Commit 6f65d20f authored by jingnan's avatar jingnan 👀

接收仓库修改不生效bug修改

parent 087af659
......@@ -236,7 +236,8 @@ export default {
extMaterialId: '',
parentId: null,
operateType: null,
parentRowId: ''
parentRowId: '',
currStorageList: []
}
},
computed: {
......@@ -308,7 +309,8 @@ export default {
},
methods: {
handleOpen(type, row) {
// this.basicData = basicData
this.defaultStorage()
// this.basicData = basicData
this.form = { 'reqAmount': 1 }
// this.dialogVisibleDetails = true
this.operateType = type
......@@ -335,7 +337,7 @@ export default {
},
// 回显数据
dispalyData(row) {
this.form = JSON.parse(JSON.stringify(row))
this.form = this.$utils.deepClone(row)
this.$set(this.form, 'operator', 'MODIFY')
row.billType === 'AirEquipment' && this.$set(this.form, 'reqAmount', 1)
this.$set(this.form, 'resCode', row.extMaterial && row.extMaterial.resCode || row.resCode || '')
......@@ -344,6 +346,14 @@ export default {
this.$set(this.form, 'modelNo', row.extMaterial && row.extMaterial.modelNo || row.modelNo || '')
this.$set(this.form, 'extMaterialId', row.extMaterialId || '')
this.$set(this.form, 'supplier', row.extDxSipplier && row.extDxSipplier.supplierFullName || row.supplier || '')
this.$set(this.form, 'storageZoneName', '')
this.$set(this.form, 'storageZone', '')
setTimeout(() => {
if (this.currStorageList && this.currStorageList.find(el => Number(el.value) === Number(row.storageZoneId))) {
this.$set(this.form, 'storageZoneName', row.storageZone && row.storageZone.extname || '')
this.$set(this.form, 'storageZone', row.storageZoneId)
}
}, 100)
this.$set(this.form, 'withProductMaterial', Array.isArray(row.withProductMaterial) ? row.withProductMaterial : row.withProductMaterial && row.withProductMaterial.split(';') || [])
this.resetMaterial(row.extMaterial ? row.extMaterial.resCode : row.resCode || '')
this.changeMaterial(row.extMaterial ? row.extMaterial.resCode : row.resCode || '')
......@@ -1845,6 +1855,7 @@ export default {
value: item.source && item.source.id
}
})
this.currStorageList = STORAGE.component.options
})
.catch((err) => {
console.log(err)
......
......@@ -243,7 +243,8 @@ export default {
extMaterialId: '',
parentId: null,
operateType: null,
parentRowId: ''
parentRowId: '',
currStorageList: []
}
},
computed: {
......@@ -312,6 +313,7 @@ export default {
methods: {
handleOpen(type, basicData, row) {
this.basicData = basicData
this.defaultStorage()
this.form = { 'reqAmount': 1 }
this.dialogVisibleDetails = true
this.operateType = type
......@@ -338,7 +340,7 @@ export default {
},
// 回显数据
dispalyData(row) {
this.form = JSON.parse(JSON.stringify(row))
this.form = this.$utils.deepClone(row)
this.$set(this.form, 'operator', row.id && this.basicData.operator !== 'ADD' ? 'MODIFY' : 'ADD')
row.billType === 'AirEquipment' && this.$set(this.form, 'reqAmount', 1)
this.$set(this.form, 'resCode', row.extMaterial && row.extMaterial.resCode || row.resCode || '')
......@@ -347,6 +349,14 @@ export default {
this.$set(this.form, 'modelNo', row.extMaterial && row.extMaterial.modelNo || row.modelNo || '')
this.$set(this.form, 'extMaterialId', row.extMaterialId || '')
this.$set(this.form, 'supplier', row.extDxSipplier && row.extDxSipplier.supplierFullName || row.supplier || '')
this.$set(this.form, 'storageZoneName', '')
this.$set(this.form, 'storageZone', '')
setTimeout(() => {
if (this.currStorageList && this.currStorageList.find(el => Number(el.value) === Number(row.storageZoneId))) {
this.$set(this.form, 'storageZoneName', row.storageZone && row.storageZone.extname || '')
this.$set(this.form, 'storageZone', row.storageZoneId)
}
}, 100)
this.$set(this.form, 'withProductMaterial', Array.isArray(row.withProductMaterial) ? row.withProductMaterial : row.withProductMaterial && row.withProductMaterial.split(';') || [])
this.resetMaterial(row.extMaterial ? row.extMaterial.resCode : row.resCode || '')
this.changeMaterial(row.extMaterial ? row.extMaterial.resCode : row.resCode || '')
......@@ -1848,6 +1858,7 @@ export default {
value: item.source && item.source.id
}
})
this.currStorageList = STORAGE.component.options
})
.catch((err) => {
console.log(err)
......
......@@ -337,7 +337,7 @@ export default {
},
// 回显数据
dispalyData(row) {
this.form = JSON.parse(JSON.stringify(row))
this.form = this.$utils.deepClone(row)
this.$set(this.form, 'operator', row.id && this.basicData.operator !== 'ADD' ? 'MODIFY' : 'ADD')
row.billType === 'AirEquipment' && this.$set(this.form, 'reqAmount', 1)
this.$set(this.form, 'resCode', row.extMaterial && row.extMaterial.resCode || row.resCode || '')
......@@ -346,6 +346,8 @@ export default {
this.$set(this.form, 'modelNo', row.extMaterial && row.extMaterial.modelNo || row.modelNo || '')
this.$set(this.form, 'extMaterialId', row.extMaterialId || '')
this.$set(this.form, 'supplier', row.extDxSipplier && row.extDxSipplier.supplierFullName || row.supplier || '')
this.$set(this.form, 'storageZoneName', row.storageZone && row.storageZone.extname || '')
this.$set(this.form, 'storageZone', row.storageZoneId)
this.$set(this.form, 'withProductMaterial', Array.isArray(row.withProductMaterial) ? row.withProductMaterial : row.withProductMaterial && row.withProductMaterial.split(';') || [])
this.resetMaterial(row.extMaterial ? row.extMaterial.resCode : row.resCode || '')
this.changeMaterial(row.extMaterial ? row.extMaterial.resCode : row.resCode || '')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment