From bb40eba5dd2ec75a6fa2cd2c8eb41d769c092fca Mon Sep 17 00:00:00 2001
From: chenhaozhe <cgz@hz-kingdee.com>
Date: 星期五, 05 十二月 2025 09:33:40 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-VUEUI

---
 src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue |  111 +++++++++++++++++++++++++++++++++----------------------
 1 files changed, 67 insertions(+), 44 deletions(-)

diff --git a/src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue b/src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue
index 3694c0e..c1b4540 100644
--- a/src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue
+++ b/src/views/scMould/warehouse/Sc_MouldProdBackBillList.vue
@@ -25,36 +25,34 @@
       <el-collapse v-model="activeSeach">
         <el-collapse-item title="鏇村" name="1">
           <el-card class="box-card">
-            <el-form-item label="缁勭粐鍚嶇О" prop="HStockOrgName">
-              <el-input v-model="queryParams.HStockOrgName" placeholder="璇疯緭鍏ョ粍缁囧悕绉�" @keyup.enter.native="handleQuery" />
+            <el-form-item label="鐘舵��" prop="HStatus">
+              <el-select v-model="queryParams.HStatus" placeholder="璇烽�夋嫨鐘舵��">
+                <el-option v-for="(item, index) in HStatusList" :key="index" :label="item.name" :value="item.value">
+                </el-option>
+              </el-select>
             </el-form-item>
-            <!-- <el-form-item label="缁勭粐">
-              <el-select v-model="queryParams.HOrgID" placeholder="璇烽�夋嫨">
+            <el-form-item label="缁勭粐">
+              <el-select v-model="queryParams.HStockOrgID" placeholder="璇烽�夋嫨">
                 <el-option v-for="(item, index) in organizationList" :key="index" :label="item.Name" :value="item.ID">
                 </el-option>
               </el-select>
-            </el-form-item> -->
+            </el-form-item>
             <el-form-item label="閮ㄩ棬淇℃伅" prop="HDept">
               <el-input v-model="queryParams.HDept" placeholder="璇疯緭鍏ラ儴闂ㄤ俊鎭�" @keyup.enter.native="handleQuery" />
-            </el-form-item>
-            <el-form-item label="鐗╂枡浠g爜" prop="HMaterNumber">
-              <el-input v-model="queryParams.HMaterNumber" placeholder="璇疯緭鍏ョ墿鏂欎唬鐮�" @keyup.enter.native="handleQuery" />
             </el-form-item>
             <el-form-item label="鍣ㄥ叿浠g爜" prop="HModelNumber">
               <el-input v-model="queryParams.HModelNumber" placeholder="璇疯緭鍏ュ櫒鍏蜂唬鐮�" @keyup.enter.native="handleQuery" />
             </el-form-item>
-            <el-form-item label="浠撳簱" prop="HWhName">
-              <el-input v-model="queryParams.HWhName" placeholder="璇疯緭鍏ヤ粨搴�" @keyup.enter.native="handleQuery" />
-            </el-form-item>
             <el-form-item label="寰�鏉ュ崟浣�" prop="HSupName">
               <el-input v-model="queryParams.HSupName" placeholder="璇疯緭鍏ュ線鏉ュ崟浣�" @keyup.enter.native="handleQuery" />
             </el-form-item>
-            <div slot="header" class="clearfix"><span>杩囨护</span></div>
+            <div slot="header" class="clearfix"><span>鍏朵粬鏉′欢</span></div>
             <div>
               <el-row>
                 <el-form-item label-width="0">
                   <el-row>
-                    <el-col :span="7">
+                    <el-col :span="2"><span>杩囨护</span></el-col>
+                    <el-col :span="6">
                       <el-select v-model="queryParams.ColName1" placeholder="璇烽�夋嫨" @change="riqiChange">
                         <span v-for="(item, index) in btList" :key="index">
                           <el-option :label="item.field" :value="item.field" v-if="!item.hide"></el-option>
@@ -67,7 +65,7 @@
                           :value="item.value"></el-option>
                       </el-select>
                     </el-col>
-                    <el-col :span="11">
+                    <el-col :span="10">
                       <el-input v-model="queryParams.ColContent1" placeholder="璇疯緭鍏�" clearable
                         @keyup.enter.native="handleQuery" />
                     </el-col>
@@ -77,7 +75,8 @@
               <el-row>
                 <el-form-item label-width="0">
                   <el-row>
