lilei 6 kuukautta sitten
vanhempi
commit
3387ed1425

+ 6 - 3
src/views/salesManagement/salesQueryNew/comps/activeStatisticsList.vue

@@ -383,10 +383,13 @@ export default {
           ]
         },
         { field: 'totalCategory', key: '21', title: '款数', width: 50, align: 'center', fixed: 'right' },
-        { field: 'totalQty', key: '22', title: '数量', width: 50, align: 'center', fixed: 'right' },
-        { field: 'totalAmount', key: '23', title: '总金额', width: 60, align: 'center', fixed: 'right', renderBodyCell: ({ row, column, rowIndex }, h) => { return this.toThousands(row[column.field]) } },
-        { field: 'lossAmount', key: '24', title: '优惠金额', width: 60, align: 'center', fixed: 'right', renderBodyCell: ({ row, column, rowIndex }, h) => { return this.toThousands(row[column.field]) } }
+        { field: 'totalQty', key: '22', title: '数量', width: 50, align: 'center', fixed: 'right' }
       ]
+      // 销售价权限
+      if (this.type == 'view' && this.$hasPermissions('B_salesDetail_salesPrice') || this.type == 'edit' && this.$hasPermissions('B_salesEdit_salesPrice')) {
+        cols.push({ field: 'totalAmount', key: '23', title: '总金额', width: 60, align: 'center', fixed: 'right', renderBodyCell: ({ row, column, rowIndex }, h) => { return this.toThousands(row[column.field]) } })
+        cols.push({ field: 'lossAmount', key: '24', title: '优惠金额', width: 60, align: 'center', fixed: 'right', renderBodyCell: ({ row, column, rowIndex }, h) => { return this.toThousands(row[column.field]) } })
+      }
       // 编辑页面
       if (this.type == 'edit') {
         cols.push({

+ 5 - 5
src/views/salesManagement/salesQueryNew/comps/detailProductList.vue

@@ -165,11 +165,11 @@ export default {
                 <div>
                   款数:<strong>{record.total && record.total.totalCategory || '--'}</strong>;
                   数量:<strong>{record.total && record.total.totalQty || '--'}</strong>;
-                  {_this.$hasPermissions('B_salesEdit_salesPrice') ? (<span>总金额:<strong>{record.total && record.total.totalAmount || '--'}</strong>;</span>) : ('')}
-                  {_this.$hasPermissions('B_salesEdit_salesPrice') && record.promo && record.total && record.total.lossAmount ? (<span>优惠金额:<strong>{record.total.lossAmount}</strong>;</span>) : ('')}
-                  {_this.$hasPermissions('B_salesEdit_salesPrice') && record.promo && record.total && record.total.cgejyAmount > 0 && !isBuyPSendP ? (<span>采购额结余:<strong>{_this.toThousands(record.total.cgejyAmount)}</strong>;</span>) : ('')}
-                  {_this.$hasPermissions('B_salesEdit_salesPrice') && record.promo && record.total && record.total.cgejyAmount < 0 && !isBuyPSendP ? (<span>采购额超出:<strong>{_this.toThousands(record.total.cgeccAmount)}</strong>;</span>) : ('')}
-                  {_this.$hasPermissions('B_salesEdit_salesPrice') && record.promo && record.total && record.total.totalPromoGiftsAmount && isBuyPSendP ? (<span>促销产品转采购额金额:<strong>{_this.toThousands(record.total.totalPromoGiftsAmount)}</strong>;</span>) : ('')}
+                  {_this.$hasPermissions('B_salesDetail_salesPrice') ? (<span>总金额:<strong>{record.total && record.total.totalAmount || '--'}</strong>;</span>) : ('')}
+                  {_this.$hasPermissions('B_salesDetail_salesPrice') && record.promo && record.total && record.total.lossAmount ? (<span>优惠金额:<strong>{record.total.lossAmount}</strong>;</span>) : ('')}
+                  {_this.$hasPermissions('B_salesDetail_salesPrice') && record.promo && record.total && record.total.cgejyAmount > 0 && !isBuyPSendP ? (<span>采购额结余:<strong>{_this.toThousands(record.total.cgejyAmount)}</strong>;</span>) : ('')}
+                  {_this.$hasPermissions('B_salesDetail_salesPrice') && record.promo && record.total && record.total.cgejyAmount < 0 && !isBuyPSendP ? (<span>采购额超出:<strong>{_this.toThousands(record.total.cgeccAmount)}</strong>;</span>) : ('')}
+                  {_this.$hasPermissions('B_salesDetail_salesPrice') && record.promo && record.total && record.total.totalPromoGiftsAmount && isBuyPSendP ? (<span>促销产品转采购额金额:<strong>{_this.toThousands(record.total.totalPromoGiftsAmount)}</strong>;</span>) : ('')}
                   {record.total && record.total.expenseAccountFlag != 'WAIT' ? (<span style="color:red;">{record.total.expenseAccountFlagDictValue}</span>) : ''}
                 </div>
               </div>