zhouhao 2 سال پیش
والد
کامیت
abf896e2e5
3فایلهای تغییر یافته به همراه104 افزوده شده و 64 حذف شده
  1. 85 56
      src/views/deposit_home/refund_list.vue
  2. 1 0
      src/views/supply/pickup/check.vue
  3. 18 8
      src/views/supply/pickup/components/pickup_form.vue

+ 85 - 56
src/views/deposit_home/refund_list.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="app-container">
-    <div v-if="(showSurrender==0)">
+    <div v-if="(showSurrender == 0)">
       <!-- 筛选条件 -->
       <div>
         <Collapse :screen-form="screenForm">
@@ -69,7 +69,6 @@
                   <el-form-item label="是否退押 " prop="isRefundDeposit">
                     <el-select v-model="screenForm.isRefundDeposit" style="width: 100%" placeholder="请选择是否退押 ">
                       <el-option label="默认" :value="null" />
-
                       <el-option v-for="item in refundDepositArr" :key="item.value" :label="item.label"
                         :value="item.value" />
                     </el-select>
@@ -77,11 +76,10 @@
                 </el-col>
                 <el-col :xs="24" :sm="12" :lg="6">
                   <el-form-item label="状态 " prop="examineStatus">
-                    <el-select v-model="screenForm.examineStatus" style="width: 100%" placeholder="请选择状态 ">
-                      <el-option label="默认" :value="null" />
-
-                      <el-option v-for="item in examineStatusArr" :key="item.value" :label="item.label"
-                        :value="item.value" />
+                    <el-select v-default-select="[examine]" v-model="screenForm.examineStatus" style="width: 100%"
+                      placeholder="请选择状态 " multiple>
+                      <el-option :disabled="examine == item.value" v-for="item in examineStatusArr" :key="item.value"
+                        :label="item.label" :value="item.value" />
                     </el-select>
                   </el-form-item>
                 </el-col>
@@ -182,23 +180,13 @@
                     <el-form-item label="寄厂日期" style="margin-bottom: 0">
                       <div class="fanwei">
                         <el-form-item prop="startMailFactoryDate">
-                          <el-date-picker
-                            v-model="screenForm.startMailFactoryDate"
-                            value-format="yyyy-MM-dd HH:mm:ss"
-                            class="dateStyle"
-                            type="datetime"
-                            placeholder="选择日期"
-                          />
+                          <el-date-picker v-model="screenForm.startMailFactoryDate" value-format="yyyy-MM-dd HH:mm:ss"
+                            class="dateStyle" type="datetime" placeholder="选择日期" />
                         </el-form-item>
                         <span>-</span>
                         <el-form-item prop="endMailFactoryDate">
-                          <el-date-picker
-                            v-model="screenForm.endMailFactoryDate"
-                            value-format="yyyy-MM-dd HH:mm:ss"
-                            class="dateStyle"
-                            type="datetime"
-                            placeholder="选择日期"
-                          />
+                          <el-date-picker v-model="screenForm.endMailFactoryDate" value-format="yyyy-MM-dd HH:mm:ss"
+                            class="dateStyle" type="datetime" placeholder="选择日期" />
                         </el-form-item>
                       </div>
                     </el-form-item>
@@ -208,24 +196,14 @@
                       <div class="fanwei">
                         <el-form-item prop="startSettlementDate">
 
-                          <el-date-picker
-                            v-model="screenForm.startSettlementDate"
-                            value-format="yyyy-MM-dd HH:mm:ss"
-                            class="dateStyle"
-                            type="datetime"
-                            placeholder="选择日期"
-                          />
+                          <el-date-picker v-model="screenForm.startSettlementDate" value-format="yyyy-MM-dd HH:mm:ss"
+                            class="dateStyle" type="datetime" placeholder="选择日期" />
                         </el-form-item>
                         <span>-</span>
                         <el-form-item prop="endSettlementDate">
 
-                          <el-date-picker
-                            v-model="screenForm.endSettlementDate"
-                            value-format="yyyy-MM-dd HH:mm:ss"
-                            class="dateStyle"
-                            type="datetime"
-                            placeholder="选择日期"
-                          />
+                          <el-date-picker v-model="screenForm.endSettlementDate" value-format="yyyy-MM-dd HH:mm:ss"
+                            class="dateStyle" type="datetime" placeholder="选择日期" />
                         </el-form-item>
                       </div>
                     </el-form-item>
