|
@@ -230,11 +230,14 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
// 销售单详情
|
|
// 销售单详情
|
|
- getOrderDetail (flag) {
|
|
|
|
|
|
+ getOrderDetail (flag, callback) {
|
|
salesDetailBySn({ salesBillSn: this.$route.params.sn }).then(res => {
|
|
salesDetailBySn({ salesBillSn: this.$route.params.sn }).then(res => {
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
this.detailData = res.data
|
|
this.detailData = res.data
|
|
this.detailData.totalDiscountAmount = Number(this.detailData.totalOrigAmount || 0) - Number(this.detailData.totalAmount || 0)
|
|
this.detailData.totalDiscountAmount = Number(this.detailData.totalOrigAmount || 0) - Number(this.detailData.totalAmount || 0)
|
|
|
|
+ if (callback) {
|
|
|
|
+ callback()
|
|
|
|
+ }
|
|
}
|
|
}
|
|
if (flag) {
|
|
if (flag) {
|
|
this.getActiveList()
|
|
this.getActiveList()
|
|
@@ -327,7 +330,7 @@ export default {
|
|
openProductModal (type, refId, countData) {
|
|
openProductModal (type, refId, countData) {
|
|
console.log(type, refId, countData)
|
|
console.log(type, refId, countData)
|
|
const promo = this.activeList.find(item => item.promoRuleSn == refId)
|
|
const promo = this.activeList.find(item => item.promoRuleSn == refId)
|
|
- if(promo){
|
|
|
|
|
|
+ if (promo) {
|
|
promo.countData = countData
|
|
promo.countData = countData
|
|
}
|
|
}
|
|
this.$refs.chooseProduct.pageInit(this.detailData, promo, type)
|
|
this.$refs.chooseProduct.pageInit(this.detailData, promo, type)
|
|
@@ -414,8 +417,13 @@ export default {
|
|
this.submitResult(ajax_data)
|
|
this.submitResult(ajax_data)
|
|
} else {
|
|
} else {
|
|
updateBatch(this.updataData.detailList).then(res => {
|
|
updateBatch(this.updataData.detailList).then(res => {
|
|
|
|
+ this.priceUpdateModal = false
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
- this.submitResult(ajax_data)
|
|
|
|
|
|
+ // 刷新详情统计
|
|
|
|
+ this.spinning = true
|
|
|
|
+ this.getOrderDetail(false, () => {
|
|
|
|
+ this.submitResult(ajax_data)
|
|
|
|
+ })
|
|
}
|
|
}
|
|
})
|
|
})
|
|
}
|
|
}
|
|
@@ -465,6 +473,7 @@ export default {
|
|
<div style="padding:10px 0;text-align:center"><strong>请按照以上提示修改后再提交</strong></div>
|
|
<div style="padding:10px 0;text-align:center"><strong>请按照以上提示修改后再提交</strong></div>
|
|
</div>
|
|
</div>
|
|
})
|
|
})
|
|
|
|
+ this.spinning = false
|
|
} else {
|
|
} else {
|
|
// 弹出确认提示信息,可跳过继续提交
|
|
// 弹出确认提示信息,可跳过继续提交
|
|
if (b.length) {
|
|
if (b.length) {
|
|
@@ -485,6 +494,7 @@ export default {
|
|
_this.submitOrder(data)
|
|
_this.submitOrder(data)
|
|
}
|
|
}
|
|
})
|
|
})
|
|
|
|
+ this.spinning = false
|
|
} else {
|
|
} else {
|
|
_this.submitOrder(data)
|
|
_this.submitOrder(data)
|
|
}
|
|
}
|