lilei 1 month ago
parent
commit
7d5788e49f

+ 18 - 17
src/views/salesManagement/salesQueryNew/comps/activeStatisticsList.vue

@@ -137,8 +137,8 @@ export default {
       },
       },
       // 筛选
       // 筛选
       ruleTypeList: [
       ruleTypeList: [
-        { value: 'BUY_PROD_GIVE_PROD', label: '产品送产品', selected: true },
-        { value: 'BUY_PROD_GIVE_MONEY', label: '产品送采购额', selected: true },
+        { value: 'BUY_PROD_GIVE_PROD', label: '产品送产品', selected: true },
+        { value: 'BUY_PROD_GIVE_MONEY', label: '产品送采购额', selected: true },
         { value: 'PROMO_PROD', label: '特价活动', selected: true }
         { value: 'PROMO_PROD', label: '特价活动', selected: true }
       ],
       ],
       ruleEnableList: [
       ruleEnableList: [
@@ -265,7 +265,8 @@ export default {
               title: '累计',
               title: '累计',
               width: 50,
               width: 50,
               align: 'center',
               align: 'center',
-              renderBodyCell: ({ row, column, rowIndex }, h) => formatTd(row, column, rowIndex, 'gateUnit', _this.openTotalProduct)
+              renderBodyCell: ({ row, column, rowIndex }, h) => formatTd(row, column, rowIndex, 'gateUnit')
+              // renderBodyCell: ({ row, column, rowIndex }, h) => formatTd(row, column, rowIndex, 'gateUnit', _this.openTotalProduct)
             },
             },
             {
             {
               field: 'geteBalance',
               field: 'geteBalance',
@@ -339,7 +340,8 @@ export default {
               title: '累计',
               title: '累计',
               width: 50,
               width: 50,
               align: 'center',
               align: 'center',
-              renderBodyCell: ({ row, column, rowIndex }, h) => formatTd(row, column, rowIndex, 'regularUnit', _this.openTotalProduct)
+              renderBodyCell: ({ row, column, rowIndex }, h) => formatTd(row, column, rowIndex, 'regularUnit')
+              // renderBodyCell: ({ row, column, rowIndex }, h) => formatTd(row, column, rowIndex, 'regularUnit', _this.openTotalProduct)
             },
             },
             {
             {
               field: 'regularBaseVal',
               field: 'regularBaseVal',
@@ -420,17 +422,16 @@ export default {
         { field: 'totalCategory', key: '22', title: '款数', width: 50, align: 'center', fixed: 'right' },
         { field: 'totalCategory', key: '22', title: '款数', width: 50, align: 'center', fixed: 'right' },
         { field: 'totalQty', key: '23', title: '数量', width: 50, align: 'center', fixed: 'right' }
         { field: 'totalQty', key: '23', title: '数量', width: 50, align: 'center', fixed: 'right' }
       ]
       ]
-      if (this.type == 'edit') {
-        cols.unshift({
-          field: '',
-          key: '0',
-          type: 'checkbox',
-          title: '',
-          width: 23,
-          align: 'center',
-          fixed: 'left'
-        })
-      }
+      // 复选框
+      cols.unshift({
+        field: '',
+        key: '0',
+        type: 'checkbox',
+        title: '',
+        width: 23,
+        align: 'center',
+        fixed: 'left'
+      })
       // 销售价权限
       // 销售价权限
       if (this.type == 'view' && this.$hasPermissions('B_salesDetail_salesPrice') || this.type == 'edit' && this.$hasPermissions('B_salesEdit_salesPrice')) {
       if (this.type == 'view' && this.$hasPermissions('B_salesDetail_salesPrice') || this.type == 'edit' && this.$hasPermissions('B_salesEdit_salesPrice')) {
         cols.push({ field: 'totalAmount', key: '24', title: '总金额', width: 60, align: 'center', fixed: 'right', renderBodyCell: ({ row, column, rowIndex }, h) => { return this.toThousands(row[column.field]) } })
         cols.push({ field: 'totalAmount', key: '24', title: '总金额', width: 60, align: 'center', fixed: 'right', renderBodyCell: ({ row, column, rowIndex }, h) => { return this.toThousands(row[column.field]) } })
@@ -541,8 +542,8 @@ export default {
         })
         })
       }
       }
       return cols.filter((item, index) => {
       return cols.filter((item, index) => {
-        const i = this.type === 'edit' ? index - 1 : index
-        return this.showCols.includes(i.toString()) || (this.type === 'edit' && index == 0) || index > (this.type === 'edit' ? 8 : 7)
+        const i = index - 1
+        return this.showCols.includes(i.toString()) || index == 0 || index > 12
       })
       })
     }
     }
   },
   },

+ 13 - 4
src/views/salesManagement/salesQueryNew/comps/detailProductList.vue

@@ -1,10 +1,12 @@
 <template>
 <template>
   <!-- 已选配件列表 -->
   <!-- 已选配件列表 -->
   <a-spin :spinning="spinning" tip="Loading...">
   <a-spin :spinning="spinning" tip="Loading...">
-    <div :style="{position:'relative'}">
+    <div :style="{position:'relative',background:'#fff'}">
       <div style="height:10px;"></div>
       <div style="height:10px;"></div>
       <ve-table
       <ve-table
         border-y
         border-y
+        border-x
+        border-around
         :scroll-width="0"
         :scroll-width="0"
         :max-height="tableHeight"
         :max-height="tableHeight"
         :show-header="showTableHead"
         :show-header="showTableHead"