@@ -457,7 +435,7 @@
                 <!-- <el-button type="text" class="textColor"
                   v-if="(scope.row.examineStatus == 'OK' ||scope.row.examineStatus == 'AMEND') && isCustomer"
                   @click="replenishClick(scope.row.depositManageId)">补充资料</el-button> -->
-                  <el-button type="text" class="textColor"
+                <el-button type="text" class="textColor"
                   v-if="scope.row.examineStatus == 'WAIT_REVIEW' && $checkBtnRole('examine', $route.meta.roles)"
                   @click="reexamineClick(scope.row.depositManageId)">复核</el-button>
 
@@ -466,9 +444,9 @@
                   scope.row.examineStatus == 'OK' ||
                   scope.row.examineStatus == 'FAIL' ||
                   scope.row.examineStatus == 'WAIT_REVIEW' ||
-                  scope.row.examineStatus ==  'REVIEW' ||
-                  scope.row.examineStatus ==  'AMEND'
-
+                  scope.row.examineStatus == 'REVIEW' ||
+                  scope.row.examineStatus == 'AMEND'
+                
                 " @click="infoFn(scope.row.depositManageId)">详情</el-button>
               </template>
             </el-table-column>
@@ -482,9 +460,9 @@
         </div>
       </div>
     </div>
-    <refund-list-detail v-else-if="(showSurrender==1)" :detail-id="detailId" @updateList="updateList" />
-  <refund-replenish v-else-if="(showSurrender==2)" :detail-id="detailId" @updateList="updateList"/>
-    <refund-reexamine v-else-if="(showSurrender==3)" :detail-id="detailId" @updateList="updateList"/>
+    <refund-list-detail v-else-if="(showSurrender == 1)" :detail-id="detailId" @updateList="updateList" />
+    <refund-replenish v-else-if="(showSurrender == 2)" :detail-id="detailId" @updateList="updateList" />
+    <refund-reexamine v-else-if="(showSurrender == 3)" :detail-id="detailId" @updateList="updateList" />
     <examine-dialog :is-show.sync="isShowExamineDialog" :examine-form.sync="examineForm" />
   </div>
 </template>
@@ -511,6 +489,35 @@ export default {
     RefundReplenish,
     RefundReexamine
   },
