Commit d127e73c by shaojiawen

bug:TAPD

调整卡券包库存;
卡券编辑保存;
parent 93d6c294
......@@ -291,6 +291,13 @@ export default {
this.$tips({ message: '库存不能大于100w', type: 'warning' });
return;
}
let stockEnough = this.tableCardPackage.filter(function(value){
return params.count > value.remainedStock;
});
if(params.optType == 1 && stockEnough.length){
this.$tips({ message: (stockEnough[0].cardName + '库存不足'), type: 'warning' });
return;
}
this.$refs.adjust.loading = true;
params.couponPackageId = this.adjust.couponPackageId;
updatePackageStock(params).then(res => {
......
......@@ -134,9 +134,9 @@ export default {
params.applyList = JSON.stringify(params.applyList);
params.useConditionLimit = JSON.stringify(params.useConditionLimit);
this.loading = true;
if (params !== true) {
return;
}
// if (params !== true) {
// return;
// }
this.$emit('updateLoading', true);
updateCard(params).then(res => {
this.$emit('updateLoading', false);
......
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