lilei il y a 1 an
Parent
commit
282ec948b5

+ 1 - 1
public/version.json

@@ -1,5 +1,5 @@
 {
   "message": "发现有新版本发布,确定更新系统?",
   "vendorJsVersion": "",
-  "version": 1705200875773
+  "version": 1705203715511
 }

+ 7 - 2
src/views/purchasingManagement/purchaseOrder/detail.vue

@@ -80,7 +80,7 @@
                 <span>{{ record.dealerProductEntity.code }}</span>
                 <a-badge v-if="record.promotionFlag && record.promotionFlag=='GIFT'" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
                 <a-badge v-if="record.promotionFlag && record.promotionFlag=='DISCOUNT'" count="特" :number-style="{ backgroundColor: '#faad14', zoom:'80%',marginLeft:'5px' }"></a-badge>
-                <a-badge v-if="record.convertPromoGiftsFlag && record.convertPromoGiftsFlag==1" count="转" :number-style="{ backgroundColor: '#ff0000', zoom:'80%',marginLeft:'5px' }"></a-badge>
+                <a-badge v-if="showConvertPromoGIftQty && record.convertPromoGiftsFlag && record.convertPromoGiftsFlag==1" count="转" :number-style="{ backgroundColor: '#ff0000', zoom:'80%',marginLeft:'5px' }"></a-badge>
               </template>
               <!-- 采购数量 -->
               <template slot="origqty" slot-scope="text, record">
@@ -172,6 +172,11 @@ export default {
     }
   },
   computed: {
+    showConvertPromoGIftQty(){
+      const ret = this.detail && (this.detail.totalPutQty + this.detail.totalWaitPutQty + this.detail.totalCancelQty
+ + this.detail.totalConvertPromoGiftsQty) == this.detail.totalQty
+      return ret
+    },
     columns () {
       const _this = this
       const arr = [
@@ -192,7 +197,7 @@ export default {
         arr.splice(6, 0, { title: '采购金额', dataIndex: 'discountedAmount', width: '7%', align: 'right', scopedSlots: { customRender: 'amount' } })
         arr.splice(8, 0, { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
       }
-      if(this.detail && this.detail.totalConvertPromoGiftsQty){
+      if(this.showConvertPromoGIftQty){
         arr.push({ slots: { title: 'customTitle1' }, dataIndex: 'convertPromoGiftsQty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
         arr.push({ slots: { title: 'customTitle2' }, dataIndex: 'convertPromoGiftsAmount', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
       }

+ 7 - 2
src/views/purchasingManagement/purchaseOrderNew/detail.vue

@@ -83,7 +83,7 @@
             <span>{{ record.dealerProductEntity.code }}</span>
             <a-badge v-if="record.promotionFlag && record.promotionFlag=='GIFT'" count="促" :number-style="{ backgroundColor: '#52c41a', zoom:'80%',marginLeft:'5px' }"></a-badge>
             <a-badge v-if="record.promotionFlag && record.promotionFlag=='DISCOUNT'" count="特" :number-style="{ backgroundColor: '#faad14', zoom:'80%',marginLeft:'5px' }"></a-badge>
-            <a-badge v-if="detail&&detail.totalConvertPromoGiftsQty&&record.convertPromoGiftsFlag&&record.convertPromoGiftsFlag==1" count="转" :number-style="{ backgroundColor: '#0055ff', zoom:'80%',marginLeft:'5px' }"></a-badge>
+            <a-badge v-if="showConvertPromoGIftQty&&record.convertPromoGiftsFlag&&record.convertPromoGiftsFlag==1" count="转" :number-style="{ backgroundColor: '#0055ff', zoom:'80%',marginLeft:'5px' }"></a-badge>
           </template>
           <!-- 采购数量 -->
           <template slot="origqty" slot-scope="text, record">
@@ -174,6 +174,11 @@ export default {
     }
   },
   computed: {
+    showConvertPromoGIftQty(){
+         const ret = this.detail && (this.detail.totalPutQty + this.detail.totalWaitPutQty + this.detail.totalCancelQty
+    + this.detail.totalConvertPromoGiftsQty) == this.detail.totalQty
+         return ret
+       },
     columns () {
       const _this = this
       const arr = [
@@ -194,7 +199,7 @@ export default {
         arr.splice(6, 0, { title: '采购金额', dataIndex: 'discountedAmount', width: '11%', align: 'right', scopedSlots: { customRender: 'amount' } })
         arr.splice(8, 0, { title: '审核订单金额', dataIndex: 'pushedAmount', width: '8%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
       }
-      if(this.detail && this.detail.totalConvertPromoGiftsQty){
+      if(this.showConvertPromoGIftQty){
         arr.push({ slots: { title: 'customTitle1' }, dataIndex: 'convertPromoGiftsQty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
         arr.push({ slots: { title: 'customTitle2' }, dataIndex: 'convertPromoGiftsAmount', width: '7%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } })
       }