Commit f5125444 by 前端

Merge branch 'SAAS+V4.44-0902' of http://192.168.3.233:8090/saas_plus/dj-car-lif…

…e-system into SAAS+V4.44-0902
2 parents 84d1ad2b ed9c09ef
...@@ -111,6 +111,6 @@ export function orderFieldSettingUpdate(data) { ...@@ -111,6 +111,6 @@ export function orderFieldSettingUpdate(data) {
} }
//员工注册码 //员工注册码
export function employeeRegister(data) { export function employeeRegister(data) {
data.method = `${path}serviceMerchant.shopSetting` data.method = `${path}staff.register`
return request(data, RequestMethods.POST) return request(data, RequestMethods.POST)
} }
...@@ -379,8 +379,9 @@ ...@@ -379,8 +379,9 @@
<el-input class="w-320" <el-input class="w-320"
size="small" size="small"
maxlength="20" maxlength="20"
@input="handleBatchServiceTimeInput($event)"
v-model="batchForm.serviceYears" v-model="batchForm.serviceYears"
placeholder="请输入服务时间"></el-input> placeholder="请输入服务时间/年"></el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
</d2-dialog> </d2-dialog>
...@@ -425,7 +426,8 @@ export default { ...@@ -425,7 +426,8 @@ export default {
extendedPosiTypeList: [], // 延保类商品部位 extendedPosiTypeList: [], // 延保类商品部位
serviceYearsVisible: false, // 批量服务时间弹窗 serviceYearsVisible: false, // 批量服务时间弹窗
batchForm: { batchForm: {
serviceYears: '' serviceYears: '',
oldServiceYears: ''
}, },
batchRules: { batchRules: {
serviceYears: [ serviceYears: [
...@@ -780,6 +782,13 @@ export default { ...@@ -780,6 +782,13 @@ export default {
this.$set(this.goodsInfoData.goodsSpecificationSingleList[index], 'serviceYears', limitPrice(newValue, oldValue, 2, 0, 1)) this.$set(this.goodsInfoData.goodsSpecificationSingleList[index], 'serviceYears', limitPrice(newValue, oldValue, 2, 0, 1))
this.$set(this.goodsInfoData.goodsSpecificationSingleList[index], 'oldserviceYears', this.goodsInfoData.goodsSpecificationSingleList[index]['serviceYears']) this.$set(this.goodsInfoData.goodsSpecificationSingleList[index], 'oldserviceYears', this.goodsInfoData.goodsSpecificationSingleList[index]['serviceYears'])
}, },
// 批量服务时间
handleBatchServiceTimeInput(newValue) {
newValue = newValue.replace(/[^\d.]/g, '')
let oldValue = this.batchForm.oldServiceYears ? this.batchForm.oldServiceYears : ''
this.$set(this.batchForm, 'serviceYears', limitPrice(newValue, oldValue, 2, 0, 1))
this.$set(this.batchForm, 'oldServiceYears', this.batchForm['serviceYears'])
},
handleServiceTimeBlur(e, index) { handleServiceTimeBlur(e, index) {
const newValue = e.target.value const newValue = e.target.value
if (!newValue) this.$set(this.goodsInfoData.goodsSpecificationSingleList[index], 'serviceYearsEmpty', true) if (!newValue) this.$set(this.goodsInfoData.goodsSpecificationSingleList[index], 'serviceYearsEmpty', true)
......
<!-- 标记退款 --> <!-- 标记退款 -->
<template> <template>
<baseDialog :dialog-config="dialogConfig" :is-show.sync="visible" :btn-loding="btnLoding" class="accountDailog" @handleClick="handleAddConfirm"> <baseDialog :dialog-config="dialogConfig" :is-show.sync="visible" :btn-loding="btnLoding" class="accountDailog" @handleClick="handleAddConfirm">
<div class="refund-dialog"> <div class="refund-dialog" v-loading="loading">
<p class="title">业务信息</p> <p class="title">业务信息</p>
<el-form class="edit-sub-block" label-width="150px" :inline="true"> <el-form class="edit-sub-block" label-width="150px" :inline="true">
<template v-for="item in orderInfoList"> <template v-for="item in orderInfoList">
...@@ -25,15 +25,15 @@ ...@@ -25,15 +25,15 @@
</el-input> </el-input>
</div> </div>
<template slot="attachmentListHtml" slot-scope="scope"> <template slot="attachmentListHtml" slot-scope="scope">
<el-upload action="" accept=".xlsx,.xls,.doc,.pdf" class="upload-file" drag :show-file-list="false" :file-list="uploadFileList" :limit="5" :auto-upload="false" :on-remove="importFileChange" :on-change=" <el-upload action="" accept=".xlsx,.xls,.doc,.pdf,.docx,.jpg,.png" class="upload-file" :show-file-list="false" :file-list="uploadFileList" :limit="5" :auto-upload="false" :on-remove="importFileChange" :on-change="
(file, fileList) => handleFileChange(file, fileList, scope.scope) (file, fileList) => handleFileChange(file, fileList, scope.scope)
" :on-exceed="hanldeOnExceed" multiple> " :on-exceed="hanldeOnExceed" multiple>
<i class="el-icon-upload"></i> <!-- <i class="el-icon-upload"></i>
<div class="el-upload__text">点击或将文件拖拽到此区域上传</div> <div class="el-upload__text">点击或将文件拖拽到此区域上传</div>
<div class="item-tips text-tips"> <div class="item-tips text-tips">
支持格式:.xlsx .xls .doc .pdf 支持格式:.xlsx .xls .doc .pdf
</div> </div> -->
<div class="item-tips">单个文件不能超过10M,最多上传5个文件</div> <div class="upload-txt">+ 上传文件</div>
</el-upload> </el-upload>
<!-- 文件列表区域 --> <!-- 文件列表区域 -->
<div class="file-box"> <div class="file-box">
...@@ -48,6 +48,7 @@ ...@@ -48,6 +48,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="upload-tips">支持文件格式:.doc .docx .pdf .xlsx .xls .png .jpg ,单个文件不能超过10M,最多上传5个文件。</div>
</template> </template>
</glsx-combi-form> </glsx-combi-form>
</div> </div>
...@@ -57,7 +58,7 @@ ...@@ -57,7 +58,7 @@
<script> <script>
import { getPlatformMerchant, addRefundApplyRecord, getOrderDefaultInfo } from "@api/refundExamine" import { getPlatformMerchant, addRefundApplyRecord, getOrderDefaultInfo } from "@api/refundExamine"
import { getYqMerchantConfig } from "@api/serviceManage" import { getYqMerchantConfig } from "@api/serviceManage"
import { getList as merchantApi } from '@api/merchant' import { listShop4sByRef as merchantApi } from '@api/merchant'
import { getList as serviceManageApi } from '@api/serviceManage' import { getList as serviceManageApi } from '@api/serviceManage'
import { deepClone } from "@/common/util" import { deepClone } from "@/common/util"
import { mapActions, mapState } from "vuex" import { mapActions, mapState } from "vuex"
...@@ -68,6 +69,9 @@ export default { ...@@ -68,6 +69,9 @@ export default {
data() { data() {
return { return {
userInfo: this.$store.state.d2admin.user.info, userInfo: this.$store.state.d2admin.user.info,
loading: false,
// 标记apiList是否都正确返回数据
baseApiIdx: 0,
okParams: {}, okParams: {},
formDefaultObj: { formDefaultObj: {
labelWidth: '150px', labelWidth: '150px',
...@@ -75,7 +79,7 @@ export default { ...@@ -75,7 +79,7 @@ export default {
isEdit: true isEdit: true
}, },
infoForm: { infoForm: {
refundType: '', refundType: "1",
yqMerchantId: '', yqMerchantId: '',
shopMerchantId: '', shopMerchantId: '',
shopRefundAmount: '', shopRefundAmount: '',
...@@ -317,10 +321,15 @@ export default { ...@@ -317,10 +321,15 @@ export default {
isClear: true, isClear: true,
maxlength: 30, maxlength: 30,
inputFn: (event) => { inputFn: (event) => {
if (!(/^\d|\s+$/.test(event.slice(event.length - 1)))) { if (!(/^\d|\s+$/.test(event.slice(event.length)))) {
this.infoForm.bankAccountNo = event.slice(0, event.length - 1) this.infoForm.bankAccountNo = event.replace(/\D/g, '')
} }
this.infoForm.bankAccountNo = this.infoForm.bankAccountNo.replace(/\s/g, '').replace(/(.{4})/g, "$1 ") this.infoForm.bankAccountNo = this.infoForm.bankAccountNo.replace(/\s/g, '').replace(/(.{4})/g, "$1 ")
let arr = this.infoForm.bankAccountNo.split('')
if(arr[arr.length - 1] == ' ') {
arr.splice(arr.length - 1, 1)
this.infoForm.bankAccountNo = arr.join('')
}
} }
}, },
{ {
...@@ -342,10 +351,10 @@ export default { ...@@ -342,10 +351,10 @@ export default {
], ],
baseData: { baseData: {
refundList: [{ refundList: [{
confId: 1, confId: '1',
confLabel: '全额退款' confLabel: '全额退款'
}, { }, {
confId: 2, confId: '2',
confLabel: '部分退款' confLabel: '部分退款'
}], }],
yqMerchantList: [], yqMerchantList: [],
...@@ -358,7 +367,8 @@ export default { ...@@ -358,7 +367,8 @@ export default {
list: ['yqMerchantList'] list: ['yqMerchantList']
}, { }, {
api: merchantApi, api: merchantApi,
list: ['shopMerchantList'] list: ['shopMerchantList'],
noList: true
}, { }, {
api: serviceManageApi, api: serviceManageApi,
list: ['partnerList'] list: ['partnerList']
...@@ -438,6 +448,11 @@ export default { ...@@ -438,6 +448,11 @@ export default {
created() { created() {
this.dealAttrRule() this.dealAttrRule()
this.getPlatformMerchant()
this.loading = true
this.apiList.forEach(item => {
this.setBaseData(item)
})
}, },
mounted() { mounted() {
...@@ -453,18 +468,24 @@ export default { ...@@ -453,18 +468,24 @@ export default {
// 加判断--------------- // 加判断---------------
this.getOrderDefaultInfo() this.getOrderDefaultInfo()
} else if (this.orderList && this.orderList.length > 0) { } else if (this.orderList && this.orderList.length > 0) {
let yqIdTemp = this.orderList[0].yqMerchantId
let shopIdTemp = this.orderList[0].shopMerchantId
this.orderList.forEach((item) => { this.orderList.forEach((item) => {
if(yqIdTemp) {
yqIdTemp = yqIdTemp == item.yqMerchantId ? yqIdTemp : ''
}
if(shopIdTemp) {
shopIdTemp = shopIdTemp == item.shopMerchantId ? shopIdTemp : ''
}
this.orderInfoList.push({ this.orderInfoList.push({
orderCode: item.orderCode, orderCode: item.orderCode,
price: item.price price: item.price
}) })
this.infoForm.bizOrderCodeList.push(item.orderCode) this.infoForm.bizOrderCodeList.push(item.orderCode)
}) })
this.infoForm.yqMerchantId = yqIdTemp
this.infoForm.shopMerchantId = shopIdTemp
} }
this.getPlatformMerchant()
this.apiList.forEach(item => {
this.setBaseData(item)
})
}, },
methods: { methods: {
...@@ -525,9 +546,14 @@ export default { ...@@ -525,9 +546,14 @@ export default {
setBaseData(name) { setBaseData(name) {
name.api(this.pageParams).then(res => { name.api(this.pageParams).then(res => {
name.list.forEach(k => { name.list.forEach(k => {
this.baseData[k] = res.list this.baseData[k] = name.noList ? res : res.list
}) })
this.baseApiIdx = this.baseApiIdx + 1
this.getOptionsList('infoEditFormData') this.getOptionsList('infoEditFormData')
}).finally(() => {
if(this.baseApiIdx == this.apiList.length) {
this.loading = false
}
}) })
}, },
...@@ -560,7 +586,10 @@ export default { ...@@ -560,7 +586,10 @@ export default {
!fileInfo.name.includes(".xlsx") && !fileInfo.name.includes(".xlsx") &&
!fileInfo.name.includes(".xls") && !fileInfo.name.includes(".xls") &&
!fileInfo.name.includes(".doc") && !fileInfo.name.includes(".doc") &&
!fileInfo.name.includes(".pdf") !fileInfo.name.includes(".pdf") &&
!fileInfo.name.includes(".docx") &&
!fileInfo.name.includes(".png") &&
!fileInfo.name.includes(".jpg")
) { ) {
this.$message({ this.$message({
message: "文件格式不支持上传", message: "文件格式不支持上传",
...@@ -607,7 +636,9 @@ export default { ...@@ -607,7 +636,9 @@ export default {
"application/vnd.ms-excel": "excel", "application/vnd.ms-excel": "excel",
"application/msword": "doc", "application/msword": "doc",
"application/vnd.openxmlformats-officedocument.wordprocessingml.document": "application/vnd.openxmlformats-officedocument.wordprocessingml.document":
"docx" "doc",
"image/png": "image",
"image/jpeg": "image"
} }
// this.btnLoding = true // this.btnLoding = true
uploadFile({ uploadFile({
...@@ -799,10 +830,11 @@ export default { ...@@ -799,10 +830,11 @@ export default {
} }
.el-textarea .el-input__count { .el-textarea .el-input__count {
right: 90px; right: 10px;
bottom: -10px; bottom: -7px;
font-size: 12px; font-size: 12px;
color: #999999; color: #999999;
background-color: transparent;
} }
.tips { .tips {
...@@ -823,35 +855,55 @@ export default { ...@@ -823,35 +855,55 @@ export default {
} }
.upload-file { .upload-file {
::v-deep .el-upload-dragger { width: 110px;
display: flex; height: 32px;
flex-flow: column; border-radius: 4px;
justify-content: center; opacity: 1;
align-items: center; border: 1px solid #00000026;
width: 300px; background: #ffffff;
height: 160px; text-align: center;
background: #f7f7f7; .upload-txt {
.el-icon-upload {
margin: 0;
}
.el-upload__text {
font-size: 14px;
color: #000000;
}
.item-tips {
font-size: 12px;
color: #999999;
height: 22px; height: 22px;
color: #666666;
font-size: 14px;
text-align: left;
line-height: 22px; line-height: 22px;
} }
// ::v-deep .el-upload-dragger {
// display: flex;
// flex-flow: column;
// justify-content: center;
// align-items: center;
// width: 300px;
// height: 160px;
// background: #f7f7f7;
// .el-icon-upload {
// margin: 0;
// }
.text-tips { // .el-upload__text {
font-size: 14px; // font-size: 14px;
} // color: #000000;
// }
// .item-tips {
// font-size: 12px;
// color: #999999;
// height: 22px;
// line-height: 22px;
// }
// .text-tips {
// font-size: 14px;
// }
// }
} }
.upload-tips {
height: 20px;
color: #999999;
font-size: 14px;
text-align: left;
} }
.file-box { .file-box {
...@@ -868,8 +920,8 @@ export default { ...@@ -868,8 +920,8 @@ export default {
::v-deep .el-progress-bar { ::v-deep .el-progress-bar {
width: 320px; width: 320px;
background: #ffffff; // background: #ffffff;
border: 1px solid #f4f6fc; // border: 1px solid #f4f6fc;
border-radius: 4px; border-radius: 4px;
.el-progress-bar__outer { .el-progress-bar__outer {
...@@ -889,16 +941,19 @@ export default { ...@@ -889,16 +941,19 @@ export default {
} }
.file-name { .file-name {
position: absolute; box-sizing: border-box;
left: 12px; width: 318px;
top: 6px; height: 26px;
transform: translateY(-50%); line-height: 26px;
background: #f5f7fa;
color: #333333; color: #333333;
font-size: 14px; font-size: 14px;
max-width: 300px; transform: translateY(-50%);
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
border-radius: 4px;
padding: 0 8px;
} }
.image-file { .image-file {
...@@ -907,11 +962,11 @@ export default { ...@@ -907,11 +962,11 @@ export default {
} }
.file-item:first-child { .file-item:first-child {
margin-top: 15px; margin-top: 11px;
.file-name { .file-name {
position: absolute; position: absolute;
left: 12px; left: 0px;
top: 15px; top: 15px;
transform: translateY(-50%); transform: translateY(-50%);
color: #333333; color: #333333;
......
...@@ -4,15 +4,15 @@ ...@@ -4,15 +4,15 @@
<div class="refund-update-dialog"> <div class="refund-update-dialog">
<glsx-combi-form class="edit-form-container" ref="editFormRef" label-width="150px" default-width="370px" :form-ref="editChildRef" :form-obj="infoForm" :form-data="editFormData" :form-rules="formRules"> <glsx-combi-form class="edit-form-container" ref="editFormRef" label-width="150px" default-width="370px" :form-ref="editChildRef" :form-obj="infoForm" :form-data="editFormData" :form-rules="formRules">
<template slot="attachmentListHtml" slot-scope="scope"> <template slot="attachmentListHtml" slot-scope="scope">
<el-upload action="" accept=".png,.jpg" class="upload-file" drag :show-file-list="false" :file-list="uploadFileList" :limit="5" :auto-upload="false" :on-remove="importFileChange" :on-change=" <el-upload action="" accept=".png,.jpg" class="upload-file" :show-file-list="false" :file-list="uploadFileList" :limit="5" :auto-upload="false" :on-remove="importFileChange" :on-change="
(file, fileList) => handleFileChange(file, fileList, scope.scope) (file, fileList) => handleFileChange(file, fileList, scope.scope)
" :on-exceed="hanldeOnExceed" multiple> " :on-exceed="hanldeOnExceed" multiple>
<i class="el-icon-upload"></i> <!-- <i class="el-icon-upload"></i>
<div class="el-upload__text">点击或将文件拖拽到此区域上传</div> <div class="el-upload__text">点击或将文件拖拽到此区域上传</div>
<div class="item-tips text-tips"> <div class="item-tips text-tips">
支持格式:.png .jpg 支持格式:.png .jpg
</div> </div> -->
<div class="item-tips">单个文件不能超过10M,最多上传5个文件</div> <div class="upload-txt">+ 上传文件</div>
</el-upload> </el-upload>
<!-- 文件列表区域 --> <!-- 文件列表区域 -->
<div class="file-box"> <div class="file-box">
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="upload-tips">支持文件格式: .png .jpg ,单个文件不能超过10M,最多上传5个文件。</div>
</template> </template>
</glsx-combi-form> </glsx-combi-form>
</div> </div>
...@@ -81,6 +82,13 @@ export default { ...@@ -81,6 +82,13 @@ export default {
trigger: "blur" trigger: "blur"
} }
], ],
attachmentList: [
{
required: false,
message: "请上传结算凭证",
trigger: "blur"
}
],
remark: [ remark: [
{ {
required: true, required: true,
...@@ -119,15 +127,20 @@ export default { ...@@ -119,15 +127,20 @@ export default {
isClear: true, isClear: true,
maxlength: 30, maxlength: 30,
inputFn: (event) => { inputFn: (event) => {
if (!(/^\d|\s+$/.test(event.slice(event.length - 1)))) { if (!(/^\d|\s+$/.test(event.slice(event.length)))) {
this.infoForm.bankAccountNo = event.slice(0, event.length - 1) this.infoForm.bankAccountNo = event.replace(/\D/g, '')
} }
this.infoForm.bankAccountNo = this.infoForm.bankAccountNo.replace(/\s/g, '').replace(/(.{4})/g, "$1 ") this.infoForm.bankAccountNo = this.infoForm.bankAccountNo.replace(/\s/g, '').replace(/(.{4})/g, "$1 ")
let arr = this.infoForm.bankAccountNo.split('')
if(arr[arr.length - 1] == ' ') {
arr.splice(arr.length - 1, 1)
this.infoForm.bankAccountNo = arr.join('')
}
} }
}, { }, {
label: "附件", label: "结算凭证",
name: "attachmentList", name: "attachmentList",
// isHide: false, isHide: true,
addHtml: "attachmentListHtml" addHtml: "attachmentListHtml"
}, { }, {
label: "备注", label: "备注",
...@@ -175,6 +188,11 @@ export default { ...@@ -175,6 +188,11 @@ export default {
// this.dialogConfig.title = this.examineType // this.dialogConfig.title = this.examineType
this.infoForm = deepClone(this.detailInfo) this.infoForm = deepClone(this.detailInfo)
this.getPlatformMerchant() this.getPlatformMerchant()
this.dealAttachment()
if(this.infoForm.bankAccountNo) {
this.infoForm.bankAccountNo = this.infoForm.bankAccountNo.replace(/\s/g, '').replace(/(.{4})/g, "$1 ")
}
console.log(this.infoForm, 'infoForm--------')
}, },
methods: { methods: {
...@@ -190,6 +208,25 @@ export default { ...@@ -190,6 +208,25 @@ export default {
}) })
}, },
dealAttachment() {
// fileType 文件类型(1.申请附件,2.结算凭证)';只保留结算凭证
/* status状态(已完成才有结算凭证)
{ confId: 0, confValue: "运营审核" },
{ confId: 1, confValue: "商务审核" },
{ confId: 2, confValue: "财务复核" },
{ confId: 3, confValue: "财务结算" },
{ confId: 4, confValue: "已完成" },
{ confId: 5, confValue: "驳回" }
*/
console.log(this.infoForm.status)
this.infoForm.attachmentList = this.infoForm.status == 4 ? [] : (this.infoForm.attachmentList.filter(item => item.fileType == 2) || [])
if (this.infoForm.status == 4) {
let idx = this.editFormData.findIndex(item => item.label == '结算凭证')
this.editFormData[idx].isHide = false
this.formRules.attachmentList[0].required = true
}
},
getPlatformMerchant() { getPlatformMerchant() {
this.baseData.platformMerchantIdList = [] this.baseData.platformMerchantIdList = []
var params = {} var params = {}
...@@ -203,7 +240,6 @@ export default { ...@@ -203,7 +240,6 @@ export default {
importFileChange(file, fileList) { importFileChange(file, fileList) {
this.uploadFileList = fileList this.uploadFileList = fileList
this.infoForm.attachmentList = deepClone(fileList) this.infoForm.attachmentList = deepClone(fileList)
console.log(fileList, "fileList")
}, },
hanldeOnExceed(files, fileList) { hanldeOnExceed(files, fileList) {
...@@ -292,7 +328,7 @@ export default { ...@@ -292,7 +328,7 @@ export default {
// this.btnLoding = true // this.btnLoding = true
uploadFile({ uploadFile({
file: base64, file: base64,
fileType: fileTypeKey[fileInfo.type], fileType: 'image',
onProcess: (e) => { onProcess: (e) => {
// 上传进度 // 上传进度
const { loaded, total } = e const { loaded, total } = e
...@@ -333,7 +369,14 @@ export default { ...@@ -333,7 +369,14 @@ export default {
i-- // 需要将i减1,因为数组长度已经减少了1 i-- // 需要将i减1,因为数组长度已经减少了1
} }
} }
console.log(params, 'params-----------') params.attachmentList.forEach((k, idx) => {
params.attachmentList[idx] = {
fileUrl: k.fileUrl,
fileName: k.fileName
}
})
params.bankAccountNo = params.bankAccountNo.replace(/\s*/g, '')
// console.log(params, 'params-----------')
update(params).then((res) => { update(params).then((res) => {
this.notice.okTips("操作成功") this.notice.okTips("操作成功")
this.$emit('refundConfirm') this.$emit('refundConfirm')
...@@ -365,6 +408,28 @@ export default { ...@@ -365,6 +408,28 @@ export default {
.tips { .tips {
color: #999999; color: #999999;
} }
.upload-file {
width: 110px;
height: 32px;
border-radius: 4px;
opacity: 1;
border: 1px solid #00000026;
background: #ffffff;
text-align: center;
.upload-txt {
height: 22px;
color: #666666;
font-size: 14px;
text-align: left;
line-height: 22px;
}
}
.upload-tips {
height: 20px;
color: #999999;
font-size: 14px;
text-align: left;
}
.file-box { .file-box {
width: 350px; width: 350px;
...@@ -401,16 +466,19 @@ export default { ...@@ -401,16 +466,19 @@ export default {
} }
.file-name { .file-name {
position: absolute; box-sizing: border-box;
left: 12px; width: 318px;
top: 6px; height: 26px;
transform: translateY(-50%); line-height: 26px;
background: #f5f7fa;
color: #333333; color: #333333;
font-size: 14px; font-size: 14px;
max-width: 300px; transform: translateY(-50%);
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
border-radius: 4px;
padding: 0 8px;
} }
.image-file { .image-file {
...@@ -419,11 +487,11 @@ export default { ...@@ -419,11 +487,11 @@ export default {
} }
.file-item:first-child { .file-item:first-child {
margin-top: 15px; margin-top: 8px;
.file-name { .file-name {
position: absolute; position: absolute;
left: 12px; left: 0px;
top: 15px; top: 15px;
transform: translateY(-50%); transform: translateY(-50%);
color: #333333; color: #333333;
......
...@@ -581,7 +581,7 @@ export default { ...@@ -581,7 +581,7 @@ export default {
selectableFn(row, index) { selectableFn(row, index) {
var isSelect = true var isSelect = true
if (row.inputStatus == '1' || row.inputStatus == '6' || row.inputStatus == '7' || row.inputStatus == '8') { // 已补录流水/已分帐/退款中/已退款不可勾选 if (row.inputStatus == '1' || row.inputStatus == '7' || row.inputStatus == '8') { // 已补录流水/退款中/已退款不可勾选
isSelect = false isSelect = false
} }
return isSelect return isSelect
...@@ -601,6 +601,17 @@ export default { ...@@ -601,6 +601,17 @@ export default {
}) })
return false return false
} }
const flag = selectedData.some((item) => {
return item.inputStatus == '6' // “已分账”不可进行该操作
})
if (flag) {
this.$message({
message: "已分账状态流水不支持操作",
type: "warning",
showClose: true
})
return false
}
this.ids = selectedData.map((item) => { this.ids = selectedData.map((item) => {
return item.id return item.id
}) })
...@@ -628,6 +639,17 @@ export default { ...@@ -628,6 +639,17 @@ export default {
}) })
return false return false
} }
const flag = selectedData.some((item) => {
return item.inputStatus == '6' // “已分账”不可进行该操作
})
if (flag) {
this.$message({
message: "已分账状态流水不支持操作",
type: "warning",
showClose: true
})
return false
}
var idList = selectedData.map((item) => { var idList = selectedData.map((item) => {
return item.id return item.id
}) })
...@@ -782,7 +804,7 @@ export default { ...@@ -782,7 +804,7 @@ export default {
return false return false
} }
const flag = selectedData.some((item) => { const flag = selectedData.some((item) => {
return item.inputStatus != '0' && item.inputStatus != '2' && item.inputStatus != '3' // 仅流水状态=“未关联”“未补录”“无需补录”可进行该操作 return item.inputStatus != '0' && item.inputStatus != '2' && item.inputStatus != '3' && item.inputStatus != '6' // 仅流水状态=“未关联”“未补录”“无需补录”“已分账”可进行该操作
}) })
if (flag) { if (flag) {
this.$message({ this.$message({
......
...@@ -64,6 +64,7 @@ ...@@ -64,6 +64,7 @@
<span style="margin-right: 10px;"> <span style="margin-right: 10px;">
<auth-button :data="scope.scope" <auth-button :data="scope.scope"
:show-btn-ids="['9040808']" /> :show-btn-ids="['9040808']" />
<span v-if="scope.scope.downCount != 0" style="color: #2A58AD;">({{scope.scope.downCount}})</span>
</span> </span>
</div> </div>
</d2-table> </d2-table>
...@@ -207,7 +208,10 @@ export default { ...@@ -207,7 +208,10 @@ export default {
}, { }, {
label: '银行账号', label: '银行账号',
prop: 'bankAccountNo', prop: 'bankAccountNo',
width: '160px' width: '160px',
formatter: (cellValue) => {
return cellValue.bankAccountNo ? cellValue.bankAccountNo.replace(/\s/g, '').replace(/(.{4})/g, "$1 ") : '--'
}
}, { }, {
label: '关联业务单号', label: '关联业务单号',
prop: 'bizOrderCode', prop: 'bizOrderCode',
......
...@@ -127,9 +127,12 @@ ...@@ -127,9 +127,12 @@
</el-row> </el-row>
</el-form> </el-form>
</div> </div>
<div class="examine-record" v-if="detailInfo.operationList.length > 0"> <div class="examine-record">
<div class="title">审核记录</div> <div class="title">审核记录</div>
<div class="record-div"> <div
class="record-div"
v-if="detailInfo.operationList && detailInfo.operationList.length > 0"
>
<div <div
class="record-div-d" class="record-div-d"
v-for="(item, index) in detailInfo.operationList" v-for="(item, index) in detailInfo.operationList"
...@@ -146,6 +149,7 @@ ...@@ -146,6 +149,7 @@
<div class="record-div-time">审核时间:{{ item.operateTime }}</div> <div class="record-div-time">审核时间:{{ item.operateTime }}</div>
</div> </div>
</div> </div>
<div v-else class="empty">暂无记录</div>
</div> </div>
</div> </div>
<el-dialog <el-dialog
...@@ -418,6 +422,12 @@ export default { ...@@ -418,6 +422,12 @@ export default {
.carousel-img { .carousel-img {
width: 100%; width: 100%;
} }
.empty {
display: flex;
align-items: center;
justify-content: center;
margin-top:20px;
}
</style> </style>
<style > <style >
......
...@@ -55,7 +55,7 @@ ...@@ -55,7 +55,7 @@
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="积分变化时间:"> <el-form-item label="积分变化时间:">
{{ detailInfo.rewardTime ? detailInfo.rewardTime : "-" }} {{ detailInfo.updatedTime ? detailInfo.updatedTime : "-" }}
</el-form-item></el-col </el-form-item></el-col
> >
...@@ -173,9 +173,8 @@ export default { ...@@ -173,9 +173,8 @@ export default {
getDetail() { getDetail() {
getScoreDetail({ id: this.id }).then((res) => { getScoreDetail({ id: this.id }).then((res) => {
if (res) { if (res) {
console.log(res) res.updatedTime = res.updatedTime
res.rewardTime = res.rewardTime ? Util.dateFormate(res.updatedTime, "YYYY-MM-DD HH:mm:ss")
? Util.dateFormate(res.rewardTime, "YYYY-MM-DD HH:mm:ss")
: "--" : "--"
res.withdrawalTime = res.withdrawalTime res.withdrawalTime = res.withdrawalTime
? Util.dateFormate(res.withdrawalTime, "YYYY-MM-DD HH:mm:ss") ? Util.dateFormate(res.withdrawalTime, "YYYY-MM-DD HH:mm:ss")
......
...@@ -187,19 +187,19 @@ export default { ...@@ -187,19 +187,19 @@ export default {
exportDetailScore(params).then((res) => { exportDetailScore(params).then((res) => {
console.log(res) console.log(res)
this.$open(res.data) this.$open(res)
}) })
}, },
beforeSearchFn() { beforeSearchFn() {
return new Promise((resolve) => { return new Promise((resolve) => {
this.searchFormSearch = deepClone(this.searchForm) this.searchFormSearch = deepClone(this.searchForm)
if (this.searchFormSearch.rewardTime&&this.searchFormSearch.rewardTime.length) { if (this.searchFormSearch.rewardTime&&this.searchFormSearch.rewardTime.length) {
this.searchFormSearch.rewardTimeBegin = this.searchFormSearch.rewardBeginTime =
Util.dateFormate( Util.dateFormate(
this.searchFormSearch.rewardTime[0], this.searchFormSearch.rewardTime[0],
"YYYY-MM-DD" "YYYY-MM-DD"
) + " 00:00:00" ) + " 00:00:00"
this.searchFormSearch.rewardTimeEnd = this.searchFormSearch.rewardEndTime =
Util.dateFormate( Util.dateFormate(
this.searchFormSearch.rewardTime[1], this.searchFormSearch.rewardTime[1],
"YYYY-MM-DD" "YYYY-MM-DD"
...@@ -260,6 +260,9 @@ export default { ...@@ -260,6 +260,9 @@ export default {
} }
} }
} }
.header{
background: #ffffff;
}
.detail-wrap { .detail-wrap {
margin: 16px 24px; margin: 16px 24px;
.detail-tabs { .detail-tabs {
......
...@@ -452,16 +452,17 @@ export default { ...@@ -452,16 +452,17 @@ export default {
message: "审核成功" message: "审核成功"
}) })
this.handleSearch() this.handleSearch()
done()
}) })
} else { } else {
done() done()
} }
} }
}).then((action) => { }).then((action) => {
this.$message({ // this.$message({
type: "info", // type: "info",
message: "action: " + action // message: "action: " + action
}) // })
}) })
}, },
...@@ -492,8 +493,7 @@ export default { ...@@ -492,8 +493,7 @@ export default {
} }
exportFile(params).then((res) => { exportFile(params).then((res) => {
console.log(res) this.$open(res)
this.$open(res.data)
}) })
}, },
aToExport(url) { aToExport(url) {
......
...@@ -126,8 +126,7 @@ export default { ...@@ -126,8 +126,7 @@ export default {
} }
exportScore(params).then((res) => { exportScore(params).then((res) => {
console.log(res) this.$open(res)
this.$open(res.data)
}) })
}, },
handleDetail(data) { handleDetail(data) {
......
...@@ -3,10 +3,10 @@ ...@@ -3,10 +3,10 @@
<div class="header" slot="header" style="padding: 10px 20px"> <div class="header" slot="header" style="padding: 10px 20px">
<d2-search label-width="110px" :search-form="searchForm" :form-data="showFormData"> <d2-search label-width="110px" :search-form="searchForm" :form-data="showFormData">
<div slot="beginDate"> <div slot="beginDate">
<el-date-picker v-model="searchForm.beginDate" value-format="yyyy-MM-dd" type="date" placeholder="选择日期" :picker-options="beginDateOptions"></el-date-picker> <el-date-picker style="width: 100%;" v-model="searchForm.beginDate" value-format="yyyy-MM-dd" type="date" placeholder="选择日期" :picker-options="beginDateOptions"></el-date-picker>
</div> </div>
<div slot="endDate"> <div slot="endDate">
<el-date-picker v-model="searchForm.endDate" value-format="yyyy-MM-dd" type="date" placeholder="选择日期" :picker-options="endDateOptions"></el-date-picker> <el-date-picker style="width: 100%;" v-model="searchForm.endDate" value-format="yyyy-MM-dd" type="date" placeholder="选择日期" :picker-options="endDateOptions"></el-date-picker>
</div> </div>
<div class="up-btns"> <div class="up-btns">
<el-button size="small" type="primary" @click="handleSearch"> <el-button size="small" type="primary" @click="handleSearch">
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
<el-input v-model="dialogForm.badgeCode" maxlength="50"></el-input> <el-input v-model="dialogForm.badgeCode" maxlength="50"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="APP编号:" prop="appCode"> <el-form-item label="APP编号:" prop="appCode">
<el-input v-model="dialogForm.appCode" maxlength="20"></el-input> <el-input v-model="dialogForm.appCode" maxlength="50"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="保管人:" prop="custodian"> <el-form-item label="保管人:" prop="custodian">
<el-input v-model="dialogForm.custodian" maxlength="20"></el-input> <el-input v-model="dialogForm.custodian" maxlength="20"></el-input>
...@@ -205,7 +205,7 @@ export default { ...@@ -205,7 +205,7 @@ export default {
maxlength: 20 maxlength: 20
}, },
{ {
label: "使用开始日期", label: "开始使用日期",
name: "beginDate", name: "beginDate",
// type: "datePicker", // type: "datePicker",
// dateType: 'date', // dateType: 'date',
...@@ -214,7 +214,7 @@ export default { ...@@ -214,7 +214,7 @@ export default {
// pickerOptions: "beginDateOptions" // pickerOptions: "beginDateOptions"
}, },
{ {
label: "使用结束日期", label: "结束使用日期",
name: "endDate", name: "endDate",
// type: "datePicker", // type: "datePicker",
// dateType: 'date', // dateType: 'date',
...@@ -259,12 +259,12 @@ export default { ...@@ -259,12 +259,12 @@ export default {
{ {
label: '设备编号', label: '设备编号',
prop: 'badgeCode', prop: 'badgeCode',
width: '180px' width: '200px'
}, },
{ {
label: 'APP编号', label: 'APP编号',
prop: 'appCode', prop: 'appCode',
width: '160px' width: '200px'
}, },
{ {
label: '保管人', label: '保管人',
...@@ -285,7 +285,7 @@ export default { ...@@ -285,7 +285,7 @@ export default {
label: '直营', label: '直营',
prop: 'directSalesFlag', prop: 'directSalesFlag',
formatter: (cellValue) => { formatter: (cellValue) => {
return cellValue.directSalesFlag == 1 ? '是' : '否' return cellValue.directSalesFlag == 1 ? '是' : cellValue.directSalesFlag == 0 ? '否' : '-'
} }
}, },
{ {
...@@ -382,8 +382,8 @@ export default { ...@@ -382,8 +382,8 @@ export default {
custodian, custodian,
custodianPhone, custodianPhone,
supervision, supervision,
brandId: Number(brandId), brandId: brandId ? Number(brandId) : null,
directSalesFlag: directSalesFlag.toString() directSalesFlag: directSalesFlag === null ? null : directSalesFlag.toString()
} }
} }
console.log(scope) console.log(scope)
......
<!--
* @Author: 王志慧 wangzh@didihu.com.cn
* @Date: 2024-08-20 10:57:01
* @LastEditors: 王志慧 wangzh@didihu.com.cn
* @LastEditTime: 2024-08-20 11:14:12
* @FilePath: \dj-car-life-system\src\views\systemConfig\ShopConfig\components\employeeDialog.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<template> <template>
<d2-dialog <d2-dialog
title="员工注册码" title="员工注册码"
...@@ -16,9 +9,11 @@ ...@@ -16,9 +9,11 @@
@closeDialog="handleClose" @closeDialog="handleClose"
@confirmDialog="handleAddConfirm" @confirmDialog="handleAddConfirm"
> >
<div class="employee-wrap"> <div class="employee-wrap" v-if="qrCodeURL">
<div class="title">员工注册码</div> <div class="title">员工注册码</div>
<div class="code"></div> <div class="code">
<img :src="qrCodeURL" alt="" />
</div>
</div> </div>
</d2-dialog> </d2-dialog>
</template> </template>
...@@ -34,6 +29,7 @@ export default { ...@@ -34,6 +29,7 @@ export default {
baseData: { baseData: {
merchantList: [] merchantList: []
}, },
loading: true,
qrCodeURL: "" qrCodeURL: ""
} }
}, },
...@@ -55,24 +51,44 @@ export default { ...@@ -55,24 +51,44 @@ export default {
components: {}, components: {},
mounted() { mounted() {
console.log(this.info) this.getEmployeeRegister()
}, },
methods: { methods: {
// 下载图片 filename是图片名称 getEmployeeRegister() {
downImg(url, name) { employeeRegister({
// 创建a标签 并设置其相关属性,最后触发其点击事件 merchantId: this.info.merchantId
const a = document.createElement("a") }).then((res) => {
const clickEvent = document.createEvent("MouseEvents") if (res) {
a.setAttribute("href", url) this.qrCodeURL = res.qrCode
a.setAttribute("download", name) this.loading = false
a.setAttribute("target", "_blank") }
clickEvent.initEvent("click", true, true) })
a.dispatchEvent(clickEvent) },
downloadIamge(imgsrc, name = new Date().getTime()) {
//下载图片地址和图片名
var image = new Image()
// 解决跨域 Canvas 污染问题
image.setAttribute("crossOrigin", "anonymous")
image.onload = function () {
var canvas = document.createElement("canvas")
canvas.width = image.width
canvas.height = image.height
var context = canvas.getContext("2d")
context.drawImage(image, 0, 0, image.width, image.height)
var url = canvas.toDataURL("image/png") //得到图片的base64编码数据
var a = document.createElement("a") // 生成一个a元素
var event = new MouseEvent("click") // 创建一个单击事件
a.download = name || "photo" // 设置图片名称
a.href = url // 将生成的URL设置为a.href属性
a.dispatchEvent(event) // 触发a的单击事件
}
image.src = imgsrc
}, },
handleAddConfirm() { handleAddConfirm() {
this.downImg() // this.downImg(this.qrCodeURL, "员工注册码.png")
this.downloadIamge(this.qrCodeURL, "员工注册码.png")
}, },
handleClose() { handleClose() {
this.$emit("dialogClose", true) this.$emit("dialogClose", true)
...@@ -85,17 +101,19 @@ export default { ...@@ -85,17 +101,19 @@ export default {
display: flex; display: flex;
align-items: center; align-items: center;
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
.title { .title {
font-weight: 500; font-weight: 500;
font-size: 14px; font-size: 14px;
color: #333333; color: #333333;
margin-bottom:8px; margin-bottom: 8px;
} }
.code { .code {
width: 120px; width: 120px;
height: 120px; height: 120px;
background: #333333; img {
width: 100%;
}
} }
} }
</style> </style>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!