-                    <el-col :span="7">
+                    <el-col :span="2"><span>杩囨护</span></el-col>
+                    <el-col :span="6">
                       <el-select v-model="queryParams.ColName2" placeholder="璇烽�夋嫨" @change="riqiChange">
                         <span v-for="(item, index) in btList" :key="index">
                           <el-option :label="item.field" :value="item.field" v-if="!item.hide"></el-option>
@@ -90,7 +89,7 @@
                           :value="item.value"></el-option>
                       </el-select>
                     </el-col>
-                    <el-col :span="11">
+                    <el-col :span="10">
                       <el-input v-model="queryParams.ColContent2" placeholder="璇疯緭鍏�" clearable
                         @keyup.enter.native="handleQuery" />
                     </el-col>
@@ -99,7 +98,8 @@
               </el-row>
               <el-form-item label-width="0">
                 <el-row>
-                  <el-col :span="7">
+                  <el-col :span="2"><span>杩囨护</span></el-col>
+                  <el-col :span="6">
                     <el-select v-model="queryParams.ColName" placeholder="璇烽�夋嫨" @change="riqiChange">
                       <el-option v-for="(item, index) in btList" :key="index" :label="item.field"
                         :value="item.field"></el-option>
@@ -111,7 +111,7 @@
                         :value="item.value"></el-option>
                     </el-select>
                   </el-col>
-                  <el-col :span="11">
+                  <el-col :span="10">
                     <el-input v-model="queryParams.ColContent" placeholder="璇疯緭鍏�" clearable
                       @keyup.enter.native="handleQuery" />
                   </el-col>
@@ -253,7 +253,7 @@
         { label: '杩戜竴骞�', value: 365 },
       ],
       organizationList: JSON.parse(sessionStorage.getItem('organizationList')),//缁勭粐鍒楄〃
-      hPriceTypeList: ['鎴愭湰浠�', '缁撶畻浠�'],
+      HStatusList: [{name:'鍏ㄩ儴',value:'-1'},{name:'鏈鏍�',value:'0'},{name:'宸插鏍�',value:'1'},{name:'宸插叧闂�',value:'2'}],
       addBtnShow: false,
       dialogTitle: '',
       OperationType: null,//淇濆瓨绫诲瀷锛堟柊澧�1淇敼3锛�
