优化单据多选商品的功能
This commit is contained in:
@@ -190,7 +190,9 @@ export const BillModalMixin = {
|
||||
let mList = res.data
|
||||
if (value.indexOf(',') > -1) {
|
||||
//多个条码
|
||||
let mArr = this.materialTable.dataSource
|
||||
this.$refs.materialDataTable.getValues((error, values) => {
|
||||
values.pop() //移除最后一行数据
|
||||
let mArr = values
|
||||
for (let i = 0; i < mList.length; i++) {
|
||||
let mInfo = mList[i]
|
||||
let mObj = this.parseInfoToObj(mInfo)
|
||||
@@ -200,11 +202,12 @@ export const BillModalMixin = {
|
||||
}
|
||||
let taxLastMoneyTotal = 0
|
||||
for (let j = 0; j < mArr.length; j++) {
|
||||
taxLastMoneyTotal += mArr[j].taxLastMoney
|
||||
taxLastMoneyTotal += mArr[j].taxLastMoney-0
|
||||
}
|
||||
this.materialTable.dataSource = mArr
|
||||
target.statisticsColumns.taxLastMoney = taxLastMoneyTotal
|
||||
that.autoChangePrice(target)
|
||||
})
|
||||
} else {
|
||||
//单个条码
|
||||
let mArr = []
|
||||
|
||||
Reference in New Issue
Block a user