Commit 9abb79e8 by 张权

滴加完成

1 parent f1cdb325
...@@ -39,7 +39,8 @@ const commitClaimsOrder = params => { ...@@ -39,7 +39,8 @@ const commitClaimsOrder = params => {
return http({ return http({
url: 'rop-scrm-equity/router', url: 'rop-scrm-equity/router',
method: 'POST', method: 'POST',
data: params data: params,
returnAll: true
}) })
} }
...@@ -96,7 +97,7 @@ const getBankList = params => { ...@@ -96,7 +97,7 @@ const getBankList = params => {
}) })
} }
// 获取开户行和证件类型列表 // 获取省市区
const getCityList = params => { const getCityList = params => {
params.method = 'scrm.api.equity.service.claims.area' params.method = 'scrm.api.equity.service.claims.area'
return http({ return http({
...@@ -106,4 +107,14 @@ const getCityList = params => { ...@@ -106,4 +107,14 @@ const getCityList = params => {
}) })
} }
export default { getclaimsList, getclaimsCount, resubmitOrder, commitClaimsOrder, getClaimsDetail, exportClaimsData, checkContractNo, getDetailByWOCode, getBankList, getCityList } // 获取收款账号
const getAccountInfo = params => {
params.method = 'scrm.api.equity.service.claims.merchant.account'
return http({
url: 'rop-scrm-equity/router',
method: 'POST',
data: params
})
}
export default { getclaimsList, getclaimsCount, resubmitOrder, commitClaimsOrder, getClaimsDetail, exportClaimsData, checkContractNo, getDetailByWOCode, getBankList, getCityList, getAccountInfo }

7.21 KB | W: | H:

6.25 KB | W: | H:

src/assets/images/idCard.png
src/assets/images/idCard.png
src/assets/images/idCard.png
src/assets/images/idCard.png
  • 2-up
  • Swipe
  • Onion skin

8.24 KB | W: | H:

7.08 KB | W: | H:

src/assets/images/idCardBack.png
src/assets/images/idCardBack.png
src/assets/images/idCardBack.png
src/assets/images/idCardBack.png
  • 2-up
  • Swipe
  • Onion skin

4.67 KB | W: | H:

4.25 KB | W: | H:

src/assets/images/upload.png
src/assets/images/upload.png
src/assets/images/upload.png
src/assets/images/upload.png
  • 2-up
  • Swipe
  • Onion skin
...@@ -128,12 +128,15 @@ export default { ...@@ -128,12 +128,15 @@ export default {
dialogObj: { dialogObj: {
url: '', url: '',
uploadType: 'img' uploadType: 'img'
}, }
regionData: cityList
} }
}, },
props: { props: {
regionData: {
type: Array,
default: cityList
},
isBlock: { isBlock: {
type: Boolean, type: Boolean,
default: false default: false
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<div class="material"> <div class="material">
<div class="material-item" v-for="item in materialData" :key="item.name"> <div class="material-item" v-for="item in materialData" :key="item.name">
<label :class="{ require: item.label }">{{ item.label }}</label> <label :class="{ require: item.label }">{{ item.label }}</label>
<el-upload :id="item.name" :ref="item.name + 'Ref'" :file-list="materialForm[item.name]" :list-type="item.listType ? item.listType : 'picture-card'" :class="[(materialForm[item.name] ? item.limit != materialForm[item.name].length : true) ? '' : 'hidePlusBtn', 'upload-item']" :limit="item.limit" action="#" :before-upload="beforeAvatarUpload" :on-preview="handlePictureCardPreview" :on-remove="e => handleRemove(e, item.name)" :http-request="e => httpRequest(e, item.name)"> <el-upload :disabled="pageType == 2" :id="item.name" :ref="item.name + 'Ref'" :file-list="materialForm[item.name]" :list-type="item.listType ? item.listType : 'picture-card'" :class="[pageType == 2 || item.limit == materialForm[item.name].length ? 'hidePlusBtn' : '', 'upload-item']" :limit="item.limit" action="#" :before-upload="e => beforeAvatarUpload(e, item.name)" :on-preview="handlePictureCardPreview" :on-remove="e => handleRemove(e, item.name)" :http-request="e => httpRequest(e, item.name)">
<!-- <i v-if="item.name == 'billInfo'" slot="default" class="el-icon-plus"> <!-- <i v-if="item.name == 'billInfo'" slot="default" class="el-icon-plus">
<p>上传图片</p> <p>上传图片</p>
</i> --> </i> -->
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
<div slot="tip" class="remark" v-if="item.name == 'idCard'">身份证人像面</div> <div slot="tip" class="remark" v-if="item.name == 'idCard'">身份证人像面</div>
<div slot="tip" class="remark" v-if="item.name == 'idCardBack'">身份证国徽面</div> <div slot="tip" class="remark" v-if="item.name == 'idCardBack'">身份证国徽面</div>
<div slot="tip" class="file-box" v-if="item.name == 'otherInfo'"> <div slot="tip" class="file-box" v-if="item.name == 'otherInfo'">
<span class="file_tip">支持扩展名:.rar .zip .doc .docx .pdf .jpg .png。</span>
<div class="bar_outer" v-for="(imgItem, imgId) in materialForm[item.name]" :key="imgId"> <div class="bar_outer" v-for="(imgItem, imgId) in materialForm[item.name]" :key="imgId">
<el-progress <el-progress
color="#F5F7FA" color="#F5F7FA"
...@@ -26,7 +27,7 @@ ...@@ -26,7 +27,7 @@
" "
:percentage="imgItem.progress" :percentage="imgItem.progress"
></el-progress> ></el-progress>
<i class="el-icon-delete del-img"></i> <i v-if="pageType != 2" @click="handleRemove(imgItem.url, item.name)" class="el-icon-delete del_img"></i>
</div> </div>
</div> </div>
</el-upload> </el-upload>
...@@ -82,7 +83,7 @@ export default { ...@@ -82,7 +83,7 @@ export default {
{ {
label: '发票:', label: '发票:',
name: 'billInfo', name: 'billInfo',
limit: 6 limit: 10
}, },
{ {
label: '其他:', label: '其他:',
...@@ -93,8 +94,12 @@ export default { ...@@ -93,8 +94,12 @@ export default {
} }
}, },
methods: { methods: {
beforeAvatarUpload(e) { beforeAvatarUpload(e, fieldName) {
let AllImgExt = '.zip|.rar|.png|.jpg' console.log(e, fieldName, 456789)
let AllImgExt = '.png|.jpg'
if (fieldName === 'otherInfo') {
AllImgExt = '.zip|.rar|.png|.jpg|.pdf|.doc|.docx'
}
let extName = e.name.substring(e.name.lastIndexOf('.')).toLowerCase() let extName = e.name.substring(e.name.lastIndexOf('.')).toLowerCase()
if (AllImgExt.indexOf(extName) === -1) { if (AllImgExt.indexOf(extName) === -1) {
this.$message.error('上传格式不正确') this.$message.error('上传格式不正确')
...@@ -106,6 +111,16 @@ export default { ...@@ -106,6 +111,16 @@ export default {
return false return false
} }
}, },
getFileType(type) {
if (!type) return 'zip'
if (type.indexOf('word') > -1) {
return 'doc'
} else if (type.indexOf('image') > -1) {
return 'image'
} else {
return 'zip'
}
},
httpRequest({ file: e }, fieldName) { httpRequest({ file: e }, fieldName) {
console.log(e, 456) console.log(e, 456)
// // 转码base64 // // 转码base64
...@@ -116,22 +131,25 @@ export default { ...@@ -116,22 +131,25 @@ export default {
const arrBase64 = imgFile.split(',') const arrBase64 = imgFile.split(',')
const targetNameList = e.name.split('.') const targetNameList = e.name.split('.')
const fileInfo = targetNameList[targetNameList.length - 1] + '@' + arrBase64[1] const fileInfo = targetNameList[targetNameList.length - 1] + '@' + arrBase64[1]
this.materialForm[fieldName].push({ name: e.name, progress: 0 }) const fileType = this.getFileType(e.type)
const fileItem = { name: e.name, progress: 0, fileType: fileType }
if (fieldName === 'idCard') fileItem.name = '&front&_' + e.name
if (fieldName === 'idCardBack') fileItem.name = '&behind&_' + e.name
this.materialForm[fieldName].push(fileItem)
const id = this.materialForm[fieldName].length - 1 const id = this.materialForm[fieldName].length - 1
const fileType = e.type.indexOf('image') != -1 ? 'image' : '' const paramObj = { file: fileInfo, fileType: fileType }
const params = { file: [fileInfo] } let param = {}
// if (fileType) params.fileType = fileType param.fileList = [paramObj]
console.log(e.type.indexOf('image'), params, 13) this.$apis.common
const targetApi = fieldName == 'otherInfo' ? this.$apis.ghBeforeSale.uploadFileApi : this.$apis.ghBeforeSale.uploadImgApi .uploadFileApi(param, res => {
targetApi(params, res => {
this.$set(this.materialForm[fieldName][id], 'progress', ((res.loaded / res.total) * 100).toFixed(2)) this.$set(this.materialForm[fieldName][id], 'progress', ((res.loaded / res.total) * 100).toFixed(2))
}).then(res => { })
.then(res => {
if (res) { if (res) {
this.$set(this.materialForm[fieldName][id], 'url', res) this.$set(this.materialForm[fieldName][id], 'url', res[0])
} else { } else {
this.handleRemove(e, fieldName, 1) this.handleRemove(e, fieldName, 1)
const index = this.materialForm[fieldName].findIndex(item => item.name == e.name) this.materialForm[fieldName].splice(id, 1)
this.materialForm[fieldName].splice(index, 1)
} }
}) })
} }
...@@ -142,11 +160,11 @@ export default { ...@@ -142,11 +160,11 @@ export default {
let id = this.$refs[fieldName + 'Ref'][0].uploadFiles.findIndex(item => item.uid === e.uid) let id = this.$refs[fieldName + 'Ref'][0].uploadFiles.findIndex(item => item.uid === e.uid)
this.$refs[fieldName + 'Ref'][0].uploadFiles.splice(id, 1) this.$refs[fieldName + 'Ref'][0].uploadFiles.splice(id, 1)
} else { } else {
console.log(e, fieldName)
const index = this.materialForm[fieldName].findIndex(item => item.url == e) const index = this.materialForm[fieldName].findIndex(item => item.url == e)
setTimeout(() => { setTimeout(() => {
this.materialForm[fieldName].splice(index, 1) this.materialForm[fieldName].splice(index, 1)
}) })
//加定时是因为去除element删除有一个闪动
} }
}, },
handlePictureCardPreview(file) { handlePictureCardPreview(file) {
...@@ -186,12 +204,16 @@ export default { ...@@ -186,12 +204,16 @@ export default {
} }
.material { .material {
padding: 32px 20px; padding: 32px 20px;
min-width: 650px;
.material-item { .material-item {
display: flex; display: flex;
margin-bottom: 20px; margin-bottom: 20px;
.upload-item { .upload-item {
position: relative; position: relative;
} }
/deep/ .el-upload-list__item-status-label {
display: none;
}
&:nth-child(-n + 3) { &:nth-child(-n + 3) {
/deep/.el-upload-list__item, /deep/.el-upload-list__item,
/deep/.el-upload--picture-card { /deep/.el-upload--picture-card {
...@@ -224,13 +246,17 @@ export default { ...@@ -224,13 +246,17 @@ export default {
} }
} }
&:nth-child(2) { &:nth-child(2) {
margin-left: 20px; margin-left: 40px;
display: inline-block; display: inline-block;
} }
&:nth-child(3) { &:nth-child(3) {
flex: 1;
margin-bottom: 0;
/deep/.el-upload-list__item, /deep/.el-upload-list__item,
/deep/.el-upload--picture-card { /deep/.el-upload--picture-card {
width: 104px; width: 104px;
margin-right: 20px;
margin-bottom: 15px;
p { p {
font-size: 14px; font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC; font-family: PingFangSC-Regular, PingFang SC;
...@@ -256,6 +282,11 @@ export default { ...@@ -256,6 +282,11 @@ export default {
border: 1px solid #dcdfe6; border: 1px solid #dcdfe6;
color: #606266; color: #606266;
} }
/deep/ .el-button.is-disabled:hover {
color: #c0c4cc;
background: #fff;
border-color: #ebeef5;
}
} }
.remark { .remark {
left: 50%; left: 50%;
...@@ -268,11 +299,19 @@ export default { ...@@ -268,11 +299,19 @@ export default {
} }
.file-box { .file-box {
margin-top: 12px; margin-top: 12px;
.file_tip {
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #999999;
line-height: 22px;
}
.bar_outer { .bar_outer {
width: 320px; width: 320px;
position: relative; position: relative;
margin-bottom: 4px; margin-bottom: 4px;
.del-img { .del_img {
color: #c6c6c6;
position: absolute; position: absolute;
right: -25px; right: -25px;
top: 50%; top: 50%;
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
<div class="type-wrap"> <div class="type-wrap">
<label class="require" for="">批准金额:</label> <label class="require" for="">批准金额:</label>
<div class="service-wrap"> <div class="service-wrap">
<template v-if="serviceItemsList.length > 0">
<div class="service-item" v-for="(item, index) in serviceItemsList" :key="item.serviceItemCode"> <div class="service-item" v-for="(item, index) in serviceItemsList" :key="item.serviceItemCode">
<p class="name">{{ item.serviceItemName }}</p> <p class="name">{{ item.serviceItemName }}</p>
<div class="price-wrap"> <div class="price-wrap">
...@@ -18,9 +19,11 @@ ...@@ -18,9 +19,11 @@
<!-- <el-input @input="validPrice($event, index)" placeholder="请选择定损批准金额" v-model="item.price"></el-input> --> <!-- <el-input @input="validPrice($event, index)" placeholder="请选择定损批准金额" v-model="item.price"></el-input> -->
</div> </div>
</div> </div>
</template>
<div class="tip" v-else>输入合同号后自动代入</div>
</div> </div>
</div> </div>
<div class="total-price"> <div v-if="serviceItemsList.length > 0" class="total-price">
<label for="">合计:</label> <label for="">合计:</label>
<span> <span>
定损批准金为 定损批准金为
...@@ -33,8 +36,8 @@ ...@@ -33,8 +36,8 @@
<div class="collecter"> <div class="collecter">
<label class="require" for="">收款对象:</label> <label class="require" for="">收款对象:</label>
<el-radio-group :disabled="pageType == 2" v-model="accountForm.objectType" @change="changeOwner"> <el-radio-group :disabled="pageType == 2" v-model="accountForm.objectType" @change="changeOwner">
<el-radio label="0">店面</el-radio> <el-radio :label="0">店面</el-radio>
<el-radio label="1">其他</el-radio> <el-radio :label="1">其他</el-radio>
</el-radio-group> </el-radio-group>
</div> </div>
<div class="account-info"> <div class="account-info">
...@@ -86,17 +89,18 @@ export default { ...@@ -86,17 +89,18 @@ export default {
type: 'radio', type: 'radio',
optionList: [ optionList: [
{ {
confId:'0', confId:0,
confName:'对公' confName:'对公'
}, },
{ {
confId:'1', confId:1,
confName:'对私' confName:'对私'
} }
], ],
optionId: 'confId', optionId: 'confId',
optionLabel: 'confName', optionLabel: 'confName',
isHide:true, isHide:true,
isClear: true,
isDisabled: this.pageType == 2 isDisabled: this.pageType == 2
}, },
{ {
...@@ -106,12 +110,14 @@ export default { ...@@ -106,12 +110,14 @@ export default {
optionList: [], optionList: [],
optionId: 'code', optionId: 'code',
optionLabel: 'name', optionLabel: 'name',
isClear: true,
isDisabled: this.pageType == 2 isDisabled: this.pageType == 2
}, },
{ {
label: '账户名称', label: '账户名称',
name: 'accountName', name: 'accountName',
type: 'input', type: 'input',
isClear: true,
isDisabled: this.pageType == 2 isDisabled: this.pageType == 2
}, },
{ {
...@@ -119,15 +125,17 @@ export default { ...@@ -119,15 +125,17 @@ export default {
name: 'accountNo', name: 'accountNo',
type: 'input', type: 'input',
maxlength:19, maxlength:19,
isClear: true,
isDisabled: this.pageType == 2 isDisabled: this.pageType == 2
}, },
{ {
label: '收款账号所在省市', label: '收款账号所在省市',
name: 'accountCity', name: 'bankCity',
type: 'select', type: 'select',
optionList: [], optionList: [],
optionId: 'code', optionId: 'code',
optionLabel: 'name', optionLabel: 'name',
isClear: true,
isDisabled: this.pageType == 2 isDisabled: this.pageType == 2
}, },
{ {
...@@ -137,6 +145,7 @@ export default { ...@@ -137,6 +145,7 @@ export default {
optionList: [], optionList: [],
optionId: 'code', optionId: 'code',
optionLabel: 'name', optionLabel: 'name',
isClear: true,
isDisabled: this.pageType == 2 isDisabled: this.pageType == 2
}, },
{ {
...@@ -174,30 +183,14 @@ export default { ...@@ -174,30 +183,14 @@ export default {
} }
], ],
accountRule: { accountRule: {
branchBankCode: [{ required: true, message: '请输入开户行名称', trigger: 'change' }], branchBankCode: [{ required: true, message: '请选择开户行名称', trigger: 'change' }],
accountName: [{ required: true, message: '请输入账户名称', trigger: 'change' }], accountName: [{ required: true, message: '请输入账户名称', trigger: 'change' }],
accountNo: [{ required: true, trigger: 'change',validator: bankAccountValid }], accountNo: [{ required: true, message: '请输入收款账号', trigger: 'change'}],
accountCity: [{ required: true, message: '请选择收款账号所在省市', trigger: 'change' }], bankCity: [{ required: true, message: '请选择收款账号所在省市', trigger: 'change' }],
payeeIDCardType: [{ required: true, message: '请选择收款人证件类型', trigger: 'change' }], payeeIDCardType: [{ required: true, message: '请选择收款人证件类型', trigger: 'change' }],
handlerName: [{ required: true, message: '请输入经办人', trigger: 'change' }], handlerName: [{ required: true, message: '请输入经办人', trigger: 'change' }],
payeeIDCardNo: [{ required: true, message: '请输入收款人证件号码', trigger: 'change' }], payeeIDCardNo: [{ required: true, message: '请输入收款人证件号码', trigger: 'change' }],
// { payeePhone: [{ required: true, message: '请输入联系号码', trigger: 'change' }],
// required: true,
// validator: (rule, value, callback) => {
// return value ? callback() : callback(new Error('请输入' + (this.accountForm.payeeIDCardType == 'IDCard' ? '身份证' : '统一社会信息代码')))
// }, trigger: 'change'
// },
// {
// validator: (rule, value, callback) => {
// return (/[a-zA-Z0-9]{18}/).test(value) ? callback() : callback(new Error('请输入18位数字或字母'))
// }, trigger: 'change'
// }
payeePhone: [{ required: true, message: '请输入联系号码', trigger: 'change' },
{
validator: (rule, value, callback) => {
return phoneReg.test(value) ? callback() : callback(new Error('请输入正确的联系号码'))
}, trigger: 'change'
}],
handlerPhone: [ handlerPhone: [
{ {
required: true, required: true,
...@@ -222,13 +215,27 @@ export default { ...@@ -222,13 +215,27 @@ export default {
mounted() { mounted() {
}, },
watch:{
'accountForm.objectType':{
handler(newVal,oldVal){
const item = this.accountData.find(item => {
return item.name == 'accountType'
})
item.isHide = newVal==0
if(newVal==0){
this.accountForm.accountType = 0
}
},
immediate:true
}
},
methods:{ methods:{
getBankList() { getBankList() {
this.$apis.claims.getBankList({}).then(res => { this.$apis.claims.getBankList({}).then(res => {
console.log(res,456) console.log(res,456)
const branchBankList = this.accountData.find(item => item.name ==='branchBankCode') const branchBankList = this.accountData.find(item => item.name ==='branchBankCode')
branchBankList.optionList = res.branchBank branchBankList.optionList = res.branchBank
const accountCityList = this.accountData.find(item => item.name ==='accountCity') const accountCityList = this.accountData.find(item => item.name ==='bankCity')
accountCityList.optionList = res.accountCity accountCityList.optionList = res.accountCity
const IDCardTypeList = this.accountData.find(item => item.name ==='payeeIDCardType') const IDCardTypeList = this.accountData.find(item => item.name ==='payeeIDCardType')
IDCardTypeList.optionList = res.cardType IDCardTypeList.optionList = res.cardType
...@@ -256,15 +263,15 @@ export default { ...@@ -256,15 +263,15 @@ export default {
} }
this.$set(this.serviceItemsList[id], 'approveAmount' , checkPlan) this.$set(this.serviceItemsList[id], 'approveAmount' , checkPlan)
}, },
changeOwner(newVal){ // changeOwner(newVal){
const item = this.accountData.find(item => { // const item = this.accountData.find(item => {
return item.name == 'accountType' // return item.name == 'accountType'
}) // })
item.isHide = newVal=='0' // item.isHide = newVal==0
if(newVal=='0'){ // if(newVal==0){
this.accountForm.accountType = '0' // this.accountForm.accountType = 0
} // }
} // }
} }
} }
</script> </script>
...@@ -315,6 +322,13 @@ export default { ...@@ -315,6 +322,13 @@ export default {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
margin-bottom: 6px; margin-bottom: 6px;
.tip {
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #666666;
line-height: 20px;
}
label { label {
width: 115px; width: 115px;
height: 16px; height: 16px;
...@@ -348,7 +362,6 @@ export default { ...@@ -348,7 +362,6 @@ export default {
} }
} }
.total-price { .total-price {
margin-bottom: 22px;
margin-left: 115px; margin-left: 115px;
.price { .price {
.sign { .sign {
...@@ -359,6 +372,9 @@ export default { ...@@ -359,6 +372,9 @@ export default {
color: #ff6d00; color: #ff6d00;
} }
} }
.collecter {
margin-top: 22px;
}
/deep/ .account-info { /deep/ .account-info {
margin: 10px 0 0 115px; margin: 10px 0 0 115px;
padding: 20px 10px 0 20px; padding: 20px 10px 0 20px;
......
<template> <template>
<div class="report-components"> <div class="report-components">
<div class="title">报案信息(客户提交)</div> <div class="title">报案信息(客户提交)</div>
<glsxCombiForm class="edit-form-container " ref="editFormRefReport" labelWidth="144px" defaultWidth="320px" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsxCombiForm :regionData="regionData" class="edit-form-container " ref="editFormRefReport" labelWidth="144px" defaultWidth="320px" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div v-if="pageType != 2" style="display:inline-block;" slot="syncBtn"> <div v-if="pageType != 2" style="display:inline-block;" slot="syncBtn">
<el-button style="margin:0 12px;" type="primary" @click="toSearchOrderDetail">同步</el-button> <el-button style="margin:0 12px;" type="primary" @click="toSearchOrderDetail">同步</el-button>
<span style="font-weight: 400; color:#666;">同步合同中以下信息,同步后的信息可手动编辑</span> <span style="font-weight: 400; color:#666;">同步合同中以下信息,同步后的信息可手动编辑</span>
...@@ -29,6 +29,7 @@ export default { ...@@ -29,6 +29,7 @@ export default {
}, },
data() { data() {
return { return {
regionData: [],
editFormData: [], editFormData: [],
showGh: false, showGh: false,
editRule: { editRule: {
...@@ -68,10 +69,13 @@ export default { ...@@ -68,10 +69,13 @@ export default {
} }
], ],
reimbursementAddress: [{ required: true, message: '请选择出险地点', trigger: 'change' }], reimbursementAddress: [{ required: true, message: '请选择出险地点', trigger: 'change' }],
detailAddress: [{ required: true, message: '请输入出险详细地址', trigger: 'change' }] reimbursementAddr: [{ required: true, message: '请输入出险详细地址', trigger: 'change' }]
} }
} }
}, },
created() {
this.getCityList()
},
mounted() { mounted() {
this.diffKeyHandle(this.isGH) this.diffKeyHandle(this.isGH)
}, },
...@@ -88,6 +92,13 @@ export default { ...@@ -88,6 +92,13 @@ export default {
} }
}, },
methods: { methods: {
getCityList() {
console.log(111)
this.$apis.claims.getCityList({}).then(res => {
console.log(res, 456)
this.regionData = res
})
},
updateTimeLimit(newVal, key) { updateTimeLimit(newVal, key) {
let limitTime = '' let limitTime = ''
// 当不是同一天,时间限制为'00:00:00 - 23:59:59',否则'00:00:00 - endTime' // 当不是同一天,时间限制为'00:00:00 - 23:59:59',否则'00:00:00 - endTime'
...@@ -181,7 +192,7 @@ export default { ...@@ -181,7 +192,7 @@ export default {
}, },
{ {
label: '出险详细地址', label: '出险详细地址',
name: 'detailAddress', name: 'reimbursementAddr',
type: 'input', type: 'input',
isDisabled, isDisabled,
isClear: true, isClear: true,
...@@ -266,7 +277,7 @@ export default { ...@@ -266,7 +277,7 @@ export default {
}, },
{ {
label: '出险详细地址', label: '出险详细地址',
name: 'detailAddress', name: 'reimbursementAddr',
type: 'input', type: 'input',
isDisabled, isDisabled,
isClear: true, isClear: true,
......
...@@ -25,8 +25,8 @@ ...@@ -25,8 +25,8 @@
<GLTable ref="equityRef" :pageSizes="sizeList" :getListApi="getListApi" :searchForm="searchParams" :tableParams="tableParams" :beforeSearchFn="beforeSearchFn" :pageConf="batchPageConf"> <GLTable ref="equityRef" :pageSizes="sizeList" :getListApi="getListApi" :searchForm="searchParams" :tableParams="tableParams" :beforeSearchFn="beforeSearchFn" :pageConf="batchPageConf">
<div class="table-btns" slot="table-btns" slot-scope="scope"> <div class="table-btns" slot="table-btns" slot-scope="scope">
<GLButton v-if="[0].includes(scope.scope.status)" fn="去处理" type="text" @click="handleEdit(4, scope.scope)">去处理</GLButton> <GLButton v-if="[0].includes(scope.scope.status)" fn="去处理" type="text" @click="handleEdit(4, scope.scope)">去处理</GLButton>
<GLButton v-if="[2, 3, 4].includes(scope.scope.status)" fn="查看" type="text" @click="handleEdit(2, scope.scope)">查看</GLButton> <GLButton v-if="[1, 3, 4].includes(scope.scope.status)" fn="查看" type="text" @click="handleEdit(2, scope.scope)">查看</GLButton>
<GLButton v-if="[1].includes(scope.scope.status)" fn="重新提交" type="text" @click="handleEdit(3, scope.scope)">重新提交</GLButton> <GLButton v-if="[2].includes(scope.scope.status)" fn="重新提交" type="text" @click="handleEdit(3, scope.scope)">重新提交</GLButton>
</div> </div>
</GLTable> </GLTable>
</div> </div>
...@@ -104,7 +104,7 @@ export default { ...@@ -104,7 +104,7 @@ export default {
{ {
label: '核销码', label: '核销码',
prop: 'writeOffCode', prop: 'writeOffCode',
width: '90px', width: '90',
formatter: cellValue => { formatter: cellValue => {
return cellValue.writeOffCode || '-' return cellValue.writeOffCode || '-'
} }
...@@ -112,7 +112,7 @@ export default { ...@@ -112,7 +112,7 @@ export default {
{ {
label: '报案号', label: '报案号',
prop: 'registNo', prop: 'registNo',
width: '200px', width: '200',
formatter: cellValue => { formatter: cellValue => {
return cellValue.registNo || '-' return cellValue.registNo || '-'
} }
...@@ -120,7 +120,7 @@ export default { ...@@ -120,7 +120,7 @@ export default {
{ {
label: '客户名称', label: '客户名称',
prop: 'merchantName', prop: 'merchantName',
width: '160px', width: '200',
formatter: cellValue => { formatter: cellValue => {
return cellValue.merchantName || '-' return cellValue.merchantName || '-'
} }
...@@ -128,7 +128,7 @@ export default { ...@@ -128,7 +128,7 @@ export default {
{ {
label: '合同号', label: '合同号',
prop: 'contractNo', prop: 'contractNo',
width: '160px', width: '200',
formatter: cellValue => { formatter: cellValue => {
return cellValue.contractNo || '-' return cellValue.contractNo || '-'
} }
...@@ -136,7 +136,7 @@ export default { ...@@ -136,7 +136,7 @@ export default {
{ {
label: '价格区间', label: '价格区间',
prop: 'priceSection', prop: 'priceSection',
width: '200px', width: '100',
formatter: cellValue => { formatter: cellValue => {
return cellValue.priceSection || '-' return cellValue.priceSection || '-'
} }
...@@ -144,7 +144,7 @@ export default { ...@@ -144,7 +144,7 @@ export default {
{ {
label: '门店提交时间', label: '门店提交时间',
prop: 'commitTime', prop: 'commitTime',
width: '160px', width: '160',
formatter: cellValue => { formatter: cellValue => {
return cellValue.commitTime ? dayjs(cellValue.commitTime).format('YYYY-MM-DD HH:mm:ss') : '-' return cellValue.commitTime ? dayjs(cellValue.commitTime).format('YYYY-MM-DD HH:mm:ss') : '-'
} }
...@@ -152,7 +152,7 @@ export default { ...@@ -152,7 +152,7 @@ export default {
{ {
label: '提交国任时间', label: '提交国任时间',
prop: 'commitGuoRenDate', prop: 'commitGuoRenDate',
width: '200px', width: '160',
formatter: cellValue => { formatter: cellValue => {
return cellValue.commitGuoRenDate ? dayjs(cellValue.commitGuoRenDate).format('YYYY-MM-DD HH:mm:ss') : '-' return cellValue.commitGuoRenDate ? dayjs(cellValue.commitGuoRenDate).format('YYYY-MM-DD HH:mm:ss') : '-'
} }
...@@ -160,7 +160,8 @@ export default { ...@@ -160,7 +160,8 @@ export default {
{ {
label: '服务名称', label: '服务名称',
prop: 'serviceName', prop: 'serviceName',
width: '300px', width: '300',
line: 1,
formatter: cellValue => { formatter: cellValue => {
return cellValue.serviceName || '-' return cellValue.serviceName || '-'
} }
...@@ -168,7 +169,7 @@ export default { ...@@ -168,7 +169,7 @@ export default {
{ {
label: '服务状态', label: '服务状态',
prop: 'status', prop: 'status',
width: '160px', width: '120',
formatter: cellValue => { formatter: cellValue => {
return statusList.map(item => item.confId).includes(cellValue.status) ? statusList.find(item => item.confId == cellValue.status).confName : '-' return statusList.map(item => item.confId).includes(cellValue.status) ? statusList.find(item => item.confId == cellValue.status).confName : '-'
} }
...@@ -176,7 +177,7 @@ export default { ...@@ -176,7 +177,7 @@ export default {
{ {
label: '状态描述', label: '状态描述',
prop: 'statusDesc', prop: 'statusDesc',
width: '200px', width: '200',
formatter: cellValue => { formatter: cellValue => {
return cellValue.statusDesc || '-' return cellValue.statusDesc || '-'
} }
...@@ -184,7 +185,7 @@ export default { ...@@ -184,7 +185,7 @@ export default {
{ {
label: '批准金额', label: '批准金额',
prop: 'approvalAmount', prop: 'approvalAmount',
width: '160px', width: '100',
formatter: cellValue => { formatter: cellValue => {
return cellValue.approvalAmount ? (cellValue.approvalAmount / 100).toFixed(2) : '-' return cellValue.approvalAmount ? (cellValue.approvalAmount / 100).toFixed(2) : '-'
} }
...@@ -192,21 +193,23 @@ export default { ...@@ -192,21 +193,23 @@ export default {
{ {
label: '支付金额', label: '支付金额',
prop: 'paymentAmount', prop: 'paymentAmount',
width: '100',
formatter: cellValue => { formatter: cellValue => {
return cellValue.paymentAmount ? (cellValue.paymentAmount / 100).toFixed(2) : '-' return cellValue.paymentAmount || '-'
} }
}, },
{ {
label: '操作人', label: '操作人',
prop: 'reporterName', prop: 'operatorName',
width: '100',
formatter: cellValue => { formatter: cellValue => {
return cellValue.reporterName || '-' return cellValue.operatorName || '-'
} }
}, },
{ {
label: '操作', label: '操作',
prop: '', prop: '',
width: '200px', width: '200',
fixed: 'right', fixed: 'right',
addHtml: 'table-btns' addHtml: 'table-btns'
} }
...@@ -247,7 +250,8 @@ export default { ...@@ -247,7 +250,8 @@ export default {
editNo, editNo,
isGH: this.showGh, isGH: this.showGh,
// isGH: true, // isGH: true,
contractNo: editNo == 1 ? '' : row.contractNo // 嘀加的用合同号 contractNo: editNo == 1 ? '' : row.contractNo, // 嘀加的用合同号
orderId: editNo == 1 ? '' : row.id
} }
if (this.showGh) { if (this.showGh) {
// 广汇的用核销码 // 广汇的用核销码
......
...@@ -6,8 +6,8 @@ ...@@ -6,8 +6,8 @@
<material ref="materialRef" :pageType="pageType" :materialForm.sync="materialForm"></material> <material ref="materialRef" :pageType="pageType" :materialForm.sync="materialForm"></material>
<div class="footer operate-btn"> <div class="footer operate-btn">
<template v-if="pageType != 2"> <template v-if="pageType != 2">
<el-button size="small" type="primary" @click="confirmSubmit(1)">确定</el-button> <el-button size="small" type="primary" @click="confirmSubmit(1)">提交</el-button>
<el-button size="small" type="primary" plain @click="confirmSubmit(2)">存草稿</el-button> <el-button size="small" type="primary" plain @click="confirmSubmit(2)">草稿</el-button>
<el-button size="small" @click="handleCancel">取消</el-button> <el-button size="small" @click="handleCancel">取消</el-button>
</template> </template>
<template v-else> <template v-else>
...@@ -20,6 +20,7 @@ ...@@ -20,6 +20,7 @@
import report from './components/report.vue' import report from './components/report.vue'
import repair from './components/repair.vue' import repair from './components/repair.vue'
import material from './components/material.vue' import material from './components/material.vue'
import util from '@/util/util'
export default { export default {
name: 'order', name: 'order',
components: { components: {
...@@ -39,16 +40,19 @@ export default { ...@@ -39,16 +40,19 @@ export default {
reporterName: '', reporterName: '',
reporterPhone: '', reporterPhone: '',
writeOffCode: '', writeOffCode: '',
detailAddress: '' reimbursementAddr: '',
reimbursementProvinceCode: '',
reimbursementCityCode: '',
reimbursementCountiesCode: ''
}, },
pageType: 1, pageType: 1,
accountForm: { accountForm: {
objectType: '0', objectType: 0,
accountType: '0', accountType: 0,
branchBankCode: '', branchBankCode: '',
accountName: '', accountName: '',
accountNo: '', accountNo: '',
accountCity: '', bankCity: '',
payeeIDCardType: '', payeeIDCardType: '',
payeeIDCardNo: '', payeeIDCardNo: '',
payeePhone: '', payeePhone: '',
...@@ -72,6 +76,9 @@ export default { ...@@ -72,6 +76,9 @@ export default {
this.handleFormInfo(urlQuery.contractNo, urlQuery.isGH) this.handleFormInfo(urlQuery.contractNo, urlQuery.isGH)
// if(!this.isGH){ // if(!this.isGH){
// } // }
if (this.routeInfo.orderId) {
this.getDetailById()
}
}, },
computed: { computed: {
totalPrice() { totalPrice() {
...@@ -83,6 +90,42 @@ export default { ...@@ -83,6 +90,42 @@ export default {
}, },
mounted() {}, mounted() {},
methods: { methods: {
//详情
getDetailById() {
this.$apis.claims.getClaimsDetail({ id: this.routeInfo.orderId }).then(res => {
console.log(res, 852)
// 以下是report数据
for (let key in this.editForm) {
this.editForm[key] = res[key]
}
this.editForm.reportDate = res.reporterDate
this.editForm.reimbursementAddress = []
const { reimbursementCityCode, reimbursementCountiesCode, reimbursementProvinceCode, serviceItemsList } = res
this.editForm.reimbursementAddress.push(reimbursementProvinceCode, reimbursementCityCode, reimbursementCountiesCode)
// 以下是repair数据
for (let key in this.accountForm) {
this.accountForm[key] = res[key]
}
this.serviceItemsList = serviceItemsList
// 以下是文件数据
res.files.forEach(item => {
let obj = { url: item.fileUrl, fileType: item.fileType, name: item.fileName, progress: 100 }
if (item.fileCode == '1') {
if (item.fileName.indexOf('&front&_') === 0) {
this.materialForm.idCard.push(obj)
} else {
this.materialForm.idCardBack.push(obj)
}
} else if (item.fileCode == '31') {
this.materialForm.billInfo.push(obj)
} else if (item.fileCode == '4') {
this.materialForm.otherInfo.push(obj)
}
})
console.log(this.materialForm, 8989)
})
},
// 新增的时候,输入合同号,带出信息
toSearchOrderDetail() { toSearchOrderDetail() {
let param = {} let param = {}
param.contractNo = this.editForm.contractNo param.contractNo = this.editForm.contractNo
...@@ -94,10 +137,10 @@ export default { ...@@ -94,10 +137,10 @@ export default {
targetAPI(param).then(res => { targetAPI(param).then(res => {
console.log(res, 123) console.log(res, 123)
if (res.code == '0') { if (res.code == '0') {
const { reporterName, reporterPhone, serviceItemsList } = res.data const { reporterName, reporterPhone, serviceItemsList, contractNo } = res.data
this.editForm = { ...this.editForm, reporterName, reporterPhone } this.editForm = { ...this.editForm, reporterName, reporterPhone }
console.log(serviceItemsList)
this.serviceItemsList = serviceItemsList this.serviceItemsList = serviceItemsList
this.getAccountInfo(contractNo)
} else { } else {
this.$message({ this.$message({
message: res.message, message: res.message,
...@@ -106,9 +149,17 @@ export default { ...@@ -106,9 +149,17 @@ export default {
} }
}) })
}, },
// 处理表单数据 // 新增的时候,输入合同号。默认收款人的信息
handlerForm() { getAccountInfo(contractNo) {
console.log(this.editForm) this.$apis.claims.getAccountInfo({ contractNo }).then(res => {
console.log(res)
const { accountName, accountCityCode: bankCity, openBankCode: branchBankCode, accountNo, accountType, cardNo: payeeIDCardNo, cardTypeCode: payeeIDCardType, phone: payeePhone } = res || {}
const result = { accountName, bankCity, branchBankCode, accountNo, accountType, payeeIDCardNo, payeeIDCardType, payeePhone }
// for (let key in this.accountForm) {
// this.accountForm[key] = result[key] || this.accountForm[key]
// }
this.accountForm = { ...this.accountForm, ...result }
})
}, },
// 根据页面跳转参数处理表单信息-自动填入 // 根据页面跳转参数处理表单信息-自动填入
// 步骤流程:拿到核销码/合同号后==》请求接口获取该合同号/核销码下对应的套餐,下发数据到维修信息模块,上传资料模块,报案信息模块 // 步骤流程:拿到核销码/合同号后==》请求接口获取该合同号/核销码下对应的套餐,下发数据到维修信息模块,上传资料模块,报案信息模块
...@@ -118,6 +169,7 @@ export default { ...@@ -118,6 +169,7 @@ export default {
} }
this.editForm.contractNo = contractNo this.editForm.contractNo = contractNo
}, },
// 提交的时候校验,滴加不校验经办人信息
validAccountInfo() { validAccountInfo() {
let valid = false let valid = false
this.$refs.repairRef.$refs.accountRef.$refs.formRef.validate(aValid => { this.$refs.repairRef.$refs.accountRef.$refs.formRef.validate(aValid => {
...@@ -132,16 +184,72 @@ export default { ...@@ -132,16 +184,72 @@ export default {
} }
}) })
}) })
this.serviceItemsList.forEach(item => {
if (item.approveAmount <= 0) {
this.$message({
message: `请输入${item.serviceItemName}的金额,必须大于0`,
type: 'error'
})
valid = false
}
})
return valid return valid
}, },
// 提交核赔
confirmSubmit(type) { confirmSubmit(type) {
if (type == 1 && !this.validAccountInfo()) { if (type == 1 && !this.validAccountInfo()) {
return false return false
} }
const params = { ...this.editForm, ...this.accountForm }
params.operation = type
params.reimbursementDate = params.reimbursementDate ? util.dateFormat(params.reimbursementDate, 'YYYY-MM-DD HH:mm:ss') : ''
params.reportDate = params.reportDate ? util.dateFormat(params.reportDate, 'YYYY-MM-DD HH:mm:ss') : ''
if (params.reimbursementAddress.length == 3) {
params.reimbursementProvinceCode = params.reimbursementAddress[0]
params.reimbursementCityCode = params.reimbursementAddress[1]
params.reimbursementCountiesCode = params.reimbursementAddress[2]
}
params.approveAmounts = ''
let tagetObj = {}
this.serviceItemsList.forEach(item => {
tagetObj[item.serviceItemCode] = item.approveAmount
})
params.approveAmounts = JSON.stringify(tagetObj)
delete params.reimbursementAddress
params.fileList = []
for (let key in this.materialForm) {
this.materialForm[key].forEach((item, index) => {
const obj = {}
obj.fileType = item.fileType
obj.fileUrl = item.url
obj.fileCode = key == 'idCard' || key == 'idCardBack' ? 1 : key == 'billInfo' ? 31 : 4
obj.fileName = item.name
params.fileList.push(obj)
})
}
if (this.routeInfo.orderId) {
params.id = this.routeInfo.orderId
}
this.$apis.claims.commitClaimsOrder(params).then(res => {
console.log(res)
if (res.code == '0') {
this.$message({
message: type == 1 ? '提交成功' : '保存草稿成功',
type: 'success'
})
this.handleCancel()
} else {
this.$message({
message: res.message,
type: 'error'
})
}
})
console.log(this.editForm, this.accountForm, this.materialForm, this.serviceItemsList, this.totalPrice) console.log(this.editForm, this.accountForm, this.materialForm, this.serviceItemsList, this.totalPrice)
}, },
handleCancel() { handleCancel() {
this.$router.back() this.$router.push({ path: '/claims/index' })
} }
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!