Commit 9de52c86 by cwq0219

bug修复

1 parent fcf96643
...@@ -88,6 +88,7 @@ export default { ...@@ -88,6 +88,7 @@ export default {
data() { data() {
return { return {
size: 'small', size: 'small',
submit: false,
// title: '新增权益', // title: '新增权益',
// titleObj: { // titleObj: {
// 1: '新增权益', // 1: '新增权益',
...@@ -153,13 +154,13 @@ export default { ...@@ -153,13 +154,13 @@ export default {
label: '车架号', label: '车架号',
name: 'vin', name: 'vin',
type: 'input', type: 'input',
maxlength: 19 maxlength: 17
}, },
{ {
label: '发动机号', label: '发动机号',
name: 'engineNo', name: 'engineNo',
type: 'input', type: 'input',
maxlength: 32 maxlength: 16
}, },
{ {
label: '发票价格', label: '发票价格',
...@@ -175,7 +176,7 @@ export default { ...@@ -175,7 +176,7 @@ export default {
label: '车身颜色', label: '车身颜色',
name: 'vehicleColor', name: 'vehicleColor',
type: 'input', type: 'input',
maxlength: 32 maxlength: 5
}, },
{ {
label: '座位数', label: '座位数',
...@@ -747,6 +748,10 @@ export default { ...@@ -747,6 +748,10 @@ export default {
return params return params
}, },
handleDraft() { handleDraft() {
if (this.submit) {
return true
}
this.submit = true
var params = this.getParams() var params = this.getParams()
params.operationType = 0 params.operationType = 0
if (this.routeInfo.addOrEdit == 2) { if (this.routeInfo.addOrEdit == 2) {
...@@ -756,6 +761,7 @@ export default { ...@@ -756,6 +761,7 @@ export default {
this.$apis.beforeSale.createCodeApi({}).then(res => { this.$apis.beforeSale.createCodeApi({}).then(res => {
console.log(res) console.log(res)
params.contractNo = res params.contractNo = res
this.submit = false
this.updateEquity(params) this.updateEquity(params)
}) })
} }
...@@ -782,6 +788,10 @@ export default { ...@@ -782,6 +788,10 @@ export default {
}) })
}, },
handleConfirm() { handleConfirm() {
if (this.submit) {
return true
}
this.submit = true
var list = ['Car', 'User', 'Pro', 'Other'] var list = ['Car', 'User', 'Pro', 'Other']
var flag = true var flag = true
var errorObjList = [] var errorObjList = []
...@@ -810,11 +820,15 @@ export default { ...@@ -810,11 +820,15 @@ export default {
this.$apis.beforeSale.createCodeApi({}).then(res => { this.$apis.beforeSale.createCodeApi({}).then(res => {
console.log(res) console.log(res)
params.contractNo = res params.contractNo = res
this.submit = false
this.updateEquity(params) this.updateEquity(params)
}) })
} }
}, },
handleCancel() { handleCancel() {
if (this.submit) {
return true
}
this.$router.push({ this.$router.push({
path: '/beforeSale/index' path: '/beforeSale/index'
}) })
......
...@@ -175,8 +175,9 @@ export default { ...@@ -175,8 +175,9 @@ export default {
{ {
label: '合同号', label: '合同号',
prop: 'contractNo', prop: 'contractNo',
width: '200px',
formatter: cellValue => { formatter: cellValue => {
return cellValue.contractNo || '-' return [2, 4, 5].includes(cellValue.orderStatus) ? (cellValue.contractNo || '-') : '-'
} }
}, },
{ {
...@@ -189,10 +190,10 @@ export default { ...@@ -189,10 +190,10 @@ export default {
}, },
{ {
label: '新车开票日期', label: '新车开票日期',
prop: 'expirationDate', prop: 'billingDate',
width: '160px', width: '160px',
formatter: cellValue => { formatter: cellValue => {
return cellValue.expirationDate ? dayjs(cellValue.expirationDate).format('YYYY-MM-DD HH:mm:ss') : '-' return cellValue.billingDate ? dayjs(cellValue.billingDate).format('YYYY-MM-DD HH:mm:ss') : '-'
} }
}, },
{ {
...@@ -207,6 +208,7 @@ export default { ...@@ -207,6 +208,7 @@ export default {
{ {
label: '车品牌', label: '车品牌',
prop: 'vehicleBrandName', prop: 'vehicleBrandName',
width: '160px',
formatter: cellValue => { formatter: cellValue => {
return cellValue.vehicleBrandName || '-' return cellValue.vehicleBrandName || '-'
} }
...@@ -266,6 +268,7 @@ export default { ...@@ -266,6 +268,7 @@ export default {
{ {
label: '状态', label: '状态',
prop: 'orderStatus', prop: 'orderStatus',
width: '100px',
formatter: cellValue => { formatter: cellValue => {
return this.baseData.orderStatusList.map(item => item.confId).includes(cellValue.orderStatus) ? this.baseData.orderStatusList.find(item => item.confId == cellValue.orderStatus).confName : '-' return this.baseData.orderStatusList.map(item => item.confId).includes(cellValue.orderStatus) ? this.baseData.orderStatusList.find(item => item.confId == cellValue.orderStatus).confName : '-'
} }
...@@ -287,6 +290,7 @@ export default { ...@@ -287,6 +290,7 @@ export default {
{ {
label: '操作人', label: '操作人',
prop: 'updatedBy', prop: 'updatedBy',
width: '140px',
formatter: cellValue => { formatter: cellValue => {
return cellValue.updatedBy || '-' return cellValue.updatedBy || '-'
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!