Commit 3a7b8407 by 杨明

Merge branch 'master' into 'v3.18.0'

Master

See merge request !41
2 parents 788c6d6c 17273400

6.25 KB | W: | H:

11.4 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

7.08 KB | W: | H:

12 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
...@@ -38,7 +38,8 @@ export default { ...@@ -38,7 +38,8 @@ export default {
}, },
blurFn(e){ blurFn(e){
let value = e.target.value let value = e.target.value
if(this.minVal && +this.minVal>=value) value = this.minVal if(this.minVal && +this.minVal>=value) value = this.minVal+''
if(value && value.charAt(value.length-1)=='.') value = value.substr(0 ,value.length-1)
this.$emit('input', value) this.$emit('input', value)
} }
} }
......
...@@ -169,7 +169,7 @@ export default { ...@@ -169,7 +169,7 @@ export default {
}, },
labelPaddingRight: { labelPaddingRight: {
type: Number, type: Number,
default: 15 default: 8
}, },
formData: { formData: {
type: Array, type: Array,
......
<template>
<div class="element">
<label class="element_label">
<span v-if="isRequire" class="require">*</span>
{{ title }}:
</label>
<div class="wrapper">
<div class="upload_wrap">
<!-- 0 是默认上传类型 -->
<template v-if="uploadType == 0">
<template v-if="imagesList.length">
<div v-for="(imgItem, i) in imagesList" :key="i" class="imagBox">
<img class="imgItem" :src="imgItem" alt="" />
<div class="img_mask">
<i @click="handlePictureCardPreview(imgItem)" class="el-icon-zoom-in"></i>
<i v-if="!disabled" @click="toDeleteImg(index, i)" class="el-icon-delete"></i>
</div>
</div>
</template>
<div v-if="!(imagesList.length == limitNum)" class="upload-value">
<el-upload :disabled="disabled" list-type="picture" class="upload_item" action="#" :before-upload="e => beforeAvatarUpload(e)" :on-remove="e => handleRemove(e, index)" :http-request="e => httpRequest(e, index)">
<img class="img" slot="default" :src="upload_img" alt="" />
</el-upload>
</div>
</template>
<!-- 1 代表的是身份证、驾驶证等类型 -->
<template v-if="uploadType == 1">
<template v-for="count in 2">
<div v-if="(count == 1 && cardImg.font) || (count == 2 && cardImg.reverse)" :key="count" class="imagBox wid180">
<img class="imgItem wid180" :src="count == 2 ? cardImg.reverse : cardImg.font" alt="" />
<div class="img_mask wid180">
<i @click="handlePictureCardPreview(count == 2 ? cardImg.reverse : cardImg.font)" class="el-icon-zoom-in"></i>
<i v-if="!disabled" @click="removeCard(count)" class="el-icon-delete"></i>
</div>
</div>
</template>
<template v-for="count in 2">
<div v-if="(count == 1 && !cardImg.font&&!disabled) || (count == 2 && !cardImg.reverse&&!disabled)" :key="count" class="upload-value upload-value-max marRight-13">
<el-upload :disabled="disabled" list-type="picture" class="upload_item" action="#" :before-upload="e => beforeAvatarUpload(e)" :on-remove="e => handleRemove(e, index)" :http-request="e => httpRequest(e, count)">
<img class="img" slot="default" :src="count == 2 ? idCardBack_img : idCard_img" alt="" />
</el-upload>
</div>
</template>
</template>
</div>
<div class="tip">
图片格式为jpg,jpeg,png,大小10M以内
<span v-if="limitNum > 8 && uploadType == 0">,最多可上传{{ limitNum }}张</span>
</div>
</div>
<el-dialog :visible.sync="dialogVisible">
<img width="100%" :src="dialogImageUrl" alt="" />
</el-dialog>
</div>
</template>
<script type="text/ecmascript-6">
import upload_img from '@/assets/beforeSale/upload.png'
import idCard_img from '@/assets/beforeSale/idCard.png'
import idCardBack_img from '@/assets/beforeSale/idCardBack.png'
export default {
name: 'uploadHandler',
props: {
title: {
type: String,
default: '其他'
},
imagesList: Array,
uploadType: {
type: Number,
default: 0
},
limitNum: {
type: Number,
default: 100
},
cardImg: Object,
disabled:Boolean,
isRequire:Boolean
},
data() {
return {
upload_img,
idCard_img,
idCardBack_img,
dialogVisible: false,
hideUpload: false
}
},
mounted() {},
methods: {
toDeleteImg(index, i) {
this.imagesList.splice(i, 1)
this.$emit('getImages', this.imagesList)
},
removeCard(count) {
if (count == 1) {
this.cardImg.font = ''
} else {
this.cardImg.reverse = ''
}
this.$emit('getCardImg', {detail:this.cardImg,type:count})
},
handlePictureCardPreview(url) {
this.dialogImageUrl = url
this.dialogVisible = true
},
beforeAvatarUpload(e) {
return new Promise((resolve, reject) => {
let AllImgExt = '.png|.jpg|.jpeg'
let extName = e.name.substring(e.name.lastIndexOf('.')).toLowerCase()
if (AllImgExt.indexOf(extName) === -1) {
this.$message.error('上传格式不正确')
return reject(false)
}
const size = e.size / 1024 / 1024
let maxSize = 10
let filetype = this.getFileType(e.type)
if (filetype == 'image') {
maxSize = 10
} else {
maxSize = 30
}
if (size > maxSize) {
this.$message.error(`上传文件不可超过${maxSize}M`)
return reject(false)
}
return resolve(true)
})
},
httpRequest({ file: e }, count) {
let size = e.size / 1024 / 1024
let loading = null
// 大于2给loading
if (size > 2) {
loading = this.$loading({
lock: true,
text: 'Loading',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.3)'
})
}
// // 转码base64
const reader = new FileReader()
reader.readAsDataURL(e)
reader.onload = event => {
const imgFile = event.target.result
const arrBase64 = imgFile.split(',')
const targetNameList = e.name.split('.')
const fileInfo = targetNameList[targetNameList.length - 1] + '@' + arrBase64[1]
const fileType = this.getFileType(e.type)
const paramObj = { file: fileInfo, fileType: fileType }
let param = {}
param.fileList = [paramObj]
this.$apis.common.uploadFileApi(param, res => {
if (loading != null) {
loading.close()
loading = null
}
// let progress = ((res.loaded / res.total) * 100).toFixed(2)
// if (progress > 90) {
// progress = 90
// }
}).then(res => {
if (res.code == 0) {
const url = res.data[0]
if (this.uploadType == 0) {
this.imagesList.push(url)
this.$emit('getImages', this.imagesList)
} else if (this.uploadType == 1) {
if (count == 1) {
this.cardImg.font = url
} else {
this.cardImg.reverse = url
}
this.$emit('getCardImg', {detail:this.cardImg,type:count})
}
}
})
}
},
handleRemove(e, fieldName) {
if (e.status == 'ready') return
},
getFileType(type) {
if (!type) return 'doc'
if (type.indexOf('image') > -1) {
return 'image'
} else {
return 'doc'
}
}
}
}
</script>
<style lang="scss" scoped>
.element {
display: flex;
margin-bottom: 20px;
.element_label {
width: 154px;
font-weight: 400;
font-size: 14px;
color: #333333;
text-align: right;
.require {
color: red;
}
}
.wrapper {
width: 650px;
.upload_wrap {
display: flex;
flex-wrap: wrap;
.imagBox {
position: relative;
.imgItem {
width: 104px;
height: 104px;
border-radius: 4px;
margin-right: 10px;
margin-bottom: 10px;
border: 1px dashed #00000026;
}
.img_mask {
display: none;
}
}
.imagBox:hover {
.img_mask {
display: block;
width: 104px;
height: 104px;
border-radius: 4px;
position: absolute;
left: 0;
top: 0;
right: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.4);
transition: opacity 0.3s;
display: flex;
align-items: center;
justify-content: center;
i {
color: white;
cursor: pointer;
font-weight: 400;
font-size: 21px;
}
i:first-child {
margin-right: 12px;
}
i:last-child {
margin-right: 0;
}
}
}
}
.upload-value {
width: 104px;
height: 104px;
border: 1px dashed #00000026;
border-radius: 4px;
.upload_item {
width: 104px;
height: 104px;
.img {
width: 104px;
height: 104px;
border-radius: 4px;
}
/deep/.el-upload-list--picture {
display: none;
}
}
}
.upload-value-max {
width: 180px;
.upload_item {
width: 180px;
.img {
width: 180px;
}
}
}
.wid180 {
width: 180px !important;
margin-right: 13px;
}
.marRight-13 {
margin-right: 13px;
}
.tip {
font-weight: 400;
font-size: 14px;
color: #999999;
margin-top: 8px;
}
}
}
</style>
...@@ -78,7 +78,7 @@ ...@@ -78,7 +78,7 @@
</el-select> </el-select>
</template> </template>
<template v-if="attr.attributeType == 'datePicker'"> <template v-if="attr.attributeType == 'datePicker'">
<el-date-picker class="arrt_pannel" :picker-options="attr.attributeName == 'additional_date' ? pickerOptions2 : pickerOptions" :disabled="disabled || attr.disabled" @change="getCurChangeDate($event, item, attr)" v-model="productModal[item.idName][attr.attributeName]" size="small" type="date" :placeholder="'请选择' + attr.attributeDesc"></el-date-picker> <el-date-picker class="arrt_pannel" :picker-options="limitData.includes(attr.attributeName) ? pickerOptions2 : pickerOptions" :disabled="disabled || attr.disabled" @change="getCurChangeDate($event, item, attr)" v-model="productModal[item.idName][attr.attributeName]" size="small" type="date" :placeholder="'请选择' + attr.attributeDesc"></el-date-picker>
</template> </template>
</div> </div>
</div> </div>
...@@ -131,15 +131,16 @@ ...@@ -131,15 +131,16 @@
</div> </div>
<div class="arrt_pannel"> <div class="arrt_pannel">
<template v-if="attr.attributeType == 'input'"> <template v-if="attr.attributeType == 'input'">
<el-input class="arrt_pannel" :disabled="disabled || attr.disabled || (attr.attributeName == 'compensation_name' && compensationNameDisable)" @input="getCurChangeInput($event, item, attr, index, attrindex, 2)" v-model="productModal[item.idName][attr.attributeName]" size="small" :maxlength="attr.maxLength" clearable :placeholder="'请输入' + attr.attributeDesc"></el-input> <FormatInput v-if="limitAttrName.includes(attr.attributeName)" class="arrt_pannel" :disabled="disabled || attr.disabled || (attr.attributeName == 'compensation_name' && compensationNameDisable)" @input="getCurChangeInput($event, item, attr, index, attrindex, 2)" v-model="productModal[item.idName][attr.attributeName]" size="small" :maxlength="attr.maxLength" clearable :placeholder="'请输入' + attr.attributeDesc" precise="2" intDigit="10"></FormatInput>
<el-input v-else class="arrt_pannel" :disabled="disabled || attr.disabled || (attr.attributeName == 'compensation_name' && compensationNameDisable)" @input="getCurChangeInput($event, item, attr, index, attrindex, 2)" v-model="productModal[item.idName][attr.attributeName]" size="small" :maxlength="attr.maxLength" clearable :placeholder="'请输入' + attr.attributeDesc"></el-input>
</template> </template>
<template v-if="attr.attributeType == 'select'"> <template v-if="attr.attributeType == 'select'">
<el-select class="arrt_pannel" :disabled="disabled || attr.disabled" size="small" @change="getCurChangeSelect($event, item, attr)" v-model="productModal[item.idName][attr.attributeName]" clearable :placeholder="'请选择' + attr.attributeDesc"> <el-select :allow-create="attr.attributeName == 'gearbox'" :remote="attr.attributeName == 'gearbox'" :filterable="attr.attributeName == 'gearbox'" class="arrt_pannel" :disabled="disabled || attr.disabled" size="small" @change="getCurChangeSelect($event, item, attr)" v-model="productModal[item.idName][attr.attributeName]" clearable :placeholder="'请选择' + attr.attributeDesc">
<el-option v-for="option in attr.optionList" :key="option.value" :label="option.label" :value="option.value"></el-option> <el-option v-for="option in attr.optionList" :key="option.value" :label="option.label" :value="option.value"></el-option>
</el-select> </el-select>
</template> </template>
<template v-if="attr.attributeType == 'datePicker'"> <template v-if="attr.attributeType == 'datePicker'">
<el-date-picker class="arrt_pannel" :picker-options="attr.attributeName == 'additional_date' ? pickerOptions2 : pickerOptions" :disabled="disabled || attr.disabled" @change="getCurChangeDate($event, item, attr)" v-model="productModal[item.idName][attr.attributeName]" size="small" type="date" :placeholder="'请选择' + attr.attributeDesc"></el-date-picker> <el-date-picker class="arrt_pannel" :picker-options="limitData.includes(attr.attributeName) ? pickerOptions2 : pickerOptions" :disabled="disabled || attr.disabled" @change="getCurChangeDate($event, item, attr)" v-model="productModal[item.idName][attr.attributeName]" size="small" type="date" :placeholder="'请选择' + attr.attributeDesc"></el-date-picker>
</template> </template>
</div> </div>
</div> </div>
...@@ -152,6 +153,11 @@ ...@@ -152,6 +153,11 @@
</div> </div>
</div> </div>
<!-- 上传资料 -->
<template v-if="showUploadInfo">
<uploadInfo :imgsQuery="attachmentListQuery" :disabled="disabled" :cardImg="cardImg" :uploadMessage="uploadMessage" @getAttachmentList="getAttachmentList"></uploadInfo>
</template>
<!-- 其他信息 --> <!-- 其他信息 -->
<div class="container m-t-10"> <div class="container m-t-10">
<p class="edit-title">其他信息</p> <p class="edit-title">其他信息</p>
...@@ -183,6 +189,8 @@ import glsxCombiForm from '@/components/glsx-combi-form' ...@@ -183,6 +189,8 @@ import glsxCombiForm from '@/components/glsx-combi-form'
import qrCode from '@/components/qr-code' import qrCode from '@/components/qr-code'
import { fetchConfig } from '@/config' import { fetchConfig } from '@/config'
import utils from '../../util/util' import utils from '../../util/util'
import uploadInfo from './uploadInfo.vue'
import FormatInput from '@/components/FormatInput'
export default { export default {
name: 'editEquity', name: 'editEquity',
data() { data() {
...@@ -664,7 +672,54 @@ export default { ...@@ -664,7 +672,54 @@ export default {
hotline: '', hotline: '',
compensationNameDisable: false, compensationNameDisable: false,
errGlassName: '', errGlassName: '',
dataSourceDisable: false dataSourceDisable: false,
// 日期限制属性
limitData: ['vehicle_registration_date', 'additional_date'],
// 上传资料默认属性
uploadMessage: {
buyCar: [],
mileage: [],
others: []
},
cardImg: {
font: '',
reverse: ''
},
attachmentListQuery: [],
// 延保变速箱
gearboxOptions: [
{
value: 'MT变速箱',
label: 'MT变速箱'
},
{
value: 'AMT变速箱',
label: 'AMT变速箱'
},
{
value: 'AT变速箱',
label: 'AT变速箱'
},
{
value: 'CVT变速箱',
label: 'CVT变速箱'
},
{
value: 'DCT变速箱',
label: 'DCT变速箱'
}
],
operationalOptions: [
{
label: '非营运',
value: '1'
},
{
label: '营运',
value: '0'
}
],
limitAttrName:['warranty_km','vehicle_displacement','mileage','warranty_period']
} }
}, },
...@@ -688,7 +743,9 @@ export default { ...@@ -688,7 +743,9 @@ export default {
components: { components: {
glsxCombiForm, glsxCombiForm,
qrCode qrCode,
uploadInfo,
FormatInput
}, },
async created() { async created() {
...@@ -899,6 +956,9 @@ export default { ...@@ -899,6 +956,9 @@ export default {
attributeName: 'planId' attributeName: 'planId'
} }
this.commonPart(this.productModal[`vip${item.packageCode}`]['planId'], item, customAttr) this.commonPart(this.productModal[`vip${item.packageCode}`]['planId'], item, customAttr)
if (item.printType == 2) {
this.showUploadInfo = true
}
} else { } else {
this.checkCodeList = this.checkCodeList.filter(t => t != item.packageCode) this.checkCodeList = this.checkCodeList.filter(t => t != item.packageCode)
this.autoPackageCodeList = this.autoPackageCodeList.filter(t => t != item.packageCode) this.autoPackageCodeList = this.autoPackageCodeList.filter(t => t != item.packageCode)
...@@ -909,6 +969,9 @@ export default { ...@@ -909,6 +969,9 @@ export default {
} }
}) })
} }
if (item.printType == 2) {
this.showUploadInfo = false
}
} }
}, },
// 获取店铺信息 // 获取店铺信息
...@@ -986,7 +1049,8 @@ export default { ...@@ -986,7 +1049,8 @@ export default {
attributeName: attr.attributeName, attributeName: attr.attributeName,
attributeValue: e, attributeValue: e,
sort: 0, sort: 0,
packageCode: pack.packageCode packageCode: pack.packageCode,
printType: pack.printType
} }
this.productModal[pack.idName] = { this.productModal[pack.idName] = {
...temp, ...temp,
...@@ -1080,9 +1144,11 @@ export default { ...@@ -1080,9 +1144,11 @@ export default {
blackArr[j].push(obj) blackArr[j].push(obj)
let attrStr = `attributes[${j}].packageCode` let attrStr = `attributes[${j}].packageCode`
let contractNoStr = `attributes[${j}].contractNo` let contractNoStr = `attributes[${j}].contractNo`
let printType = `attributes[${j}].printType`
let temp = { let temp = {
[attrStr]: codeList[j], [attrStr]: codeList[j],
[contractNoStr]: arr[i].contractNo [contractNoStr]: arr[i].contractNo,
[printType]: arr[i].printType
} }
newArr.push(temp) newArr.push(temp)
} }
...@@ -1194,27 +1260,39 @@ export default { ...@@ -1194,27 +1260,39 @@ export default {
e.optionList = this.baseData.servicePeriodList2 e.optionList = this.baseData.servicePeriodList2
} }
e.disabled = true e.disabled = true
if(this.routeInfo.addOrEdit==3){ if (this.routeInfo.addOrEdit == 3) {
e.disabled = false e.disabled = false
} }
// v3.1.2--新版的定制权益-服务期限--改为1,2,3年---旧版的依然是一年 // v3.1.2--新版的定制权益-服务期限--改为1,2,3年---旧版的依然是一年
let isOld = item.packageName.includes('尊享版') || item.packageName.includes('舒享版') || item.packageName.includes('优享版') let isOld = item.packageName.includes('尊享版') || item.packageName.includes('舒享版') || item.packageName.includes('优享版')
if (item.idName == `vip${item.packageCode}` && !isOld) { if (item.idName == `vip${item.packageCode}` && !isOld) {
e.disabled = false e.disabled = false
e.optionList = this.baseData.servicePeriodList e.optionList = this.baseData.servicePeriodList
// 延保
if (item.printType == 2) {
const _servicePeriodList = item.servicePeriod.split('')
let _optis = []
_servicePeriodList.forEach(itm => {
let _objj = { value: itm, label: `${itm}年` }
_optis.push(_objj)
})
e.optionList = _optis
}
} }
// this.productModal[item.idName][e.attributeName] = '1' this.$set(this.productModal[item.idName], `${e.attributeName}`, e.optionList[0].value)
this.$set(this.productModal[item.idName], `${e.attributeName}`, '1')
} else if (e.attributeDesc == '生效日期') { } else if (e.attributeDesc == '生效日期') {
let nextDay = new Date().getTime() + 24 * 60 * 60 * 1000 let nextDay = new Date().getTime() + 24 * 60 * 60 * 1000
// this.productModal[item.idName][e.attributeName] = utils.dateFormat(nextDay)
this.$set(this.productModal[item.idName], `${e.attributeName}`, utils.dateFormat(nextDay)) this.$set(this.productModal[item.idName], `${e.attributeName}`, utils.dateFormat(nextDay))
if (item.idName == 'glass') { if (item.idName == 'glass') {
let tAdd2 = new Date().getTime() + 24 * 60 * 60 * 1000 * 2 let tAdd2 = new Date().getTime() + 24 * 60 * 60 * 1000 * 2
// this.productModal[item.idName][e.attributeName] = utils.dateFormat(tAdd2)
this.$set(this.productModal[item.idName], `${e.attributeName}`, utils.dateFormat(tAdd2)) this.$set(this.productModal[item.idName], `${e.attributeName}`, utils.dateFormat(tAdd2))
e.disabled = true e.disabled = true
} }
} else if (e.attributeName === 'gearbox') {
e.optionList = this.gearboxOptions
} else if (e.attributeName === 'vehicle_nature') {
e.optionList = this.operationalOptions
this.$set(this.productModal[item.idName], `${e.attributeName}`, e.optionList[0].value)
} }
ele.tempobj = { ...e } ele.tempobj = { ...e }
}) })
...@@ -1377,7 +1455,7 @@ export default { ...@@ -1377,7 +1455,7 @@ export default {
if (ele.attributeName == 'service_period' && this.routeInfo.addOrEdit == 4) { if (ele.attributeName == 'service_period' && this.routeInfo.addOrEdit == 4) {
ele.disabled = true ele.disabled = true
} }
if (ele.attributeName == 'card'&& this.routeInfo.addOrEdit == 4) { if (ele.attributeName == 'card' && this.routeInfo.addOrEdit == 4) {
ele.disabled = true ele.disabled = true
} }
if (ele.attributeName == 'effective_date' && this.routeInfo.addOrEdit == 4) { if (ele.attributeName == 'effective_date' && this.routeInfo.addOrEdit == 4) {
...@@ -1425,7 +1503,7 @@ export default { ...@@ -1425,7 +1503,7 @@ export default {
if (elee.attributeName == 'service_period' && this.routeInfo.addOrEdit == 4) { if (elee.attributeName == 'service_period' && this.routeInfo.addOrEdit == 4) {
elee.disabled = true elee.disabled = true
} }
if (elee.attributeName == 'card'&& this.routeInfo.addOrEdit == 4) { if (elee.attributeName == 'card' && this.routeInfo.addOrEdit == 4) {
elee.disabled = true elee.disabled = true
} }
if (elee.attributeName == 'effective_date' && this.routeInfo.addOrEdit == 4) { if (elee.attributeName == 'effective_date' && this.routeInfo.addOrEdit == 4) {
...@@ -1451,13 +1529,17 @@ export default { ...@@ -1451,13 +1529,17 @@ export default {
}) })
} }
} }
if (targetItem.printType == 2) {
this.showUploadInfo = true
}
packCode.push(item.packageCode) packCode.push(item.packageCode)
item.attributeDTOList.forEach(el => { item.attributeDTOList.forEach(el => {
attrList.push({ attrList.push({
...el, ...el,
packageCode: item.packageCode, packageCode: item.packageCode,
contractNo: item.contractNo contractNo: item.contractNo,
printType: item.printType
}) })
}) })
}) })
...@@ -1470,35 +1552,34 @@ export default { ...@@ -1470,35 +1552,34 @@ export default {
} }
this.checkCodeList = packCode this.checkCodeList = packCode
this.handleProductArrParam(attrList, packCode) this.handleProductArrParam(attrList, packCode)
// this.editRulePro = {} this.handlerImagesFile(detailInfo)
// this.editFormPro = {} },
// var attrName = '' // 处理延保图片资料
// targetItem && handlerImagesFile(detailInfo) {
// targetItem.groupAttributeList.forEach(item => { if (this.showUploadInfo) {
// if (item.attributeList.length == 1) { const { attachmentList } = detailInfo
// attrName = item.attributeList[0].attributeName let _temArr = []
// this.$set(this.editFormPro, attrName, tempObj.hasOwnProperty(attrName) ? tempObj[attrName] : '') attachmentList.forEach(el => {
// if (item.attributeList[0].required == 1) { if (el.attachmentCode === 'YB0001') {
// this.editRulePro[item.attributeList[0].attributeName] = [ this.uploadMessage.buyCar.push(el.attachmentFile)
// { } else if (el.attachmentCode === 'YB0002') {
// required: true, this.uploadMessage.mileage.push(el.attachmentFile)
// message: '请输入' + item.attributeList[0].attributeDesc, } else if (el.attachmentCode === 'YB0003') {
// trigger: 'change' this.cardImg.font = el.attachmentFile
// } } else if (el.attachmentCode === 'YB0004') {
// ] this.cardImg.reverse = el.attachmentFile
// } } else if (el.attachmentCode === 'YB0005') {
// } else { this.uploadMessage.others.push(el.attachmentFile)
// for (var i = 0; i < item.num; i++) { }
// item.attributeList.forEach(k => { let obj = {
// attrName = k.attributeName attachmentCode: el.attachmentCode,
// this.$set(this.editFormPro, attrName + i, tempObj.hasOwnProperty(attrName + i) ? tempObj[attrName + i] : '') attachmentFile: el.attachmentFile,
// }) attachmentType: el.attachmentType
// } }
// } _temArr.push(obj)
// }) })
// if (recovery) { this.attachmentListQuery = _temArr
// this.recoveryEditFormPro() }
// }
}, },
recoveryEditFormPro() { recoveryEditFormPro() {
this.editForm.attributeList.length && this.editForm.attributeList.length &&
...@@ -1786,6 +1867,10 @@ export default { ...@@ -1786,6 +1867,10 @@ export default {
if (!params.attributes) { if (!params.attributes) {
params.attributes = [] params.attributes = []
} }
if (this.showUploadInfo) {
params.attachmentList = this.attachmentList || []
}
params.attachmentList = params.attachmentList || []
params = Object.assign(params, vaidObj) params = Object.assign(params, vaidObj)
this.updateEquity(params) this.updateEquity(params)
}, },
...@@ -1840,72 +1925,87 @@ export default { ...@@ -1840,72 +1925,87 @@ export default {
} }
}, },
handleConfirm() { handleConfirm() {
this.vaildGlassParams() try {
const vaidObj = this.equityRadio == 1 ? this.formatProduct : this.autoFormatProduct this.vaildGlassParams()
const isEmptyObj = JSON.stringify(vaidObj) == '{}' const vaidObj = this.equityRadio == 1 ? this.formatProduct : this.autoFormatProduct
if (isEmptyObj) { const isEmptyObj = JSON.stringify(vaidObj) == '{}'
this.$message({ message: '请选择产品信息', type: 'error' }) if (isEmptyObj) {
return this.$message({ message: '请选择产品信息', type: 'error' })
} return
if (this.submit) {
return true
}
this.submit = true
var list = ['Car', 'Brand', 'User', 'Shop', 'Other']
var flag = true
var errorObjList = []
for (var i = 0; i < list.length; i++) {
if (this.$refs['editFormRef' + list[i]]) {
var pRef = this.$refs['editFormRef' + list[i]]
pRef.$refs['editChildRef' + list[i]].validate((valid, errorObj) => {
!valid && errorObjList.push(errorObj)
flag && (flag = valid)
})
} }
} if (this.submit) {
if (!flag) { return true
this.whereToGo(Object.keys(errorObjList[0])[0])
this.submit = false
return true
}
var params = this.getParams()
delete params.attributes
params.operationType = 1
if ([2, 3, 4].includes(this.routeInfo.addOrEdit)) {
if (this.routeInfo.addOrEdit == 4 && this.editForm.orderStatus != 3) {
params.contractNo = ''
} else {
params.contractNo = this.routeInfo.contractNo
} }
} else { this.submit = true
params.contractNo = '' var list = ['Car', 'Brand', 'User', 'Shop', 'Other']
} var flag = true
const productflag = this.vaidProduct() var errorObjList = []
if (productflag) { for (var i = 0; i < list.length; i++) {
return if (this.$refs['editFormRef' + list[i]]) {
} var pRef = this.$refs['editFormRef' + list[i]]
params = { pRef.$refs['editChildRef' + list[i]].validate((valid, errorObj) => {
...params, !valid && errorObjList.push(errorObj)
...vaidObj flag && (flag = valid)
} })
this.$apis.beforeSale.checkOrderApi({ vin: this.editForm.vehicle.vin, contractNo: this.routeInfo.contractNo || '' }).then(res => { }
if (res.code == '0') { }
this.updateEquity(params) if (!flag) {
} else { this.whereToGo(Object.keys(errorObjList[0])[0])
this.submit = false this.submit = false
this.$confirm(res.message, '提示', { return true
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
callback: action => {
if (action == 'confirm') {
this.submit = true
this.updateEquity(params)
}
}
})
} }
}) var params = this.getParams()
delete params.attributes
params.operationType = 1
if ([2, 3, 4].includes(this.routeInfo.addOrEdit)) {
if (this.routeInfo.addOrEdit == 4 && this.editForm.orderStatus != 3) {
params.contractNo = ''
} else {
params.contractNo = this.routeInfo.contractNo
}
} else {
params.contractNo = ''
}
const productflag = this.vaidProduct()
if (productflag) {
return
}
params = {
...params,
...vaidObj
}
if (this.showUploadInfo) {
const _check = this.checkAttachmentList()
if (_check) {
this.submit = false
this.$message({ message: '请补充全部资料', type: 'error' })
return
}
params.attachmentList = this.attachmentList || []
}
params.attachmentList = params.attachmentList || []
this.$apis.beforeSale.checkOrderApi({ vin: this.editForm.vehicle.vin, contractNo: this.routeInfo.contractNo || '' }).then(res => {
if (res.code == '0') {
this.updateEquity(params)
} else {
this.submit = false
this.$confirm(res.message, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
callback: action => {
if (action == 'confirm') {
this.submit = true
this.updateEquity(params)
}
}
})
}
})
} catch (error) {
console.log(error);
this.submit = false
}
}, },
handleReset() { handleReset() {
this.editForm = { this.editForm = {
...@@ -1972,6 +2072,32 @@ export default { ...@@ -1972,6 +2072,32 @@ export default {
this.$router.push({ this.$router.push({
path: '/beforeSale/checkSet' path: '/beforeSale/checkSet'
}) })
},
// 附件资料
getAttachmentList(e) {
this.attachmentList = e
},
// 校验附件资料是否上传
checkAttachmentList() {
let _code = [],
_typeCode = ['YB0001', 'YB0002', 'YB0003', 'YB0004'],
flag = false
if ((!this.attachmentList || !this.attachmentList.length) && this.attachmentListQuery.length) {
this.attachmentList = this.attachmentListQuery || []
}
if(!this.attachmentList){
this.attachmentList = []
}
this.attachmentList.forEach(el => {
if (_typeCode.includes(el.attachmentCode)) {
_code.push(el.attachmentCode)
}
})
_code = Array.from(new Set(_code))
if (_code.length < 4) {
flag = true
}
return flag
} }
} }
} }
......
<!-- 权益订单列表 --> <!-- 权益订单列表 -->
<template> <template>
<div class="before-sale"> <div class="before-sale">
<div class="flex m-b-10"> <!-- <div class="flex m-b-10">
<el-button :size="size" type="primary" class="el-icon-plus" @click="handleEdit(1)">新增权益</el-button> <el-button :size="size" type="primary" class="el-icon-plus" @click="handleEdit(1)">新增权益</el-button>
<!-- <GLButton :size="size" fn="新增权益" icon="el-icon-plus" type="primary" @click="handleEdit(1)">新增权益</GLButton> --> </div> -->
<!-- <div class="table-top-tips"><span class="el-icon-warning"></span>请注意:订单列表还有{{countNoData}}单未上传客户凭证等资料,若发生事故无法获得补偿,请尽快在列表操作-上传资料中完善。</div> -->
</div>
<div class="container"> <div class="container">
<div class="find_wrap"> <div class="find_wrap">
<GLCombiForm :key="newKey" ref="showSearch" :formObj="searchForm" :searchSelectObj="searchSelectObj" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm> <GLCombiForm :key="newKey" ref="showSearch" :formObj="searchForm" :searchSelectObj="searchSelectObj" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
...@@ -13,7 +11,14 @@ ...@@ -13,7 +11,14 @@
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<div class="table_wrapper"> <div class="table_wrapper">
<el-button plain style="float:right;margin-bottom:10px;" :size="size" @click="handleExport">导出</el-button> <div class="table_top_line flex_scb">
<span>订单列表</span>
<div class="table_top_btn flex_sc">
<el-button :size="size" type="primary" class="el-icon-plus" @click="handleEdit(1)">新增权益</el-button>
<el-button plain size="small" @click="handleExport">导出</el-button>
</div>
</div>
<!-- <el-button plain style="float: right; margin-bottom: 10px" :size="size" @click="handleExport">导出</el-button> -->
<GLTable ref="equityRef" :getListApi="getListApi" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable ref="equityRef" :getListApi="getListApi" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<div class="table-btns" slot="table-btns" slot-scope="scope"> <div class="table-btns" slot="table-btns" slot-scope="scope">
<GLTableButton :buttonList="buttonList" :buttonItem="scope" :buttonNum="3"></GLTableButton> <GLTableButton :buttonList="buttonList" :buttonItem="scope" :buttonNum="3"></GLTableButton>
...@@ -1070,6 +1075,12 @@ export default { ...@@ -1070,6 +1075,12 @@ export default {
// box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1); // box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
padding: 0 20px 20px; padding: 0 20px 20px;
} }
.table_top_line {
margin-bottom: 10px;
}
.el-button + .el-button {
margin-left: 8px;
}
.before-sale .m-b-10 { .before-sale .m-b-10 {
margin-bottom: 10px; margin-bottom: 10px;
......
<template>
<div class="upload-contianer">
<div class="title">上传资料</div>
<div class="widget">
<uploadHandler :isRequire="true" :disabled="disabled" @getImages="getImages($event, 'YB0001')" title="购车发票" limitNum="1" :imagesList="uploadMessage.buyCar"></uploadHandler>
<uploadHandler :isRequire="true" :disabled="disabled" @getImages="getImages($event, 'YB0002')" title="合同购买时里程数" limitNum="1" :imagesList="uploadMessage.mileage"></uploadHandler>
<uploadHandler :isRequire="true" :disabled="disabled" @getCardImg="getCardImg" uploadType="1" title="行驶证" :cardImg="cardImg"></uploadHandler>
<uploadHandler :disabled="disabled" @getImages="getImages($event, 'YB0005')" title="其他" limitNum="9" :imagesList="uploadMessage.others"></uploadHandler>
</div>
</div>
</template>
<script type="text/ecmascript-6">
import upload_img from '@/assets/beforeSale/upload.png'
import uploadHandler from './components/UploadHandler.vue'
export default {
name: 'uploadInfo',
components: {
uploadHandler
},
data() {
return {
upload_img,
dialogVisible: false,
attachmentList: [],
license: [{}, {}]
}
},
props: {
uploadMessage: Object,
cardImg: Object,
disabled: Boolean,
imgsQuery: Array
},
mounted() {},
methods: {
getImages(e, code) {
this.handlerData()
if (code === 'YB0005') {
this.others = []
} else if (code === 'YB0001' && !e.length) {
this.buyCar = []
} else if (code === 'YB0002' && !e.length) {
this.mileage = []
}
e.forEach(url => {
let obj = {
attachmentCode: code,
attachmentFile: url,
attachmentType: 'IMG'
}
if (code === 'YB0001') {
this.buyCar = [obj]
} else if (code === 'YB0002') {
this.mileage = [obj]
} else if (code === 'YB0005') {
this.others.push(obj)
}
})
this.getAllImages()
},
getCardImg(e) {
this.handlerData()
const _value = e.detail,
type = e.type
const _attachmentCode = type == 1 ? 'YB0003' : 'YB0004'
const _attachmentFile = type == 1 ? _value.font : _value.reverse
const _obj = {
attachmentCode: _attachmentCode,
attachmentFile: _attachmentFile,
attachmentType: 'IMG'
}
if (!_attachmentFile && type == 1) {
this.license[0] = {}
} else if (!_attachmentFile && type == 2) {
this.license[1] = {}
} else {
this.license[type - 1] = _obj
}
this.getAllImages()
},
getAllImages() {
let attachmentList = [],
_tempArr1 = [],
_tempArr2 = [],
_tempArr3 = [],
_tempArr4 = []
if (this.buyCar) {
this.buyCar.forEach(e => {
_tempArr1.push(e)
})
}
if (this.mileage) {
this.mileage.forEach(e => {
_tempArr2.push(e)
})
}
if (this.others) {
this.others.forEach(e => {
_tempArr3.push(e)
})
}
if (this.license) {
this.license.forEach(e => {
if (e.attachmentFile) {
_tempArr4.push(e)
}
})
}
attachmentList = [..._tempArr1, ..._tempArr2, ..._tempArr3, ..._tempArr4]
this.$emit('getAttachmentList', attachmentList)
},
handlerData() {
if (this.imgsQuery.length && !this.active) {
this.buyCar = []
this.mileage = []
this.license = [{}, {}]
this.others = []
this.imgsQuery.forEach(el => {
if (el.attachmentCode === 'YB0001') {
this.buyCar = [el]
} else if (el.attachmentCode === 'YB0002') {
this.mileage = [el]
} else if (el.attachmentCode === 'YB0003') {
this.license[0] = el
} else if (el.attachmentCode === 'YB0004') {
this.license[1] = el
} else if (el.attachmentCode === 'YB0005') {
this.others.push(el)
}
})
this.active = true
}
}
}
}
</script>
<style lang="scss" scoped>
.upload-contianer {
background: white;
margin: 10px 0 0;
.title {
font-size: 16px;
font-weight: 600;
padding: 15px 20px;
border-bottom: 1px solid #e7eaec;
margin: 0 0;
}
.widget {
padding: 32px 0px;
}
}
</style>
...@@ -12,8 +12,8 @@ ...@@ -12,8 +12,8 @@
<img v-if="item.name === 'idCard'" slot="default" :src="idCard" alt="" /> <img v-if="item.name === 'idCard'" slot="default" :src="idCard" alt="" />
<img v-if="item.name === 'idCardBack'" slot="default" :src="idCardBack" alt="" /> <img v-if="item.name === 'idCardBack'" slot="default" :src="idCardBack" alt="" />
<el-button v-if="item.name == 'otherInfo'" slot="default" :disabled="renewDisable || pageType == 2 || item.limit == materialForm[item.name].length" size="small" class="el-icon-plus">上传文件</el-button> <el-button v-if="item.name == 'otherInfo'" slot="default" :disabled="renewDisable || pageType == 2 || item.limit == materialForm[item.name].length" size="small" class="el-icon-plus">上传文件</el-button>
<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">支持扩展名:.doc .docx .pdf .jpg .png .jpeg。图片类型大小不能超过9M,其他类型文件大小不能超过30M。</span> <span class="file_tip">支持扩展名:.doc .docx .pdf .jpg .png .jpeg。图片类型大小不能超过9M,其他类型文件大小不能超过30M。</span>
<template> <template>
...@@ -321,7 +321,7 @@ export default { ...@@ -321,7 +321,7 @@ export default {
display: inline-block; display: inline-block;
position: relative; position: relative;
padding-left: 118px; padding-left: 118px;
margin-bottom: 45px; margin-bottom: 20px;
height: 104px; height: 104px;
.require { .require {
position: absolute; position: absolute;
...@@ -330,7 +330,7 @@ export default { ...@@ -330,7 +330,7 @@ export default {
} }
} }
&:nth-child(2) { &:nth-child(2) {
margin-left: 40px; margin-left: 12px;
display: inline-block; display: inline-block;
} }
&:nth-child(3) { &:nth-child(3) {
...@@ -342,7 +342,7 @@ export default { ...@@ -342,7 +342,7 @@ export default {
/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-right: 12px;
margin-bottom: 15px; margin-bottom: 15px;
p { p {
font-size: 14px; font-size: 14px;
...@@ -386,8 +386,8 @@ export default { ...@@ -386,8 +386,8 @@ export default {
position: absolute; position: absolute;
} }
.file-box { .file-box {
margin-top: 8px;
.file_tip { .file_tip {
margin: 8px 0;
font-size: 14px; font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC; font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400; font-weight: 400;
...@@ -398,6 +398,7 @@ export default { ...@@ -398,6 +398,7 @@ export default {
width: 320px; width: 320px;
position: relative; position: relative;
margin-bottom: 4px; margin-bottom: 4px;
margin-top: 8px;
.download { .download {
width: 20px; width: 20px;
height: 18px; height: 18px;
......
<template> <template>
<div class="report-components gl-form-page"> <div class="report-components gl-form-page">
<div class="title">报案信息(客户提交)</div> <div class="title">报案信息(客户提交)</div>
<template v-if="[1, 3, 4].includes(pageType)&&!renewDisable"> <template v-if="[1, 3, 4,5,6].includes(pageType)&&!renewDisable">
<glsxCombiForm :regionData="regionData" class="edit-form-container" ref="editFormRefReport" labelWidth="154px" defaultWidth="432px" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <glsxCombiForm :regionData="regionData" class="edit-form-container" ref="editFormRefReport" labelWidth="154px" defaultWidth="432px" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div v-if="pageType == 1" style="display: inline-block" slot="syncBtn"> <div v-if="pageType == 1" 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>
......
<template>
<div class="warning-contianer">
<div class="title">预警信息</div>
<div class="widget">
<template v-for="(item, index) in list">
<div :key="index" class="element">
<label class="label">风险预警{{ index + 1 }}:</label>
<div class="wrap">
<div class="cell">
<label class="cell-label">预警原因:</label>
<div class="cell-value">{{ matchResultDesc[item.matchResult] }}</div>
</div>
<div class="cell">
<label class="cell-label">具体描述:</label>
<div class="cell-value">{{ item.matchResultDesc }}</div>
</div>
<div class="cell">
<label class="cell-label">核实情况说明:</label>
<el-input :disabled="isWatchOrder || item.matchType==1" @input="inputExplain" class="input-value" v-model="item.verifyResultDesc" type="textarea" placeholder="请输入核实后的情况说明" show-word-limit maxlength="100"></el-input>
</div>
<div class="cell">
<label class="cell-label">核实资料补充:</label>
<div class="inner">
<div class="image_group">
<template v-if="item.accountVerifyImagesList.length">
<div v-for="(imgItem, i) in item.accountVerifyImagesList" :key="i" class="imagBox">
<img class="imgItem" :src="imgItem.verifyImage" alt="" />
<div class="img_mask">
<i @click="handlePictureCardPreview(imgItem.verifyImage)" class="el-icon-zoom-in"></i>
<i v-if="!isWatchOrder&&item.matchType!=1" @click="toDeleteImg(index, i)" class="el-icon-delete"></i>
</div>
</div>
</template>
<div class="upload-value">
<el-upload :disabled="isWatchOrder || item.matchType==1" list-type="picture" class="upload_item" action="#" :before-upload="e => beforeAvatarUpload(e)" :on-remove="e => handleRemove(e, index)" :http-request="e => httpRequest(e, index)">
<img class="img" slot="default" :src="upload_img" alt="" />
</el-upload>
</div>
</div>
<p class="tips">图片格式为jpg,jpeg,png,大小10M以内</p>
</div>
</div>
</div>
</div>
</template>
</div>
<el-dialog :visible.sync="dialogVisible">
<img width="100%" :src="dialogImageUrl" alt="" />
</el-dialog>
</div>
</template>
<script type="text/ecmascript-6">
import upload_img from '@/assets/images/upload.png'
export default {
name: 'wraning',
components: {},
data() {
return {
upload_img,
dialogVisible: false,
matchResultDesc: {
1: '支付账号异常',
2: '金额过大'
}
}
},
props: {
list: Array,
isWatchOrder: Boolean
},
mounted() {},
methods: {
inputExplain() {
this.$emit('getWarningData', this.list)
},
toDeleteImg(index, i) {
this.list[index].accountVerifyImagesList.splice(i, 1)
this.$emit('getWarningData', this.list)
},
handlePictureCardPreview(url) {
this.dialogImageUrl = url
this.dialogVisible = true
},
beforeAvatarUpload(e) {
console.log(e)
return new Promise((resolve, reject) => {
let AllImgExt = '.png|.jpg|.jpeg'
let extName = e.name.substring(e.name.lastIndexOf('.')).toLowerCase()
if (AllImgExt.indexOf(extName) === -1) {
this.$message.error('上传格式不正确')
return reject(false)
}
const size = e.size / 1024 / 1024
let maxSize = 10
let filetype = this.getFileType(e.type)
if (filetype == 'image') {
maxSize = 10
} else {
maxSize = 30
}
if (size > maxSize) {
this.$message.error(`上传文件不可超过${maxSize}M`)
return reject(false)
}
return resolve(true)
})
},
httpRequest({ file: e }, index) {
let size = e.size / 1024 / 1024
let loading = null
// 大于2给loading
if (size > 2) {
loading = this.$loading({
lock: true,
text: 'Loading',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.3)'
})
}
// // 转码base64
const reader = new FileReader()
reader.readAsDataURL(e)
reader.onload = event => {
const imgFile = event.target.result
const arrBase64 = imgFile.split(',')
const targetNameList = e.name.split('.')
const fileInfo = targetNameList[targetNameList.length - 1] + '@' + arrBase64[1]
const fileType = this.getFileType(e.type)
const paramObj = { file: fileInfo, fileType: fileType }
let param = {}
param.fileList = [paramObj]
this.$apis.common
.uploadFileApi(param, res => {
if (loading != null) {
loading.close()
loading = null
}
// let progress = ((res.loaded / res.total) * 100).toFixed(2)
// if (progress > 90) {
// progress = 90
// }
})
.then(res => {
if (res.code == 0) {
const url = res.data[0]
this.list[index].accountVerifyImagesList.push({ verifyImage: url })
this.$emit('getWarningData', this.list)
}
})
}
},
handleRemove(e, fieldName) {
if (e.status == 'ready') return
},
getFileType(type) {
if (!type) return 'doc'
if (type.indexOf('image') > -1) {
return 'image'
} else {
return 'doc'
}
}
}
}
</script>
<style lang="scss" scoped>
.warning-contianer {
background: white;
margin: 20px 0 0;
.title {
padding: 0 20px;
font-size: 16px;
font-weight: bold;
height: 58px;
line-height: 58px;
border-bottom: 1px solid #d8d8d8;
margin: 0 0;
color: #333;
}
.widget {
padding: 32px 20px;
.element {
display: flex;
margin-bottom: 20px;
.label {
width: 154px;
text-align: right;
font-weight: 400;
font-size: 14px;
color: #333333;
}
.wrap {
width: 792px;
background: #f9f9f9;
box-sizing: border-box;
padding: 20px;
.cell {
display: flex;
margin-bottom: 20px;
.cell-label {
width: 134px;
font-weight: 400;
font-size: 14px;
color: #666666;
text-align: right;
}
.cell-value {
font-weight: 400;
font-size: 14px;
color: #333333;
}
.input-value {
width: 580px;
}
.inner {
.image_group {
display: flex;
flex-wrap: wrap;
.imagBox {
position: relative;
.imgItem {
width: 104px;
height: 104px;
border-radius: 4px;
margin-right: 10px;
margin-bottom: 10px;
border: 1px dashed #00000026;
}
.img_mask {
display: none;
}
}
.imagBox:hover {
.img_mask {
display: block;
width: 104px;
height: 104px;
border-radius: 4px;
position: absolute;
left: 0;
top: 0;
right: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.4);
transition: opacity 0.3s;
display: flex;
align-items: center;
justify-content: center;
i {
color: white;
cursor: pointer;
font-weight: 400;
font-size: 21px;
}
i:first-child {
margin-right: 12px;
}
i:last-child {
margin-right: 0;
}
}
}
}
.upload-value {
width: 104px;
height: 104px;
border: 1px dashed #00000026;
border-radius: 4px;
.upload_item {
width: 104px;
height: 104px;
.img {
width: 104px;
height: 104px;
border-radius: 4px;
}
/deep/.el-upload-list--picture {
display: none;
}
}
}
.tips {
font-weight: 400;
font-size: 14px;
color: #999999;
margin-top: 8px;
}
}
}
.cell:last-child {
margin-bottom: 0;
}
}
}
.element:last-child {
margin-bottom: 0;
}
}
}
</style>
<!-- 权益订单 --> <!-- 权益订单 -->
<template> <template>
<div> <div>
<div class="header_btn_widget flex_sc"> <!-- <div class="header_btn_widget flex_sc">
<GLButton size="small" fn="订单详情" icon="el-icon-plus" type="primary" @click="handleEdit(1)">新增核赔</GLButton> <GLButton size="small" fn="订单详情" icon="el-icon-plus" type="primary" @click="handleEdit(1)">新增核赔</GLButton>
</div> </div> -->
<div class="header_info_widget"> <div class="header_info_widget">
<span class="el-icon-warning"></span> <span class="el-icon-warning"></span>
请注意:订单列表还有 请注意:订单列表还有
...@@ -16,8 +16,19 @@ ...@@ -16,8 +16,19 @@
<GLCombiForm :rowNumber="1" ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleOkFn" @handleRest="handleRestFn()"></GLCombiForm> <GLCombiForm :rowNumber="1" ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleOkFn" @handleRest="handleRestFn()"></GLCombiForm>
</div> </div>
<div class="table_widget"> <div class="table_widget">
<el-button plain style="float:right;margin-bottom:10px;" size="small" @click="exportList">导出</el-button> <div class="table_top_line flex_scb">
<span>核赔订单列表</span>
<div class="table_top_btn flex_sc">
<GLButton size="small" fn="订单详情" icon="el-icon-plus" type="primary" @click="handleEdit(1)">新增核赔</GLButton>
<el-button plain size="small" @click="exportList">导出</el-button>
</div>
</div>
<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="flex_sc" slot="colorStatus" slot-scope="scope">
<div class="table_point" :style="{ background: statusMap[scope.scope.status || 0].color }"></div>
<span>{{ statusMap[scope.scope.status || 0].name }}</span>
</div>
<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="[1, 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>
...@@ -54,6 +65,26 @@ const statusList = [ ...@@ -54,6 +65,26 @@ const statusList = [
{ {
confId: 4, confId: 4,
confName: '支付失败' confName: '支付失败'
},
{
confId: 19,
confName: '待核实'
},
{
confId: 21,
confName: '待运营经理审核'
},
{
confId: 22,
confName: '运营经理审核不通过'
},
{
confId: 23,
confName: '待核赔'
},
{
confId: 25,
confName: '核赔不通过'
} }
] ]
export default { export default {
...@@ -68,7 +99,7 @@ export default { ...@@ -68,7 +99,7 @@ export default {
return '去处理' return '去处理'
}, },
condition: row => { condition: row => {
return [0].includes(row.scope.status) return [0, 19, 22, 25].includes(row.scope.status)
}, },
attrs: { attrs: {
type: 'text', type: 'text',
...@@ -84,7 +115,7 @@ export default { ...@@ -84,7 +115,7 @@ export default {
return '查看' return '查看'
}, },
condition: row => { condition: row => {
return [1, 3, 4].includes(row.scope.status) return [1, 3, 4, 21, 24].includes(row.scope.status)
}, },
attrs: { attrs: {
type: 'text', type: 'text',
...@@ -109,6 +140,38 @@ export default { ...@@ -109,6 +140,38 @@ export default {
listeners: { listeners: {
click: row => this.handleEdit(3, row.scope) click: row => this.handleEdit(3, row.scope)
} }
},
{
type: 'GLButton',
name: row => {
return '运营经理审核'
},
condition: row => {
return [21].includes(row.scope.status)
},
attrs: {
type: 'text',
fn: '运营经理审核'
},
listeners: {
click: row => this.handleEdit(5, row.scope)
}
},
{
type: 'GLButton',
name: row => {
return '核赔审核'
},
condition: row => {
return [23].includes(row.scope.status)
},
attrs: {
type: 'text',
fn: '核赔审核'
},
listeners: {
click: row => this.handleEdit(6, row.scope)
}
} }
], ],
getListApi: this.$apis.claims.getclaimsList, getListApi: this.$apis.claims.getclaimsList,
...@@ -219,11 +282,12 @@ export default { ...@@ -219,11 +282,12 @@ export default {
{ {
label: '服务状态', label: '服务状态',
prop: 'status', prop: 'status',
width: 120, width: 180,
formatter: cellValue => { addHtml: 'colorStatus'
if (!cellValue) return '-' // formatter: cellValue => {
return statusList.map(item => item.confId).includes(cellValue.status) ? statusList.find(item => item.confId === cellValue.status).confName : '-' // if (!cellValue) return '-'
} // return statusList.map(item => item.confId).includes(cellValue.status) ? statusList.find(item => item.confId === cellValue.status).confName : '-'
// }
}, },
{ {
label: '状态描述', label: '状态描述',
...@@ -262,12 +326,54 @@ export default { ...@@ -262,12 +326,54 @@ export default {
}, },
{ {
label: '操作', label: '操作',
width: 160,
prop: '', prop: '',
width: 100,
fixed: 'right', fixed: 'right',
addHtml: 'table-btns' addHtml: 'table-btns'
} }
] ]
},
statusMap: {
0: {
name: '待提交国任',
color: '#FDB757'
},
2: {
name: '校验不通过',
color: ' #EB4E4E'
},
1: {
name: '待支付',
color: '#FDB757'
},
3: {
name: '支付成功',
color: '#2CCA74'
},
4: {
name: '支付失败',
color: '#EB4E4E'
},
19: {
name: '待核实',
color: '#FDB757'
},
21: {
name: '待运营经理审核',
color: '#FDB757'
},
22: {
name: '运营经理审核不通过',
color: '#EB4E4E'
},
23: {
name: '待核赔',
color: '#5850FF'
},
25: {
name: '核赔不通过',
color: '#EB4E4E'
}
} }
} }
}, },
...@@ -290,7 +396,7 @@ export default { ...@@ -290,7 +396,7 @@ export default {
this.showGh = href.indexOf('cgacar') != -1 this.showGh = href.indexOf('cgacar') != -1
if (!this.showGh) this.searchFormData[0].placeholder = '请输入客户名 | 合同号 | 报案号' if (!this.showGh) this.searchFormData[0].placeholder = '请输入客户名 | 合同号 | 报案号'
}, },
// 1.新增 2.查看 3.重新提交 4.去处理 // 1.新增 2.查看 3.重新提交 4.去处理 5.运营经理审核 6 核赔审核
handleEdit(editNo, row) { handleEdit(editNo, row) {
let urlParam = { let urlParam = {
editNo, editNo,
...@@ -304,7 +410,8 @@ export default { ...@@ -304,7 +410,8 @@ export default {
urlParam.contractNo = editNo == 1 ? '' : row.writeOffCode urlParam.contractNo = editNo == 1 ? '' : row.writeOffCode
} }
const temp = encodeURIComponent(JSON.stringify(urlParam)) const temp = encodeURIComponent(JSON.stringify(urlParam))
this.$router.push({ path: '/claims/order/' + temp }) const title = this.jumpTitle(editNo)
this.$router.push({ path: '/claims/order/' + temp, query: { $title: title } })
}, },
handleOkFn() { handleOkFn() {
this.getParams() this.getParams()
...@@ -346,6 +453,35 @@ export default { ...@@ -346,6 +453,35 @@ export default {
document.body.appendChild(a) document.body.appendChild(a)
a.click() a.click()
}) })
},
// 页面跳转标题判断
//1.新增 2.查看 3.重新提交 4.去处理 5.运营经理审核 6 核赔审核
jumpTitle(addOrEdit) {
let title = '详情'
switch (addOrEdit) {
case 1:
title = '新增核赔'
break
case 2:
title = '查看'
break
case 3:
title = '重新提交'
break
case 4:
title = '去处理'
break
case 5:
title = '运营经理审核'
break
case 6:
title = '核赔审核'
break
default:
title = '详情'
break
}
return title
} }
} }
} }
...@@ -353,7 +489,8 @@ export default { ...@@ -353,7 +489,8 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
.header_info_widget { .header_info_widget {
box-sizing: border-box; box-sizing: border-box;
margin: 16px 0; // margin: 16px 0;
margin-bottom: 16px;
width: 100%; width: 100%;
height: 40px; height: 40px;
display: flex; display: flex;
...@@ -380,17 +517,28 @@ export default { ...@@ -380,17 +517,28 @@ export default {
} }
.search_container { .search_container {
background: #ffffff; background: #ffffff;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
padding: 20px 20px 0; padding: 20px 20px 0;
} }
.table_widget { .table_widget {
padding: 0px 20px 20px; padding: 0px 20px 20px;
background: #ffffff; background: #ffffff;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1); // box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
}
.table_point {
width: 6px;
height: 6px;
border-radius: 50%;
margin-right: 8px;
}
.table_top_line {
margin-bottom: 10px;
}
.el-button + .el-button {
margin-left: 8px;
} }
/deep/ .el-form { /deep/ .el-form {
.el-form-item { .el-form-item {
margin-right: 12px !important; // margin-right: 12px !important;
&:first-child { &:first-child {
.el-input { .el-input {
width: 312px !important; width: 312px !important;
......
<!-- 权益订单 --> <!-- 权益订单 -->
<template> <template>
<div> <div v-if="pageShow">
<div v-if="detailOrderStatus == 25 || detailOrderStatus == 22" class="fail_status_widget">
<i class="el-icon-warning"></i>
<span>核赔不通过:{{ noPassMap[reasonForFailureCode] }},{{ reasonForFailure }}</span>
</div>
<report @toSearchOrderDetail="toSearchOrderDetail" ref="reportRef" :isGH="routeInfo.isGH" :pageType="pageType" :editForm.sync="editForm"></report> <report @toSearchOrderDetail="toSearchOrderDetail" ref="reportRef" :isGH="routeInfo.isGH" :pageType="pageType" :editForm.sync="editForm"></report>
<repair ref="repairRef" @changeObjectType="changeObjectType" :isGH="routeInfo.isGH" :pageType="pageType" :serviceItemsList.sync="serviceItemsList" :totalPrice.sync="totalPrice" :accountForm.sync="accountForm"></repair> <repair ref="repairRef" @changeObjectType="changeObjectType" :isGH="routeInfo.isGH" :pageType="pageType" :serviceItemsList.sync="serviceItemsList" :totalPrice.sync="totalPrice" :accountForm.sync="accountForm"></repair>
<material ref="materialRef" :pageType="pageType" :materialForm.sync="materialForm"></material> <material ref="materialRef" :pageType="pageType" :materialForm.sync="materialForm"></material>
<div class="page-btm-btn" v-if="pageType != 2"> <wraning :isWatchOrder="isWatchOrder" @getWarningData="getWarningData" v-if="accountMatchResultList.length && detailOrderStatus != 2" :list="accountMatchResultList"></wraning>
<el-button type="primary" @click="confirmSubmit(1)">提交</el-button> <div v-if="pageType != 2" class="page-btm-btn">
<el-button type="primary" plain @click="confirmSubmit(2)">草稿</el-button> <template v-if="detailOrderStatus < 19 || detailOrderStatus == 22 || detailOrderStatus == 25">
<el-button type="primary" @click="confirmSubmit(1)">提交</el-button>
<el-button type="primary" plain @click="confirmSubmit(2)">草稿</el-button>
</template>
<!-- <template v-if="detailOrderStatus == 19">
<el-button @click="toCheckOrder(20)" :size="size" type="primary">提交</el-button>
</template> -->
<template v-if="detailOrderStatus == 21">
<el-button @click="toCheckOrderByYY(22)" :size="size" plain>审核不通过</el-button>
<el-button @click="toCheckOrderByYY(23)" :size="size" type="primary">审核通过</el-button>
</template>
<template v-if="detailOrderStatus == 23">
<el-button @click="toCheckOrderByYY(25)" :size="size" plain>审核不通过</el-button>
<el-button @click="toCheckOrderByYY(24)" :size="size" type="primary">审核通过</el-button>
</template>
</div>
<div v-if="pageType == 2 && detailOrderStatus == 19" class="page-btm-btn">
<el-button @click="toCheckOrder(20)" :size="size" type="primary">提交</el-button>
</div> </div>
<el-dialog title="风险预警" width="720px" @close="cancelWarning" :visible.sync="dialogVisible">
<div v-if="accountMatchResultList.length" class="warning_body">
<!-- <div slot="title" class="maxtitle">风险预警</div> -->
<div class="header">
<i class="el-icon-warning"></i>
<span class="title">风险预警</span>
<span class="cont">请核实情况,并在系统上提交说明或上传资料。</span>
</div>
<div class="main">
<div class="element">
<div class="e_title">风险预警:{{ matchResultDesc[accountMatchResultList[accountMatchResultList.length - 1].matchResult] }}</div>
<div class="e_desc">具体描述:{{ accountMatchResultList[accountMatchResultList.length - 1].matchResultDesc }}</div>
</div>
</div>
</div>
<span slot="footer" class="dialog-footer">
<el-button :size="size" @click="cancelWarning">取 消</el-button>
<el-button :size="size" type="primary" @click="handleWarning">确 定</el-button>
</span>
</el-dialog>
<GLDialog class="gl-form-page gl-form-min" title="审核不通过" mode="mid" :visible.sync="showNoPassDialog" @onOk="comfirmNoPass" @onCancel="cancleNoPass">
<glsx-combi-form ref="noPassRef" :isInline="false" labelWidth="154px" defaultWidth="284px" :formObj="noPassObj" :formData="noPassForm"></glsx-combi-form>
</GLDialog>
</div> </div>
</template> </template>
<script> <script>
...@@ -15,12 +59,16 @@ import report from './components/report.vue' ...@@ -15,12 +59,16 @@ 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' import util from '@/util/util'
import wraning from './components/wraning/index.vue'
import glsxCombiForm from '@/components/glsx-combi-form'
export default { export default {
name: 'order', name: 'order',
components: { components: {
report, report,
repair, repair,
material material,
wraning,
glsxCombiForm
}, },
data() { data() {
return { return {
...@@ -61,7 +109,59 @@ export default { ...@@ -61,7 +109,59 @@ export default {
billInfo: [], billInfo: [],
otherInfo: [] otherInfo: []
}, },
serviceItemsList: [] serviceItemsList: [],
dialogVisible: false,
accountMatchResultList: [],
detailOrderStatus: 0,
matchResultDesc: {
1: '支付账号异常',
2: '金额过大'
},
// 弹窗
showNoPassDialog: false,
showPassedDialog: false,
noPassObj: {
reason: '',
desc: ''
},
noPassForm: [
{
label: '原因:',
name: 'reason',
type: 'select',
isClear: true,
placeholder: '请选择原因',
optionList: [
{
confId: 1,
confName: '拒赔'
},
{
confId: 2,
confName: '资料不清晰'
}
],
optionId: 'confId',
optionLabel: 'confName'
},
{
label: '具体描述:',
name: 'desc',
type: 'input',
inputType: 'textarea',
rows: 3,
isClear: true,
maxlength: 200,
placeholder: '请输入具体描述'
}
],
pageShow: false,
noPassMap: {
1: '拒赔',
2: '资料不清晰'
},
reasonForFailureCode: 1,
isWatchOrder: false
} }
}, },
created() { created() {
...@@ -71,25 +171,175 @@ export default { ...@@ -71,25 +171,175 @@ export default {
this.pageType = urlQuery.editNo this.pageType = urlQuery.editNo
this.routeInfo = urlQuery this.routeInfo = urlQuery
this.handleFormInfo(urlQuery.contractNo, urlQuery.isGH) this.handleFormInfo(urlQuery.contractNo, urlQuery.isGH)
// if(!this.isGH){ if (this.pageType == 2) {
// } this.isWatchOrder = true
}
if (this.routeInfo.orderId) { if (this.routeInfo.orderId) {
this.getDetailById() this.getDetailById()
} else {
this.pageShow = true
} }
}, },
computed: { computed: {
totalPrice() { totalPrice() {
let total = this.serviceItemsList.reduce(function(prev, cur) { let total = this.serviceItemsList.reduce(function (prev, cur) {
return prev + +(cur.approveAmount * 100).toFixed(0) return prev + +(cur.approveAmount * 100).toFixed(0)
}, 0) }, 0)
return total / 100 return total / 100
} }
}, },
mounted() { mounted() {},
console.log('更新')
},
methods: { methods: {
// 校验上传资料是否填完
verifyWarningImage() {
if (!this.queryList) {
this.queryList = this._temp_queryList
}
if (!this.queryList.length) {
this.$message.error(`请填写风险预警信息补充`)
return false
}
let flag = false,
imgFlag = false,
curImgIndex,
curIndex = 0
this.queryList.forEach((el, index) => {
if (el.matchType != 1) {
if (!el.verifyResultDesc) {
flag = true
curIndex = index
}
if (!el.accountVerifyImagesList || !el.accountVerifyImagesList.length) {
imgFlag = true
curImgIndex = index
}
if (el.accountVerifyImagesList&&el.accountVerifyImagesList.length) {
el.accountVerifyImagesList.forEach((k, i) => {
if (!k.verifyImage) {
imgFlag = true
curImgIndex = index
}
})
}
}
})
if (flag) {
this.$message.error(`请填写风险预警${curIndex + 1}的核实情况说明`)
return false
}
if (imgFlag) {
this.$message.error(`请上传风险预警${curImgIndex + 1}的核实资料补充`)
return false
}
return true
},
// 处理审核时需要的核赔参数
handlerClaimsQueryForCheck() {
const params = { ...this.editForm, ...this.accountForm }
if (params.accountType !== 1) {
params.accountType = 0
}
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)
})
}
return params
},
cancleNoPass() {
this.showNoPassDialog = false
},
// 点击不通过
comfirmNoPass() {
let _para = {
reasonForFailureCode: this.noPassObj.reason,
reasonForFailure: this.noPassObj.desc
}
this.toCheckOrder(this.noPass_operation, _para)
},
// 审核
toCheckOrderByYY(operation) {
if (operation == 22 || operation == 25) {
this.showNoPassDialog = true
this.noPass_operation = operation
} else {
this.toCheckOrder(operation)
}
},
toCheckOrder(operation, addQuery = {}) {
let claimsQuery = {},_accountMatchResultList = []
claimsQuery = this.handlerClaimsQueryForCheck()
if (operation == 20) {
const flag = this.verifyWarningImage()
if (!flag) return
}
if(this.queryList&&this.queryList.length>0){
const _temArr = JSON.stringify(this.queryList)
_accountMatchResultList = JSON.parse(_temArr)
_accountMatchResultList.forEach(el=>{
delete el.matchType
})
}
let _para = {
operation,
id: this.orderDetailInfo.id,
accountMatchResultList: _accountMatchResultList || [],
equitySource: 2,
...addQuery,
...claimsQuery
}
const loading = this.$loading({
lock: true,
text: 'Loading',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.3)'
})
this.$apis.claims.commitClaimsOrder(_para).then(res => {
loading.close()
if (res) {
this.$message({
message: '操作成功',
type: 'success'
})
this.handleCancel()
}
})
},
getWarningData(e) {
if (e) {
let arr = []
e.forEach(el => {
let obj = {
id: el.id,
verifyResultDesc: el.verifyResultDesc,
accountVerifyImagesList: el.accountVerifyImagesList,
matchType:el.matchType
}
arr.push(obj)
})
this.queryList = arr
}
},
changeObjectType(newVal) { changeObjectType(newVal) {
if (newVal === 1) { if (newVal === 1) {
this.saveObj.objectType = newVal this.saveObj.objectType = newVal
...@@ -140,6 +390,33 @@ export default { ...@@ -140,6 +390,33 @@ export default {
this.materialForm.otherInfo.push(obj) this.materialForm.otherInfo.push(obj)
} }
}) })
if (res.status == 19) {
this.dangerWran()
this.pageType = 2
}
this.detailOrderStatus = res.status
let _tempArr = []
res.accountMatchResultList.forEach(el => {
let arr = []
el.accountVerifyImagesList.forEach(ele => {
let obj = { verifyImage: ele.verifyImage }
arr.push(obj)
})
el.accountVerifyImagesList = arr
let _temp = {
id: el.id,
accountVerifyImagesList: arr,
verifyResultDesc: el.verifyResultDesc,
matchType: el.matchType
}
_tempArr.push(_temp)
})
this._temp_queryList = _tempArr
this.accountMatchResultList = res.accountMatchResultList
this.orderDetailInfo = res
this.reasonForFailure = res.reasonForFailure
this.reasonForFailureCode = res.reasonForFailureCode
this.pageShow = true
}) })
}, },
// 新增的时候,输入合同号,带出信息 // 新增的时候,输入合同号,带出信息
...@@ -279,24 +556,68 @@ export default { ...@@ -279,24 +556,68 @@ export default {
spinner: 'el-icon-loading', spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.3)' background: 'rgba(0, 0, 0, 0.3)'
}) })
params.equitySource = 2
this.$apis.claims.commitClaimsOrder(params).then(res => { this.$apis.claims.commitClaimsOrder(params).then(res => {
loading.close() loading.close()
if (res) { if (res) {
if (res.accountMatchResultList && res.accountMatchResultList.length) {
res.accountMatchResultList.forEach(el=>{
el.accountVerifyImagesList = el.accountVerifyImagesList || []
})
this.accountMatchResultList = res.accountMatchResultList || []
this.dialogVisible = true
this.needBack = true
}
this.$message({ this.$message({
message: type == 1 ? '提交成功' : '保存草稿成功', message: type == 1 ? '提交成功' : '保存草稿成功',
type: 'success' type: 'success'
}) })
this.handleCancel() if (type != 1) {
this.handleCancel()
}
} }
}) })
}, },
handleCancel() { handleCancel() {
this.$router.push({ path: '/claims/index' }) this.$router.push({ path: '/claims/index' })
},
// 风险预警
dangerWran() {
this.dialogVisible = true
},
cancelWarning() {
if (this.needBack) {
this.handleCancel()
}
this.dialogVisible = false
},
handleWarning() {
this.cancelWarning()
} }
} }
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.fail_status_widget {
width: 100%;
height: 40px;
background: #ffeed9;
border-radius: 4px;
margin-bottom: 12px;
display: flex;
align-items: center;
box-sizing: border-box;
padding-left: 16px;
i {
color: #fdb757;
}
span {
font-weight: 400;
font-size: 14px;
color: #000000a6;
margin-left: 8px;
}
}
.footer { .footer {
width: 100%; width: 100%;
position: fixed; position: fixed;
...@@ -307,4 +628,63 @@ export default { ...@@ -307,4 +628,63 @@ export default {
line-height: 64px; line-height: 64px;
background: #ffffff; background: #ffffff;
} }
.warning_body {
.maxtitle {
font-weight: 600;
font-size: 20px;
color: #333333;
}
.header {
display: flex;
flex-direction: column;
align-items: center;
i {
color: #fdb757;
font-size: 48px;
}
.title {
font-weight: 600;
font-size: 16px;
color: #333333;
line-height: 24px;
margin: 8px 0 4px 0;
}
.cont {
font-weight: 400;
font-size: 14px;
color: #666666;
margin-bottom: 20px;
}
}
.main {
.element {
background: #f9f9f9;
box-sizing: border-box;
padding: 12px 16px;
margin-bottom: 10px;
.e_title {
font-weight: 400;
font-size: 14px;
color: #333333;
margin-bottom: 4px;
line-height: 20px;
}
.e_desc {
font-weight: 400;
font-size: 14px;
color: #999999;
line-height: 20px;
}
}
}
}
/deep/ .el-dialog__footer {
text-align: center;
}
/deep/ .el-dialog__header {
padding: 16px 20px;
.el-dialog__title {
font-weight: 600;
}
}
</style> </style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!