lilei 2 days ago
parent
commit
c63317c79e

+ 3 - 8
src/views/promotionRulesManagement/dealerPromotions/specialOfferModal.vue

@@ -488,17 +488,16 @@ export default {
           console.log(_this.setTableData)
           if (_this.form.discountType != '0' && _this.setTableData) {
             const hasTemp = _this.setTableData.some(item => {
-              if (_this.form.discountType == '2' || _this.setTableData.length == 1) {
+              if (_this.form.discountType == '2') {
                 return item.provinceValue == undefined || item.cityValue == undefined || item.specialValue == undefined
               }
-              return item.orginAmountValue == 0 || item.provinceValue == undefined || item.cityValue == undefined || item.specialValue == undefined
+              return item.orginAmountValue == undefined || item.provinceValue == undefined || item.cityValue == undefined || item.specialValue == undefined
             })
             if (hasTemp) {
-              _this.$message.warning(_this.form.discountType == '2' || _this.setTableData.length == 1 ? '特价规则条件不能为空!' : '特价规则条件不能为空且原价金额必需大于0!')
+              _this.$message.warning('特价规则条件不能为空!')
               return
             }
           }
-          console.log(_this.form)
           // 验证表格必填项
           const form = JSON.parse(JSON.stringify(_this.form))
           if (form.gateFlag === '1') {
@@ -525,7 +524,6 @@ export default {
           if (_this.isJudge(form.specialProductList, '特价')) {
             return
           }
-          console.log(form)
           // 校验产品折扣手动输入必填项
           if (form.discountType === '0') {
             const isCountEmpty = _this.isNumEmpty(form.specialProductList)
@@ -542,7 +540,6 @@ export default {
             form.cityValue = _this.setTableData[0].cityValue
             form.specialValue = _this.setTableData[0].specialValue
           } else {
-            console.log(form)
             // 折扣
             form.specialDiscountList = _this.setTableData.map((item, index) => {
               return {
@@ -554,7 +551,6 @@ export default {
               }
             })
           }
-          console.log(form)
           // 组后端所需数据
           form.promotionSn = _this.promotionSn
           // 门槛描述
@@ -581,7 +577,6 @@ export default {
           }
           infoDetail += `<div>${form.borrowTimeLimtType ? '产品累计:' + (form.borrowTimeLimtType == 'LENGTH_YEAR' ? '近一年' : '本年度') : ''}${form.borrowedShowFlag === '1' ? ',加盟商显示“转促”标签;' : ''}</div>`
           form.ruleInfo = infoDetail
-          console.log(form)
           _this.spinning = true
           promotionSave(form).then(res => {
             if (res.status == 200) {