@@ -109,6 +111,11 @@ export default {
     showTransferDealer: {// 显示发货经销商库存
     showTransferDealer: {// 显示发货经销商库存
       type: Boolean,
       type: Boolean,
       default: true
       default: true
+    },
+    // 已勾选的活动sn
+    salesPromoSnSet: {
+      type: Array,
+      default: () => []
     }
     }
   },
   },
   data () {
   data () {
@@ -291,6 +298,9 @@ export default {
     // 是否显示城市价格变化时
     // 是否显示城市价格变化时
     showCityPrice (newValue, oldValue) {
     showCityPrice (newValue, oldValue) {
       this.isCityPrice = newValue
       this.isCityPrice = newValue
+    },
+    salesPromoSnSet (newValue, oldValue) {
+      this.searchTable()
     }
     }
   },
   },
   methods: {
   methods: {
@@ -355,7 +365,7 @@ export default {
         }
         }
       } else {
       } else {
         // 查询活动产品明细列表
         // 查询活动产品明细列表
-        this.dataSource = await salesDetailExtPromoList({ salesPromoSnSet: [], ...params }).then(res => res.data || [])
+        this.dataSource = await salesDetailExtPromoList({ salesPromoSnSet: this.salesPromoSnSet, ...params }).then(res => res.data || [])
       }
       }
 
 
       // 没用数据,则不显示当前表格
       // 没用数据,则不显示当前表格
@@ -422,9 +432,8 @@ export default {
         color: #999;
         color: #999;
         text-align: center;
         text-align: center;
         padding: 20px;
         padding: 20px;
-        position: absolute;
-        top: 50px;
         width: 100%;
         width: 100%;
+        background: #fff;
     }
     }
     .table-header-cell-center{
     .table-header-cell-center{
       text-align: center!important;
       text-align: center!important;

+ 9 - 2
src/views/salesManagement/salesQueryNew/detail.vue

@@ -234,6 +234,7 @@
         <activeStatisticsList
         <activeStatisticsList
           ref="activeTjList"
           ref="activeTjList"
           type="view"
           type="view"
+          @selected="active => salesPromoSnSet = active"
           :activeList="activeList"
           :activeList="activeList"
           :warehouseSn="warehouseSn"
           :warehouseSn="warehouseSn"
           :salesBillSn="$route.params.sn || bizSn"
           :salesBillSn="$route.params.sn || bizSn"
@@ -248,6 +249,7 @@
           :warehouseSn="warehouseSn"
           :warehouseSn="warehouseSn"
           :promoFlag="promoFlag"
           :promoFlag="promoFlag"
           :salesBillSn="$route.params.sn || bizSn"
           :salesBillSn="$route.params.sn || bizSn"
+          :salesPromoSnSet="salesPromoSnSet"
           :authCode="authCode"
           :authCode="authCode"
           :showCityPrice="isCityPrice"
           :showCityPrice="isCityPrice"
           :showAveragePrice="isAveragePrice"
           :showAveragePrice="isAveragePrice"
@@ -438,6 +440,7 @@ export default {
       openTransferOrder: false, // 打开转单弹窗
       openTransferOrder: false, // 打开转单弹窗
       selectedDealer: '', // 发货经销商名称
       selectedDealer: '', // 发货经销商名称
       selectedDealerSn: undefined, // 发货经销商sn
       selectedDealerSn: undefined, // 发货经销商sn
+      salesPromoSnSet: [], // 当前勾选的活动sn
       chooseDealerList: [], // 发货经销商数据
       chooseDealerList: [], // 发货经销商数据
       colsOptions: [],
       colsOptions: [],
       colsValue: []
       colsValue: []
@@ -512,7 +515,11 @@ export default {
         { label: '特价', value: '4' },
         { label: '特价', value: '4' },
         { label: '正价产品', value: '5' },
         { label: '正价产品', value: '5' },
         { label: '促销品', value: '6' },
         { label: '促销品', value: '6' },
-        { label: '采购额', value: '7' }
+        { label: '采购额', value: '7' },
+        { label: '款数', value: '8' },
+        { label: '数量', value: '9' },
+        { label: '总金额', value: '10' },
+        { label: '优惠金额', value: '11' }
       ]
       ]
       this.colsValue = this.colsOptions.map(item => item.value)
       this.colsValue = this.colsOptions.map(item => item.value)
     },
     },
@@ -531,7 +538,7 @@ export default {
       if (type == 'normal') {
       if (type == 'normal') {
         this.hideNormalTable = true
         this.hideNormalTable = true
       } else {
       } else {
-        this.hideActiveTable = true
+        // this.hideActiveTable = true
       }
       }
     },
     },
     // 编辑
     // 编辑

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

@@ -285,7 +285,11 @@ export default {
         { label: '特价', value: '4' },
         { label: '特价', value: '4' },
         { label: '正价产品', value: '5' },
         { label: '正价产品', value: '5' },
         { label: '促销品', value: '6' },
         { label: '促销品', value: '6' },
-        { label: '采购额', value: '7' }
+        { label: '采购额', value: '7' },
+        { label: '款数', value: '8' },
+        { label: '数量', value: '9' },
+        { label: '总金额', value: '10' },
+        { label: '优惠金额', value: '11' }
       ]
       ]
       this.colsValue = this.colsOptions.map(item => item.value)
       this.colsValue = this.colsOptions.map(item => item.value)
     },
     },