chenrui před 1 rokem
rodič
revize
65e793c2ac

+ 28 - 13
src/views/reportData/promotionSalesOrderReport/list.vue

@@ -134,31 +134,44 @@
               <a-col span="24">
                 <a-row>
                   <a-col
-                    span="4">销售额:{{ $hasPermissions('M_promotionSalesOrderReportList_salesPrice')&&(totalData.totalSaleAmount || totalData.totalSaleAmount==0) ? toThousands(totalData.totalSaleAmount) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_salesPrice')">销售额:{{ (totalData.totalSaleAmount || totalData.totalSaleAmount==0) ? toThousands(totalData.totalSaleAmount) : '--' }}</a-col>
                   <a-col
-                    span="4">促销成本费用:{{ $hasPermissions('M_promotionSalesOrderReportList_costPrice')&&(totalData.promoCostFee || totalData.promoCostFee==0) ? toThousands(totalData.promoCostFee) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_costPrice')">促销成本费用:{{ (totalData.promoCostFee || totalData.promoCostFee==0) ? toThousands(totalData.promoCostFee) : '--' }}</a-col>
                   <a-col
-                    span="4">促销成本费用比:{{ $hasPermissions('M_promotionSalesOrderReportList_costPrice')&&totalData.promoCostFeeRate ? (totalData.promoCostFeeRate*100).toFixed(2)+'%' : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_costPrice')">促销成本费用比:{{ totalData.promoCostFeeRate ? (totalData.promoCostFeeRate*100).toFixed(2)+'%' : '--' }}</a-col>
                   <a-col
-                    span="4">促销销售费用:{{ $hasPermissions('M_promotionSalesOrderReportList_salesPrice')&&(totalData.promoSaleFee || totalData.promoSaleFee==0) ? toThousands(totalData.promoSaleFee) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_salesPrice')">促销销售费用:{{ (totalData.promoSaleFee || totalData.promoSaleFee==0) ? toThousands(totalData.promoSaleFee) : '--' }}</a-col>
                   <a-col
-                    span="4">促销销售费用比:{{ $hasPermissions('M_promotionSalesOrderReportList_salesPrice')&&totalData.promoSaleFeeRate ? (totalData.promoSaleFeeRate*100).toFixed(2)+'%' : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_salesPrice')">促销销售费用比:{{ totalData.promoSaleFeeRate ? (totalData.promoSaleFeeRate*100).toFixed(2)+'%' : '--' }}</a-col>
                   <a-col
-                    span="4">参与活动销售额:{{ $hasPermissions('M_promotionSalesOrderReportList_salesPrice')&&(totalData.promoSaleAmount || totalData.promoSaleAmount==0) ? toThousands(totalData.promoSaleAmount) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_salesPrice')">参与活动销售额:{{ (totalData.promoSaleAmount || totalData.promoSaleAmount==0) ? toThousands(totalData.promoSaleAmount) : '--' }}</a-col>
                   <a-col
-                    span="4">未参与活动销售额:{{ $hasPermissions('M_promotionSalesOrderReportList_salesPrice')&&(totalData.notpromotionSale || totalData.notpromotionSale==0) ? toThousands(totalData.notpromotionSale) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_salesPrice')">未参与活动销售额:{{ (totalData.notpromotionSale || totalData.notpromotionSale==0) ? toThousands(totalData.notpromotionSale) : '--' }}</a-col>
                   <a-col
-                    span="4">调拨物料成本费用:{{ $hasPermissions('M_promotionSalesOrderReportList_costPrice')&&(totalData.allocateCost || totalData.allocateCost==0) ? toThousands(totalData.allocateCost) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_costPrice')">调拨物料成本费用:{{ (totalData.allocateCost || totalData.allocateCost==0) ? toThousands(totalData.allocateCost) : '--' }}</a-col>
                   <a-col
-                    span="4">调拨物料销售费用:{{ $hasPermissions('M_promotionSalesOrderReportList_salesPrice')&&(totalData.allocateSaleAmount || totalData.allocateSaleAmount==0) ? toThousands(totalData.allocateSaleAmount) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_salesPrice')">调拨物料销售费用:{{ (totalData.allocateSaleAmount || totalData.allocateSaleAmount==0) ? toThousands(totalData.allocateSaleAmount) : '--' }}</a-col>
                   <a-col
-                    span="4">促销成本费用+物料成本费用合计:{{ $hasPermissions('M_promotionSalesOrderReportList_costPrice')&&(totalData.promoCostFeeAndAllocateCost || totalData.promoCostFeeAndAllocateCost==0)? toThousands(totalData.promoCostFeeAndAllocateCost) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_costPrice')">促销成本费用+物料成本费用合计:{{ (totalData.promoCostFeeAndAllocateCost || totalData.promoCostFeeAndAllocateCost==0)? toThousands(totalData.promoCostFeeAndAllocateCost) : '--' }}</a-col>
                   <a-col
-                    span="4">成本合计占比:{{ $hasPermissions('M_promotionSalesOrderReportList_costPrice')&&totalData.totalCostRate ? (totalData.totalCostRate*100).toFixed(2)+'%' : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_costPrice')">成本合计占比:{{ totalData.totalCostRate ? (totalData.totalCostRate*100).toFixed(2)+'%' : '--' }}</a-col>
                   <a-col
-                    span="4">促销销售费用+物料销售费用合计:{{ $hasPermissions('M_promotionSalesOrderReportList_salesPrice')&&(totalData.promoSaleFeeAndAllocateAmount || totalData.promoSaleFeeAndAllocateAmount==0) ? toThousands(totalData.promoSaleFeeAndAllocateAmount) : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_salesPrice')">促销销售费用+物料销售费用合计:{{ (totalData.promoSaleFeeAndAllocateAmount || totalData.promoSaleFeeAndAllocateAmount==0) ? toThousands(totalData.promoSaleFeeAndAllocateAmount) : '--' }}</a-col>
                   <a-col
-                    span="4">销售合计占比:{{ $hasPermissions('M_promotionSalesOrderReportList_salesPrice')&&totalData.totalSaleRate ? (totalData.totalSaleRate*100).toFixed(2)+'%' : '--' }}</a-col>
+                    span="4"
+                    v-if="$hasPermissions('M_promotionSalesOrderReportList_salesPrice')">销售合计占比:{{ totalData.totalSaleRate ? (totalData.totalSaleRate*100).toFixed(2)+'%' : '--' }}</a-col>
                 </a-row>
               </a-col>
             </a-row>
@@ -357,9 +370,11 @@ export default {
           _this.showExport = true
           _this.exportLoading = true
           _this.spinning = true
+          _this.$store.state.app.curActionPermission = 'B_brandTypeReportExport'
           hdExportExcel(brandTypeReportExport, params, '促销销售单报表(统计)', function () {
             _this.exportLoading = false
             _this.spinning = false
+            _this.$store.state.app.curActionPermission = ''
           })
         } else {
           return false