|
|
|
@ -492,7 +492,7 @@ export default {
|
|
|
|
|
barCode: undefined,
|
|
|
|
|
spec: undefined,
|
|
|
|
|
inventoryType: undefined,
|
|
|
|
|
brandId: "520546789800018053",
|
|
|
|
|
brandId: "",
|
|
|
|
|
productCategoryId: undefined,
|
|
|
|
|
area: ["354094489370697", "354094489370698", "354094489403463"],
|
|
|
|
|
dangerousFlag: "1",
|
|
|
|
@ -782,6 +782,13 @@ export default {
|
|
|
|
|
})
|
|
|
|
|
return arrB
|
|
|
|
|
},
|
|
|
|
|
productUnitBase() {
|
|
|
|
|
if (this.dataForm.productUnitList.length > 0) {
|
|
|
|
|
return this.dataForm.productUnitList[0]['productUnitwarehouseId']
|
|
|
|
|
} else {
|
|
|
|
|
return ''
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
watch: {
|
|
|
|
|
'dataForm.manyUnitFlag': function (nManyUnitFlag, oManyUnitFlag) {
|
|
|
|
@ -789,16 +796,24 @@ export default {
|
|
|
|
|
if (this.dataForm.productUnitList.length > 1) {
|
|
|
|
|
this.dataForm.productUnitList = [this.dataForm.productUnitList[0]]
|
|
|
|
|
}
|
|
|
|
|
// if (this.dataForm.productUnitList.length > 0) {
|
|
|
|
|
// console.log(this.dataForm.productUnitList)
|
|
|
|
|
// console.log(this.dataForm.productUnitList.length)
|
|
|
|
|
// this.dataForm.inventoryUnitId = this.productUnitList[0]['id']
|
|
|
|
|
// this.dataForm.orderMainUnitId = this.productUnitList[0]['id']
|
|
|
|
|
// this.dataForm.salesMainUnitId = this.productUnitList[0]['id']
|
|
|
|
|
// this.dataForm.operateUnitId = this.productUnitList[0]['id']
|
|
|
|
|
// this.dataForm.pricingUnitId = this.productUnitList[0]['id']
|
|
|
|
|
// }
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
'productUnitBase': function (nUnitId, oUnitId) {
|
|
|
|
|
if (nUnitId != '') {
|
|
|
|
|
this.dataForm.inventoryUnitId = this.dataForm.productUnitList[0]['productUnitCode']
|
|
|
|
|
this.dataForm.orderMainUnitId = [this.dataForm.productUnitList[0]['productUnitCode']]
|
|
|
|
|
this.dataForm.salesMainUnitId = [this.dataForm.productUnitList[0]['productUnitCode']]
|
|
|
|
|
this.dataForm.operateUnitId = this.dataForm.productUnitList[0]['productUnitCode']
|
|
|
|
|
this.dataForm.pricingUnitId = this.dataForm.productUnitList[0]['productUnitCode']
|
|
|
|
|
} else {
|
|
|
|
|
this.dataForm.inventoryUnitId = ''
|
|
|
|
|
this.dataForm.orderMainUnitId = []
|
|
|
|
|
this.dataForm.salesMainUnitId = []
|
|
|
|
|
this.dataForm.operateUnitId = ''
|
|
|
|
|
this.dataForm.pricingUnitId = ''
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|