+  directives: {
+    'defaultSelect': {
+      bind(el, binding) {
+        const [defaultValues] = binding.value
+        // el.style.display = 'none'
+      //   console.log(defaultValues);
+      //   const dealStyle = function (tags) {
+
+      //     tags.forEach((el, index) => {
+      //       if (index <= defaultValues.length - 1 && ![...el.classList].includes('select-tag-close-none')) {
+             
+      //       }
+      //     })
+      //   }
+
+
+      //   const tags = el.querySelectorAll('.el-tag__close')
+      //   console.log(el,tags);
+      //   if (tags.length == 0) {
+       
+      //     const tagTemp = el.querySelectorAll('.el-tag__close')
+      //     console.log(tagTemp);
+      //     dealStyle(tagTemp)
+      //   } else {
+      //     dealStyle(tags)
+      //   }
+      }
+    }
+  },
   data() {
     return {
       importFileList: [],
@@ -519,6 +526,7 @@ export default {
       pageSize: 10, // 每页数量
       listTotal: 0, // 列表总数
       dataList: [], // 列表数据
+      examine: '',
       screenForm: {
         confirmName: '', // 审核人
         createName: '', // 创建人
@@ -526,7 +534,7 @@ export default {
         endDeliverTime: '', // 发货申请日期-结束
         enginOrderNo: '', // 工程订单编号
         enginOrderType: 'HOME', // 工程订单类型
-        examineStatus: '', // 状态
+        examineStatus: [''], // 状态
         refEnginRecordNo: '', // 登录单号
         refProjectName: '', // 项目名称
         refUseUnit: '', // 使用单位
@@ -549,9 +557,9 @@ export default {
         geLiInerNote: '',
         startFactoryNo: '',
         endFactoryNo: '',
-        settlementStatus:'',mailFactoryStatus:'',
+        settlementStatus: '', mailFactoryStatus: '',
 
-        startInstallTime:'',endInstallTime:'',startSettlementDate:'',endSettlementDate:'',endMailFactoryDate:'',startMailFactoryDate:''
+        startInstallTime: '', endInstallTime: '', startSettlementDate: '', endSettlementDate: '', endMailFactoryDate: '', startMailFactoryDate: ''
       }, // 搜索表单
       refundDepositArr: [
         {
@@ -566,6 +574,10 @@ export default {
       isCollapse: true,
       examineStatusArr: [
         {
+          label: '全部',
+          value: ''
+        },
+        {
           label: '保存',
           value: 'SAVE'
         },
@@ -584,10 +596,21 @@ export default {
         {
           label: '关闭',
           value: 'CLOSE'
+        },
+        {
+          label: '保存(补充资料)',
+          value: 'AMEND'
+        },
+        {
+          label: '待复核',
+          value: 'WAIT_REVIEW'
+        },
+        {
+          label: '复核',
+          value: 'REVIEW'
         }
       ],
       listLoading: false, // 列表加载loading
-      examine: '',
       showSurrender: 0,
       detailId: '',
       selectData: [],
@@ -620,11 +643,11 @@ export default {
     })
   },
   methods: {
-    replenishClick(id){
+    replenishClick(id) {
       this.detailId = id
       this.showSurrender = 2
     },
-    reexamineClick(id){
+    reexamineClick(id) {
       this.detailId = id
       this.showSurrender = 3
     },
@@ -655,7 +678,7 @@ export default {
           // endDeliverTime: "",
           enginOrderNo: '',
           enginOrderType: this.enginOrderType,
-          examineStatus: '',
+          examineStatus: [] || '',
           refEnginRecordNo: '',
           refProjectName: '',
           refUseUnit: '',
@@ -669,8 +692,8 @@ export default {
     // 打开 批量审批
     batchExamine() {
       if (this.selectData.length) {
-      this.submitExamineForm()
-      // this.isShowExamineDialog = true;
+        this.submitExamineForm()
+        // this.isShowExamineDialog = true;
         return
       }
       this.$errorMsg('请选择')
@@ -722,7 +745,7 @@ export default {
           // endDeliverTime: "",
           enginOrderNo: '',
           enginOrderType: this.enginOrderType,
-          examineStatus: '',
+          examineStatus: [] || '',
           refEnginRecordNo: '',
           refProjectName: '',
           refUseUnit: '',
@@ -742,7 +765,7 @@ export default {
         // endDeliverTime: "",
         enginOrderNo: '',
         enginOrderType: this.enginOrderType,
-        examineStatus: '',
+        examineStatus: [] || '',
         refEnginRecordNo: '',
         refProjectName: '',
         refUseUnit: '',
@@ -832,6 +855,9 @@ export default {
     },
     // 切换radio
     changeRadioFn(v) {
+      console.log(v, 888);
+      this.screenForm.examineStatus.pop()
+      this.screenForm.examineStatus[0] = v
       this.examine = v
       this.getDataList({
         pageSize: this.pageSize,
@@ -884,9 +910,10 @@ export default {
         createName: '',
         enginOrderNo: '',
         enginOrderType: this.enginOrderType,
-        examineStatus: this.examine,
         refUseUnit: '',
-        ...this.screenForm
+        ...this.screenForm,
+        examineStatus: this.screenForm.examineStatus.join(',') || '',
+
       })
     },
     // 详情
@@ -897,7 +924,9 @@ export default {
     async getDataList(data) {
       getDepositCountList({
         enginOrderType: this.enginOrderType,
-        ...this.screenForm
+        ...this.screenForm,
+        examineStatus: this.screenForm.examineStatus.join(',') || '',
+
       }).then(res => {
         if (res.data) {
           this.numSum = res.data

+ 1 - 0
src/views/supply/pickup/check.vue

@@ -748,6 +748,7 @@ export default {
         })
       } else {
         this.getDateil(this.tableSelection, 'getDtailPrintDis', this.check).then(res => {
+          this.tableSelection = []
           this.$endLoading()
           this.$refs.preView.show(this.hiprintTemplate, this.outputData)
         })

+ 18 - 8
src/views/supply/pickup/components/pickup_form.vue

@@ -109,8 +109,7 @@
           <el-table-column align="center" type="selection" width="55"></el-table-column>
 
           <template v-if="logisticsNumber === '001' && mainForm.pickupWay == 2">
-            <el-table-column align="left" label="仓库" prop="invoiceId" min-width="160" show-overflow-tooltip
-              v-if="isFront !== null">
+            <el-table-column align="left" label="仓库" prop="invoiceId" min-width="160" show-overflow-tooltip>
               <template v-slot="{ row }">
                 <el-select v-model="row.warehouseFlag" value-key="" placeholder="" :disabled="flag" clearable filterable size="mini"
                   @change="storeChange($event, row)">
@@ -121,35 +120,35 @@
             </el-table-column>
             <el-table-column align="left" label="收货客户" prop="orderTime" min-width="100" show-overflow-tooltip>
               <template slot-scope="scope">
-                <el-input v-if="!(scope.row.orderType === 'TRADE' || scope.row.orderType === 'HOME')" :disabled="flag || (isFront !== null && (scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
+                <el-input v-if="!(scope.row.orderType === 'TRADE' || scope.row.orderType === 'HOME')" :disabled="flag || ((scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
                   v-model="scope.row.receivingName" size="mini"
                   @input="handleInput($event, scope.row.invoiceId, 1)"></el-input>
                 <template v-else>
                   <el-input
-                    :disabled="flag || (isFront !== null && (scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
+                    :disabled="flag || ((scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
                     v-model="scope.row.refLinkman" size="mini"></el-input>
                 </template>
               </template>
             </el-table-column>
             <el-table-column align="left" label="电话" prop="orderTime" min-width="150" show-overflow-tooltip>
               <template slot-scope="scope">
-                <el-input v-if="!(scope.row.orderType === 'TRADE' || scope.row.orderType === 'HOME')" :disabled="flag || (isFront !== null && (scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
+                <el-input v-if="!(scope.row.orderType === 'TRADE' || scope.row.orderType === 'HOME')" :disabled="flag || ((scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
                   v-model="scope.row.phone" size="mini" @input="handleInput($event, scope.row.invoiceId, 2)"></el-input>
                 <template v-else>
                   <el-input
-                    :disabled="flag || (isFront !== null && (scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
+                    :disabled="flag || ((scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
                     v-model="scope.row.refPhone" size="mini"></el-input>
                 </template>
               </template>
             </el-table-column>
             <el-table-column align="left" label="收货地址" prop="orderTime" min-width="200" show-overflow-tooltip>
               <template slot-scope="scope">
-                <el-input v-if="!(scope.row.orderType === 'TRADE' || scope.row.orderType === 'HOME')" :disabled="flag || (isFront !== null && (scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
+                <el-input v-if="!(scope.row.orderType === 'TRADE' || scope.row.orderType === 'HOME')" :disabled="flag || ((scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
                   v-model="scope.row.address" size="mini"
                   @input="handleInput($event, scope.row.invoiceId, 3)"></el-input>
                 <template v-else>
                   <el-input
-                    :disabled="flag || (isFront !== null && (scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
+                    :disabled="flag || ((scope.row.warehouseFlag == 0 || scope.row.warehouseFlag == null))"
                     v-model="scope.row.refInstallAddress" size="mini"></el-input>
                 </template>
               </template>
@@ -631,7 +630,18 @@ export default {
       // let correspondName = this.warehouseList.find(o => o.id == this.mainForm.warehouse).name;
 
       let orderList = []
+     
       this.tableSelection.forEach(item => {
+        if (!(item.orderType === 'TRADE' || item.orderType === 'HOME')) {
+       
+        } else {
+          if ((item.refLinkman && item.refPhone && item.refInstallAddress)) {
+            item.receivingName = item.refLinkman
+            item.phone = item.refPhone
+            item.address = item.refInstallAddress
+          }
+
+        }
         orderList.push({
           warehouseFlag:item.warehouseFlag,
           address: item.address,