|
@@ -1,9 +1,9 @@
|
|
<template>
|
|
<template>
|
|
<div>
|
|
<div>
|
|
- <div class="table-page-search-wrapper" v-show="showDescBox&&descDetail">
|
|
|
|
- <a-descriptions :column="4">
|
|
|
|
|
|
+ <div class="table-page-search-wrapper" v-show="showDescBox">
|
|
|
|
+ <a-descriptions :column="4" v-if="descDetail">
|
|
<a-descriptions-item label="促销类型">
|
|
<a-descriptions-item label="促销类型">
|
|
- {{ descDetail.promotionRuleTypeDictValue }}
|
|
|
|
|
|
+ {{ descDetail.promotionRuleTypeDictValue||'--' }}
|
|
</a-descriptions-item>
|
|
</a-descriptions-item>
|
|
<a-descriptions-item label="促销门槛" span="3">
|
|
<a-descriptions-item label="促销门槛" span="3">
|
|
<div v-if="descDetail.gateFlag === '1'">
|
|
<div v-if="descDetail.gateFlag === '1'">
|
|
@@ -270,6 +270,10 @@
|
|
type: Object,
|
|
type: Object,
|
|
default: function(){return null}
|
|
default: function(){return null}
|
|
},
|
|
},
|
|
|
|
+ promo: {
|
|
|
|
+ type: Object,
|
|
|
|
+ default: function(){return null}
|
|
|
|
+ },
|
|
id: {
|
|
id: {
|
|
type: String,
|
|
type: String,
|
|
default: ''
|
|
default: ''
|
|
@@ -290,7 +294,12 @@
|
|
loadData: parameter => {
|
|
loadData: parameter => {
|
|
this.disabled = true
|
|
this.disabled = true
|
|
this.queryParam.salesBillSn = this.salesBillSn || ''
|
|
this.queryParam.salesBillSn = this.salesBillSn || ''
|
|
- return salesDetailList(Object.assign(parameter, this.queryParam, {showStock: true})).then(res => {
|
|
|
|
|
|
+ return salesDetailList(Object.assign(parameter, this.queryParam, {
|
|
|
|
+ showStock: true,
|
|
|
|
+ promoRuleSn: this.promo.promoRuleSn,
|
|
|
|
+ promoSn: this.promo.promoSn,
|
|
|
|
+ salesPromoSn: this.promo.salesPromoSn
|
|
|
|
+ })).then(res => {
|
|
let data
|
|
let data
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
data = res.data
|
|
data = res.data
|
|
@@ -411,7 +420,7 @@
|
|
centered: true,
|
|
centered: true,
|
|
onOk () {
|
|
onOk () {
|
|
_this.spinning = true
|
|
_this.spinning = true
|
|
- deleteAll({ salesBillSn: _this.salesBillSn }).then(res => {
|
|
|
|
|
|
+ deleteAll({ salesBillSn: _this.salesBillSn, salesPromoSn: _this.promo.salesPromoSn }).then(res => {
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
_this.resetSearchForm(true)
|
|
_this.resetSearchForm(true)
|
|
_this.$message.success(res.message)
|
|
_this.$message.success(res.message)
|
|
@@ -440,6 +449,7 @@
|
|
_this.spinning = true
|
|
_this.spinning = true
|
|
salesDetailBatchDel({
|
|
salesDetailBatchDel({
|
|
salesBillSn: _this.salesBillSn,
|
|
salesBillSn: _this.salesBillSn,
|
|
|
|
+ salesPromoSn: _this.promo.salesPromoSn,
|
|
salesBillDetailSnList: obj
|
|
salesBillDetailSnList: obj
|
|
}).then(res => {
|
|
}).then(res => {
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
@@ -457,7 +467,8 @@
|
|
const ajax_data = {
|
|
const ajax_data = {
|
|
warehouseSn: row.warehouseSn,
|
|
warehouseSn: row.warehouseSn,
|
|
salesBillDetailSnList: snArr,
|
|
salesBillDetailSnList: snArr,
|
|
- salesBillSn: this.salesBillSn
|
|
|
|
|
|
+ salesBillSn: this.salesBillSn,
|
|
|
|
+ salesPromoSn: this.promo.salesPromoSn
|
|
}
|
|
}
|
|
this.setWarehouseInfo(ajax_data)
|
|
this.setWarehouseInfo(ajax_data)
|
|
},
|
|
},
|
|
@@ -470,7 +481,8 @@
|
|
const ajax_data = {
|
|
const ajax_data = {
|
|
warehouseSn: sn,
|
|
warehouseSn: sn,
|
|
salesBillDetailSnList: snArr,
|
|
salesBillDetailSnList: snArr,
|
|
- salesBillSn: _this.salesBillSn
|
|
|
|
|
|
+ salesBillSn: _this.salesBillSn,
|
|
|
|
+ salesPromoSn: _this.promo.salesPromoSn
|
|
}
|
|
}
|
|
_this.setWarehouseInfo(ajax_data)
|
|
_this.setWarehouseInfo(ajax_data)
|
|
},
|
|
},
|
|
@@ -517,7 +529,8 @@
|
|
salesDetailUpdateQty({
|
|
salesDetailUpdateQty({
|
|
salesBillDetailSn: record.salesBillDetailSn,
|
|
salesBillDetailSn: record.salesBillDetailSn,
|
|
qty: record.qty,
|
|
qty: record.qty,
|
|
- salesBillSn: _this.salesBillSn
|
|
|
|
|
|
+ salesBillSn: _this.salesBillSn,
|
|
|
|
+ salesPromoSn: _this.promo.salesPromoSn
|
|
}).then(res => {
|
|
}).then(res => {
|
|
_this.resetSearchForm(true)
|
|
_this.resetSearchForm(true)
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
@@ -541,7 +554,7 @@
|
|
onOk () {
|
|
onOk () {
|
|
_this.delLoading = true
|
|
_this.delLoading = true
|
|
_this.spinning = true
|
|
_this.spinning = true
|
|
- salesDetailDel({ salesBillDetailSn: row.salesBillDetailSn, salesBillSn: _this.salesBillSn }).then(res => {
|
|
|
|
|
|
+ salesDetailDel({ salesBillDetailSn: row.salesBillDetailSn, salesBillSn: _this.salesBillSn, salesPromoSn: _this.promo.salesPromoSn }).then(res => {
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
_this.resetSearchForm(true)
|
|
_this.resetSearchForm(true)
|
|
_this.$message.success(res.message)
|
|
_this.$message.success(res.message)
|
|
@@ -566,6 +579,11 @@
|
|
this.isInster = true
|
|
this.isInster = true
|
|
this.spinning = true
|
|
this.spinning = true
|
|
salesDetailInsert({
|
|
salesDetailInsert({
|
|
|
|
+ salesPromoDetailDTO:{
|
|
|
|
+ salesPromoSn: this.promo.salesPromoSn,
|
|
|
|
+ promoRuleSn: this.promo.promoRuleSn,
|
|
|
|
+ promoSn: this.promo.promoSn
|
|
|
|
+ },
|
|
packQty: row.productPackQty,
|
|
packQty: row.productPackQty,
|
|
productSn: row.productSn,
|
|
productSn: row.productSn,
|
|
showCost: row.lastStockCost,
|
|
showCost: row.lastStockCost,
|