@@ -271,11 +271,10 @@
       queryParams: {
         HBillNo: '',
         HInitTimeCycle: 29,
-        HStockOrgName: '',
+        HStockOrgID: sessionStorage["OrganizationID"] - 0,
+        HStatus:'-1',
         HDept:'',
-        HMaterNumber: '',
         HModelNumber:'',
-        HWhName:'',
         HSupName:'',
         ColName1: '',
         ColName2: '',
@@ -374,20 +373,24 @@
       this.tableShow = false
       this.loading = true
       if (this.sTime && !this.sWhere) {
-        this.sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + this.sTime + "'"
-        this.sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + this.eTime + "'"
+        this.sTime = moment(this.sTime).format('YYYY-MM-DD')
+        this.eTime = moment(this.eTime).format('YYYY-MM-DD')
+        this.sWhere += " and 鏃ユ湡 >= '" + this.sTime + "'";
+        this.sWhere += " and 鏃ユ湡 <= '" + this.eTime + "'";
       }
+      this.sWhere += " and HSTOCKORGID=" + this.queryParams.HStockOrgID
       if (this.pageSize == 0) {
         this.pageSize = 50
       }
       // 閿�鍞嚭搴撳崟鍒楄〃
-      axios.get(this.baseURL + '/Sc_MouldProdBackBill/list_byPage', {
+      axios.get(this.baseURL + '/Sc_MouldProdBackBillController/page', {
         params: {
           "sWhere": this.sWhere,
           "user": sessionStorage["HUserName"],
           "Organization": sessionStorage["Organization"],
           "page": this.page,
-          "size": this.pageSize
+          "size": this.pageSize,
+          "Type": '3803'
         },
       }).then(response => {
         this.tyResList = response.data.data//鎬绘暟鎹�
@@ -583,7 +586,7 @@
     //鍙屽嚮琛�
     handleDblclick(row, column, cell, event) {
       this.OperationType = 3
-      this.handleEdit()
+      this.handleEdit(row)
     },
     // 澶氶�夋閫変腑鏁版嵁
     handleSelectionChange(selection) {
@@ -661,34 +664,43 @@
         }
         this.sWhere += " and " + this.queryParams.ColName2 + " " + com2;
       }
+      if (this.queryParams.HStatus) {
+          switch (this.queryParams.HStatus) {
+              case '-1':   //鍏ㄩ儴
+                  this.sWhere += "";
+                  break;
+              case '0':    //鏈鏍�
+                  this.sWhere += " and 瀹℃牳浜�=''";
+                  break;
+              case '1':    //宸插鏍�
+                  this.sWhere += " and 瀹℃牳浜�<>''";
+                  break;
+              case '2':    //宸插叧闂�
+                  this.sWhere += " and 鍏抽棴浜�<>''";
+              default:
+          }
+      }
       if (this.sTime) {
         this.sTime = moment(this.sTime).format('YYYY-MM-DD')
-        this.eTime = moment(this.eTime).format('YYYY-MM-DD')
-        console.log(this.sTime, this.eTime)
-        this.sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + this.sTime + "'" + " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + this.eTime + "'";
+        this.sWhere += " and 鏃ユ湡 >= '" + this.sTime + "'";
       }
-      
+      if (this.eTime) {
+        this.eTime = moment(this.eTime).format('YYYY-MM-DD')
+        this.sWhere += " and 鏃ユ湡 <= '" + this.eTime + "'";
+      }
       if (this.queryParams.HBillNo) {
         this.sWhere += " and 鍗曟嵁鍙� like '%" + this.queryParams.HBillNo + "%'";
-      }
-      if (this.queryParams.HStockOrgName) {
-        this.sWhere += " and 缁勭粐鍚嶇О like '%" + this.queryParams.HStockOrgName + "%'";
       }
       if (this.queryParams.HDept) {
           this.sWhere += " and 閮ㄩ棬 like '%" + this.queryParams.HDept + "%'";
       }
-      if (this.queryParams.HMaterNumber) {
-          this.sWhere += " and 鐗╂枡浠g爜 like '%" + this.queryParams.HMaterNumber + "%'";
-      }
       if (this.queryParams.HModelNumber) {
-          this.sWhere += " and 妯″叿浠g爜 like '%" + this.queryParams.HModelNumber + "%'";
-      }
-      if (this.queryParams.HWhName) {
-          this.sWhere += " and 浠撳簱 like '%" + this.queryParams.HWhName + "%'";
+          this.sWhere += " and 鍣ㄥ叿浠g爜 like '%" + this.queryParams.HModelNumber + "%'";
       }
       if (this.queryParams.HSupName) {
           this.sWhere += " and 寰�鏉ュ崟浣� like '%" + this.queryParams.HSupName + "%'";
       }
+      this.clearData()
       this.getList()
     },
     /** 閲嶇疆鎸夐挳鎿嶄綔 */
@@ -697,11 +709,10 @@
       this.queryParams = {
         HBillNo: '',
         HInitTimeCycle: 29,
-        HStockOrgName: '',
+        HStockOrgID: sessionStorage["OrganizationID"] - 0,
+        HStatus:'-1',
         HDept:'',
-        HMaterNumber: '',
         HModelNumber:'',
-        HWhName:'',
         HSupName:'',
         ColName1: '',
         ColName2: '',
@@ -715,6 +726,7 @@
       }
       this.riqiChange()
       this.resetForm("queryForm")
+      this.clearData()
       this.getList()
     },
 
@@ -724,6 +736,7 @@
       this.tableShow = true
       this.openEdit = false
       this.editShow = false
+      this.clearData()
       this.getList()
     },
     //鎵撳紑鏂板缁勪欢寮圭獥
@@ -743,7 +756,16 @@
       this.open = val
       this.editShow = false
       this.openEdit = val
+      this.clearData()
       this.getList()
+    },
+    //娓呴櫎閫変腑鏁版嵁鐨勭紦瀛�
+    clearData(){
+      this.ids = []
+      this.multiple = true
+      this.single = true      
+      this.OperationType = 0
+      this.copyType = 0
     },
     /** 鍒犻櫎鎸夐挳鎿嶄綔 */
     handleDelete() {
@@ -772,6 +794,7 @@
         let result = response.data
         if (result.count == 1) {
           this.$modal.msgSuccess('鎿嶄綔鎴愬姛');
+          this.clearData()
           this.getList();
         }
         else {

--
Gitblit v1.9.1