From c141b01c990146b4ef41c17a69ad3066d721a91c Mon Sep 17 00:00:00 2001
From: chenhaozhe <cgz@hz-kingdee.com>
Date: 星期四, 05 二月 2026 12:26:20 +0800
Subject: [PATCH] 调整 器具/设备 维修相关模块 页面

---
 pages/MJGL/Sb_EquipRepairCheckBill/Sb_EquipRepairCheckBill.vue |   52 ++++++++++++++++++++++++++++++++++++++++++----------
 1 files changed, 42 insertions(+), 10 deletions(-)

diff --git a/pages/MJGL/Sb_EquipRepairCheckBill/Sb_EquipRepairCheckBill.vue b/pages/MJGL/Sb_EquipRepairCheckBill/Sb_EquipRepairCheckBill.vue
index 99ea259..b153674 100644
--- a/pages/MJGL/Sb_EquipRepairCheckBill/Sb_EquipRepairCheckBill.vue
+++ b/pages/MJGL/Sb_EquipRepairCheckBill/Sb_EquipRepairCheckBill.vue
@@ -231,12 +231,12 @@
                 hform: {
                     "HBillType": '3911',
                     "HBarCode": "",
-                    "HCheckBeginDate": dayjs(new Date()).format("YYYY-MM-DD HH:mm:ss"),
+                    "HCheckBeginDate": dayjs(new Date()).format("YYYY-MM-DD"),
                     "HCheckResult": "OK",
                     "HRepairCheckContent": "",
                     "HBillNo": "",
                     "HInterID": 0,
-                    "HDate": dayjs(new Date()).format("YYYY-MM-DD HH:mm:ss"),
+                    "HDate": dayjs(new Date()).format("YYYY-MM-DD"),
                     "HDeptName": getUserInfo().HDeptName,
                     "HDeptID": getUserInfo().HDeptID,
                     "HEmpName": getUserInfo().HEmpName,
@@ -250,7 +250,7 @@
                     "HBarSpec": "",
                     "HBarModel": "",
                     "HMaker": getUserInfo()["Czymc"],
-                    "HMakeDate": dayjs(new Date()).format("YYYY-MM-DD HH:mm:ss"),
+                    "HMakeDate": dayjs(new Date()).format("YYYY-MM-DD"),
                     "HUpDater": "",
                     "HUpDateDate": "",
                     "HChecker": "",
@@ -567,10 +567,14 @@
             // 鑾峰彇鑱屽憳鏁版嵁
             async getEmpList() {
                 try {
+                    let sWhere=  " where 1=1 "
+                    if(this.hform.HDeptName && uni.getStorageSync("Organization") == '瀹佹尝甯傚崕鑸熷寘瑁呮湁闄愬叕鍙�'){
+                        sWhere += ` and HDeptName = '${this.hform.HDeptName}'`
+                    }
                     let res = await CommonUtils.doRequest2Async({
                         url: '/PublicPageMethod/UserList',
                         data: {
-                            sWhere: " where 1=1",
+                            sWhere: sWhere,
                         }
                     })
 
@@ -705,7 +709,33 @@
                     })
                 }
             },
-            async getSourceBillInfo(HSourceBillType, HInterID, HBillNo) {
+            async getSendWorkBill(HSendWorkID) {
+                try{
+                    let res = await CommonUtils.doRequest2Async({
+                        url: "/Sb_EquipRepairSendWorkBill/GetEquipRepairSendWorkBillList",
+                        data: {
+                            sWhere: ` and hmainid ='${HSendWorkID}' `,
+                            user: getUserInfo()["Czymc"]
+                        }
+                    })
+                    
+                    let {data, count, Message} = res.data
+                    if(count == 1) {
+                        this.hform.HRepairCheckID = this.HRepairCheckList.find(item => data[0]["琛ㄤ綋缁翠慨椤圭洰"] == item["缁翠慨楠屾敹椤圭洰"])?.hitemid
+                    }else {
+                       CommonUtils.showTips({
+                           title: "娓╅Θ鎻愮ず",
+                           message: `鑾峰彇娲惧伐鍗曞け璐�: ${Message}`
+                       }) 
+                    }
+                }catch(err) {
+                    CommonUtils.showTips({
+                        title: "娓╅Θ鎻愮ず",
+                        message: `鑾峰彇娲惧伐鍗曞け璐�: ${err}`
+                    })
+                }
+            },
+            async getSourceBillInfo(HSourceBillType, HInterID, HBillNo, HSendWorkID) {
                 // 涓嬫帹鍗曟嵁绫诲瀷涓鸿澶囨晠闅滅櫥璁板崟
                 if (HSourceBillType == 3907) {
                     let res = await CommonUtils.doRequest2Async({
@@ -730,12 +760,13 @@
                         this.hform.HBarName = data[0].璁惧鍚嶇О
                         this.hform.HBarModel = data[0].璁惧瑙勬牸
                         this.hform.HBarSpec = data[0].璁惧瑙勬牸
-                        
+                        this.HDetailList[0].HRepairCheckContent = data[0].鏁呴殰鎻忚堪
                         this.hform.HMainSourceBillNo = data[0]["璁惧缁翠慨璁板綍鍗�"];
                         this.hform.HMainSourceInterID = data[0]["HEquipRepairCheckBillInterID"];
                         this.hform.HMainSourceEntryID = data[0]["HEquipRepairCheckBillEntryID"];
-                        
-                        
+                        this.hform.HManagerID = data[0]["HManagerID"];
+                        this.hform.HEmpID = data[0]["HEmpID"];
+                        this.getSendWorkBill(HSendWorkID)
                     } else {
                         CommonUtils.showTips({
                             title: '娓╅Θ鎻愮ず',
@@ -830,11 +861,12 @@
                 let {
                     HSourceBillType,
                     HInterID,
-                    HBillNo
+                    HBillNo,
+                    HSendWorkID
                 } = e
                 // 涓嬫帹
                 this.getMaxNum()
-                this.getSourceBillInfo(HSourceBillType, HInterID, HBillNo)
+                this.getSourceBillInfo(HSourceBillType, HInterID, HBillNo, HSendWorkID)
             }
 
             this.getHDeptList()

--
Gitblit v1.9.1