qq_41295110
2026-02-26 423c1948a631cff298e6348cc55626f5149c111a
pages/MJGL/Sb_EquipConkBook/Sb_EquipConkBookBill.vue
@@ -78,7 +78,7 @@
                    <!-- <input disabled v-model="hform.HDeptName" placeholder="请选择部门" /> -->
                </view>
                <view class="form-item">
                    <view class="title required">负责人:</view>
                    <view class="title required">验收人:</view>
                    <zxz-uni-data-select required class="right" :localdata="HEmpList" dataKey="HName"
                        dataValue="HItemID" v-model="hform.HManagerID">
@@ -207,7 +207,7 @@
                hform: {
                    HBarCode: "",
                    HConkBeginDate: dayjs(new Date()).format("YYYY-MM-DD HH:mm:ss"),
                    HConkBeginDate: dayjs(new Date()).format("YYYY-MM-DD"),
                    HConkTypeName: "",
                    HConkTypeID: 0,
                    HConkReasonName: "",
@@ -215,13 +215,13 @@
                    HExplanation: "",
                    HBillNo: "",
                    HInterID: 0,
                    HDate: dayjs(new Date()).format("YYYY-MM-DD HH:mm:ss"),
                    HDeptName: "",
                    HDeptID: 0,
                    HEmpName: "",
                    HEmpID: 0,
                    HManagerName: "",
                    HManagerID: 0,
                    HDate: dayjs(new Date()).format("YYYY-MM-DD"),
                    HDeptName: getUserInfo().HDeptName,
                    HDeptID: getUserInfo().HDeptID,
                    HEmpName: getUserInfo().HEmpName,
                    HEmpID: getUserInfo().HEmpID,
                    HManagerName: getUserInfo().HManagerName,
                    HManagerID: getUserInfo().HManagerID,
                    HBarName: "",
                    HEquipID: 0,
                    HBarSpec: "",
@@ -230,7 +230,7 @@
                    HChecker: '',
                    HCloseMan: '',
                    HUpDater: '',
                    HMakeDate: dayjs(new Date()).format("YYYY-MM-DD HH:mm:ss"),
                    HMakeDate: dayjs(new Date()).format("YYYY-MM-DD"),
                    HCheckDate: '',
                    HCloseDate: '',
                    HUpDateDate: '',
@@ -261,10 +261,11 @@
            async getConkType() {
                try {
                    let res = await CommonUtils.doRequest2Async({
                        url: "/Gy_ConkType/List_PDA",
                        url: '/Gy_ConkType/List_PDA2',
                        data: {
                            sWhere: ``,
                            user: getUserInfo()['Czymc']
                            sWhere: '',
                            user: getUserInfo()['Czymc'],
                            mode: 'Equip'
                        }
                    })
@@ -344,7 +345,7 @@
                }
                if (this.hform.HManagerID == 0) {
                    return {
                        Message: "负责人不得为空!",
                        Message: "验收人不得为空!",
                        state: false
                    }
                }
@@ -500,10 +501,15 @@
            // 获取职员数据
            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,
                        }
                    })
@@ -530,7 +536,7 @@
            toScanCode() {
                MpaasScan.scanCode(cb => {
                    this.hfrom.HBarCode = cb
                    this.hform.HBarCode = cb
                    this.GetMessageByBarCode(cb)
                })
            },
@@ -752,7 +758,7 @@
                    if (code == 1) {
                        data = data.h_v_Sb_EquipConkBookBillList_Edit[0]
                        this.enableEdit = false
                    } else {
                        CommonUtils.showTips({
@@ -765,6 +771,46 @@
                    CommonUtils.showTips({
                        title: '温馨提示',
                        message: `获取故障登记单失败: ${err}`
                    })
                }
            },
            async GetEquipInfo(HEquipID) {
                try {
                    let res = await CommonUtils.doRequest2Async({
                        url: "/Gy_EquipFileMain/getSb_EquipList",
                        data: {
                            HInterID: HEquipID,
                            user: getUserInfo()["Czymc"]
                        }
                    })
                    let {
                        data,
                        Message,
                        count
                    } = res.data
                    if (count == 1) {
                        console.log('data: ', data);
                        Object.assign(this.hform, {
                            HDeptID: data[0]["HDeptID"],
                            HDeptName: data[0]["使用部门"],
                            HEquipID: data[0]["hmainid"],
                            HBarName: data[0]["设备名称"],
                            HBarModel: data[0]["设备规格"],
                            HBarSpec: data[0]["设备型号"],
                            HEmpID: getUserInfo()["HEmpID"],
                            HManagerID: data[0]["HRepairEmpID"]
                        })
                    } else {
                        CommonUtils.showTips({
                            title: "温馨提示",
                            message: `获取设备数据失败: ${Message}`
                        })
                    }
                } catch (err) {
                    CommonUtils.showTips({
                        title: "温馨提示",
                        message: `获取设备数据失败: ${err}`
                    })
                }
            }
@@ -788,7 +834,10 @@
                this.getEditData(hmainid)
            } else if (this.operationType == 4) {
                // 浏览
                // 报工平台下推
                let HEquipID = e.HEquipID
                this.getMaxNum()
                this.GetEquipInfo(HEquipID)
            }