浏览代码

修改bug

chenrui 7 月之前
父节点
当前提交
a5f3f073da

+ 5 - 0
src/views/easyPassManagement/promotionalActivities/chooseProductsModal.vue

@@ -116,6 +116,10 @@ export default {
       default: () => {
         return []
       }
+    },
+    propmSn: {
+      type: String,
+      default: ''
     }
   },
   data () {
@@ -159,6 +163,7 @@ export default {
         this.disabled = true
         this.spinning = true
         const params = Object.assign(parameter, this.queryParam)
+        params.promoSn = this.propmSn
         // 获取列表数据 有分页
         return shopPromoProductList(params).then(res => {
           let data

+ 7 - 6
src/views/easyPassManagement/promotionalActivities/edit.vue

@@ -23,7 +23,7 @@
           <span>基础信息</span>
         </div>
         <div v-if="form">
-          <a-descriptions :column="{ xs: 2, sm: 3, md: 3}">
+          <a-descriptions>
             <a-descriptions-item label="促销名称">{{ form.promoName || '--' }}</a-descriptions-item>
             <a-descriptions-item label="促销类型">{{ form.promoTypeDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="促销时间">
@@ -31,13 +31,13 @@
             </a-descriptions-item>
             <a-descriptions-item label="排序">{{ form.sort || '--' }}</a-descriptions-item>
             <a-descriptions-item label="加盟商开关权限">{{ form.dealerOpenFlag=='0'?'否':'是' }}</a-descriptions-item>
-            <a-descriptions-item span="3" label="参与经销商" v-if="form.allDealerFlag=='1'">全部经销商</a-descriptions-item>
-            <a-descriptions-item span="3" label="参与经销商" v-else>
+            <a-descriptions-item label="参与经销商" v-if="form.allDealerFlag=='1'">全部经销商</a-descriptions-item>
+            <a-descriptions-item label="参与经销商" v-else>
               <span v-if="!form.shopPromoDealerList||(form.shopPromoDealerList&&form.shopPromoDealerList.length==0)">--</span>
               <div v-else @click="handleSee">共<span class="link-bule">{{ form.shopPromoDealerList.length }}</span>个</div>
             </a-descriptions-item>
-            <a-descriptions-item span="3" label="封面图片"><img @click="handleCheckImg" :src="form.imageUrl" alt="图片走丢了" width="60" height="60" /></a-descriptions-item>
-            <a-descriptions-item span="3" label="促销描述">{{ form.description || '--' }}</a-descriptions-item>
+            <a-descriptions-item :span="3" label="封面图片"><img @click="handleCheckImg" :src="form.imageUrl" alt="图片走丢了" width="60" height="60" /></a-descriptions-item>
+            <a-descriptions-item :span="3" label="促销描述">{{ form.description || '--' }}</a-descriptions-item>
           </a-descriptions>
         </div>
       </a-card>
@@ -231,7 +231,7 @@
         style="padding: 0 60px;">保存</a-button>
     </div>
     <!-- 添加产品 -->
-    <chooseProduct ref="chooseProduct" :openModal="showProModal" @ok="addProductSuccess" @close="closeProductModal"></chooseProduct>
+    <chooseProduct :propmSn="$route.params.sn" :openModal="showProModal" @ok="addProductSuccess" @close="closeProductModal"></chooseProduct>
     <!--编辑  促销活动  基础信息    -->
     <add-promotion-modal
       ref="promotionAddModal"
@@ -349,6 +349,7 @@ export default {
       const _this = this
       // 情况产品列表
       _this.$refs.chooseProductList.clearTable()
+      _this.getDetail({ sn: _this.$route.params.sn })
     },
     // 禁用日期时间
     disabledDate (current) {