yangan
2024-08-05 1a92541e81f43ea9b544919400b0835bb2b7ee2b
pages/loadUnload-page/selectTarget/selectTarget.vue
@@ -181,8 +181,8 @@
                     </u--input>
                     <text> {{isNumOk ? '件' : '吨' }}</text>
                     </view>
                     <!-- pvc 并且是大包 -->
                     <view class="pvcBig" v-if="activeObj.productName === 'PVC' && activeObj.packingType === 5">
                     <!-- 聚氯乙烯树脂 并且是大包 -->
                     <view class="pvcBig" v-if="activeObj.productName === '聚氯乙烯树脂' && activeObj.packingType === 5">
                        
                     </view>
                     <view v-if="isNumOk && activeObj.productQuantity">当前数量:{{activeObj.productQuantity}}件</view>
@@ -236,7 +236,6 @@
</template>
<script>
   import { BaseUrl } from '@/api/publicInterface.js'
   import { mapState, mapMutations, mapGetters } from 'vuex';
   export default {
      props: {
@@ -384,11 +383,18 @@
               uni.hideLoading()
               if (res.code === 0) {
                  this.firstClassActionsList = res.data;
                  this.firstClassActionsList.unshift({name:'全部',id:res.data.map(item=>item.id).join(',')})
                  if(res.data.length){
                     this.dataForm.bunkerIds = res.data.map(item=>item.id).join(',')
                     uni.setStorageSync('bunkerIds',res.data.map(item=>item.id).join(','))
                     this.firstClassActionsList.unshift({name:'全部',id:res.data.map(item=>item.id).join(',')})
                     this.dataForm.firstClass = '全部'
                     if(!uni.getStorageSync('bunkerIds')){
                        this.dataForm.firstClass = '全部'
                        this.dataForm.bunkerIds = res.data.map(item=>item.id).join(',')
                         uni.setStorageSync('bunkerIds',res.data.map(item=>item.id).join(','))
                     }else{
                        this.dataForm.bunkerIds = uni.getStorageSync('bunkerIds');
                        uni.setStorageSync('bunkerIds',this.dataForm.bunkerIds)
                     }
                     this.getDetailData();
               
                  }
@@ -396,7 +402,7 @@
                  this.$u.toast('加载失败')
               }
            }).then(() => {
               this.getUserInfo()
            })
         },
         firstClassSelect() {
@@ -469,7 +475,7 @@
                  
            //    }
            // })
         //  计件:   0 pvc type
         //  计件:   0 聚氯乙烯树脂 type
         //  折吨: 
            this.activeObj = item;
            if( (parintItem.orderType === '外购' ||parintItem.orderType === '外购退' ) && item.isWeight === 0){
@@ -484,8 +490,8 @@
               this.isNumOk = false;
               this.isClean = false;
            }
            //pvc
             if(parintItem.orderType ==='外销' && item.productName ==='PVC' && (item.packingType === 3 || item.packingType === 4)){
            //聚氯乙烯树脂
             if(parintItem.orderType ==='外销' && (/聚氯乙烯树脂/.test(item.productName) || item.productName === 'PVC')  && (item.packingType === 3 || item.packingType === 4)){
               this.isNumOk = true;
               this.isClean  = false;
            }
@@ -497,7 +503,7 @@
            }
            //
            //pvc大包自动计算折吨
            if(item.productName === 'PVC' && item.packingType === 5){
            if((/聚氯乙烯树脂/.test(item.productName) || item.productName === 'PVC')  && item.packingType === 5){
               this.isNumOk = true;
               this.isClean = false;
            }