lilei 1 éve
szülő
commit
41526c8d9e

+ 11 - 10
src/views/salesManagement/salesQueryNew/comps/productNormalList.vue

@@ -78,16 +78,17 @@
     
     <!-- 已选配件列表 -->
     <s-table
-      class="sTable"
-      ref="table"
-      size="small"
-      :scroll="showTotal ? null :{ y: tableHeight }"
-      :rowKey="(record) => record.id"
-      :columns="columns"
-      :data="loadData"
-      :row-selection="{ columnWidth: 40 }"
-      @rowSelection="rowSelectionFun"
-      :pageSize="showTotal?10:30"
+      class="sTable" 
+      ref="table" 
+      size="small" 
+      :scroll="showTotal ? null :{ y: tableHeight }" 
+      :rowKey="(record) => record.id" 
+      :columns="columns" 
+      :data="loadData" 
+      :row-selection="{ columnWidth: 40 }" 
+      @rowSelection="rowSelectionFun" 
+      :pageSize="showTotal?10:30" 
+      :defaultLoadData="false"
       bordered>
       <!-- 产品编码 -->
       <template slot="productCode" slot-scope="text, record">

+ 8 - 1
src/views/salesManagement/salesQueryNew/edit.vue

@@ -35,7 +35,7 @@
           ref="productNormalList" 
           @insterOk="insterActiveOk"
           @openCpModal="openProductModal" 
-          :showTotal="activeList.length>0"
+          :showTotal="showTotal"
           :detailData="detailData" 
           :warehouseSn="warehouseSn" 
           :salesBillSn="salesBillSn"></productNormalList>
@@ -195,6 +195,9 @@ export default {
     }
   },
   computed: {
+    showTotal(){
+      return this.activeList.length > 0
+    },
     shippingAddress () {
       const shippingAddrProvinceName = this.detailData && this.detailData.salesBillExtEntity && this.detailData.salesBillExtEntity.shippingAddrProvinceName ? this.detailData.salesBillExtEntity.shippingAddrProvinceName : ''
       const shippingAddrCityName = this.detailData && this.detailData.salesBillExtEntity && this.detailData.salesBillExtEntity.shippingAddrCityName ? this.detailData.salesBillExtEntity.shippingAddrCityName : ''
@@ -245,6 +248,10 @@ export default {
         item.disabled = item.enabledFlag == 0
         this.activeDesKey['search-'+item.promoRuleSn] = false
       })
+      // 加载正常产品列表
+      setTimeout(()=> {
+        this.$refs.productNormalList.resetSearchForm()
+      }, 500)
     },
     // 获取是否有新活动
     async getNewActive(){