Commit e5799ef2 by 胡悦

fix(订单创建): 修复补录订单时收款类型禁用问题及组件切换逻辑

修复从补录订单进入时4S店收款类型被禁用的问题
调整组件切换时数据传输逻辑,确保补录订单场景正确处理
1 parent 0d74960d
...@@ -156,6 +156,23 @@ export default { ...@@ -156,6 +156,23 @@ export default {
} }
console.log(this.orderObj, 'orderObj') console.log(this.orderObj, 'orderObj')
handleTransactionData(newVal) handleTransactionData(newVal)
} else {
this.orderCreateType = 'createWithPay'
this.orderObj = {
customer: {},
customerSex: '1',
experienceFlag: 'Y',
payeeType: 1,
salesType: '0',
frontGear: null, // 1 ,回显upgradeGoodsPosition == 1
frontWindow: null, // 2
rearWindow: null, // 3
rearGear: null, // 4
sunRoof: null, // 5, 6,7
package: null,
skuGoods: null // upgradeGoodsPosition 为空,则是其他精品单商品
}
this.initData()
} }
}, },
immediate: true immediate: true
...@@ -260,6 +277,12 @@ export default { ...@@ -260,6 +277,12 @@ export default {
] ]
this.changePayee() this.changePayee()
} else { } else {
// 防止从补录进来4s店收款为禁用
const cell = this.formList[2].find(item => item.value == 'payeeType')
if (cell) {
cell.current = 1
cell.radioList[1].disabled = false
}
this.getConfig() this.getConfig()
} }
// this.getEmployeeList() // this.getEmployeeList()
......
...@@ -110,7 +110,7 @@ export default { ...@@ -110,7 +110,7 @@ export default {
if (!noInterceptPage.includes(item.name) && ((await this.checkDailyReport()) || (await this.inspectionOfProhibitionBill()))) return if (!noInterceptPage.includes(item.name) && ((await this.checkDailyReport()) || (await this.inspectionOfProhibitionBill()))) return
// 保存当前选择的组件信息,但不立即切换 // 保存当前选择的组件信息,但不立即切换
const selectedItem = item const selectedItem = item
if (this.toolComponentName == selectedItem.name) return if (this.toolComponentName === selectedItem.name && (!this.transmissionOfData || this.transmissionOfData.type !== 'supplementOrder')) return
// 如果当前组件是OrderManagement,直接切换组件,不显示弹窗 // 如果当前组件是OrderManagement,直接切换组件,不显示弹窗
// 只有从CreateOrder、DefeatOrder切换其他组件时需要二次确认 // 只有从CreateOrder、DefeatOrder切换其他组件时需要二次确认
if (this.toolComponentName !== 'CreateOrder' && this.toolComponentName !== 'DefeatOrder') { if (this.toolComponentName !== 'CreateOrder' && this.toolComponentName !== 'DefeatOrder') {
...@@ -127,9 +127,13 @@ export default { ...@@ -127,9 +127,13 @@ export default {
callback: () => { callback: () => {
// 点击确认后才切换组件 // 点击确认后才切换组件
this.toolComponentName = selectedItem.name this.toolComponentName = selectedItem.name
if (selectedItem.name !== 'CreateOrder') { // if (selectedItem.name !== 'CreateOrder') {
this.transmissionOfData = null // this.transmissionOfData = null
} // }else {
// console.log(111)
// this.transmissionOfData = null
// }
this.transmissionOfData = null
this.$refs.notice.close() this.$refs.notice.close()
} }
}, },
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!