From 96973dca40a1815e9727160e6b2e6dee839b9f8d Mon Sep 17 00:00:00 2001
From: wtt <1985833171@qq.com>
Date: 星期三, 31 十二月 2025 13:06:14 +0800
Subject: [PATCH] 质量模具模块页面优化
---
pages/ZLGL/chuchangjiaoyandan/QC_OutCompCheckBill.vue | 3
pages/ZLGL/shengchanrukujiaoyan/QC_LastPieceCheckBill_v2.vue | 6
pages/ZLGL/mojianjianyan/lastPieceCheckBill.vue | 68 ++++++++
utils/auth.js | 2
components/ZLGL/CheckProjectPopup.vue | 14
pages/ZLGL/QualityReportStep/QualityReportStepBill.vue | 6
pages/MJGL/mujulingliaotuikudan/Sc_MouldProdBackBill.vue | 6
pages/index/tab4.vue | 2
pages/ZLGL/lailiaojianyan/POStockInCheckBill.vue | 6
pages/mujvzhuangtai/mujvzhuangtai.vue | 138 ++++++++---------
pages/MJGL/mujulingliaochukudan/MouldProdOutBill.vue | 8
components/BillListPopup/BillListPopup.vue | 23 ++
pages/ZLGL/shoujianjianyan/firstCheckBill.vue | 70 ++++++++
pages/index/mine.vue | 87 ++++++++++
pages/qijvguzhangdengji/mouldMistakeBill.vue | 7
15 files changed, 340 insertions(+), 106 deletions(-)
diff --git a/components/BillListPopup/BillListPopup.vue b/components/BillListPopup/BillListPopup.vue
index ae4c641..5855496 100644
--- a/components/BillListPopup/BillListPopup.vue
+++ b/components/BillListPopup/BillListPopup.vue
@@ -10,6 +10,11 @@
<view class="title"><text>鐗╂枡: </text></view>
<view class="right"><input type="text" :focus="enablefocus" v-model="HMater"
@confirm="getBillList" /></view>
+ <view class="icon-wrapper-big">
+ <uni-icons class="right-icon"
+ :class="'enable-icon-button'"
+ type="scan" size="20" @click="toScanCode"></uni-icons>
+ </view>
</view>
<view class="search-condition">
<view class="title"><text>鍏宠仈椤�: </text></view>
@@ -71,6 +76,9 @@
CommonUtils
} from '../../utils/common';
import dayjs from 'dayjs';
+ import {
+ MpaasScan
+ } from "../../utils/mpaasScan";
export default {
name: "BillListPopup",
data() {
@@ -115,6 +123,15 @@
event: 'change'
},
methods: {
+ //鎵爜
+ toScanCode() {
+ MpaasScan.scanCode((res) => {
+ if (res) {
+ this.HMater = res;
+ this.getBillList();
+ }
+ });
+ },
popupChangeHandler(e) {
if (e.show === true) {
this.getBillList()
@@ -347,4 +364,10 @@
background-color: rgba(0, 122, 255, 0.2);
}
}
+ .enable-icon-button {
+ background-color: #3a78ff;
+ padding: 6rpx;
+ color: #fff;
+ border-radius: 100%;
+ }
</style>
\ No newline at end of file
diff --git a/components/ZLGL/CheckProjectPopup.vue b/components/ZLGL/CheckProjectPopup.vue
index 0fb9d35..2192288 100644
--- a/components/ZLGL/CheckProjectPopup.vue
+++ b/components/ZLGL/CheckProjectPopup.vue
@@ -5,7 +5,7 @@
<view class="search-condition">
<view class="title"><text>鏃ユ湡: </text></view>
<view class="daterange" style="flex: 1;">
- <view class="right general">
+ <!-- <view class="right general">
<uni-datetime-picker type="date" :clear-icon="false" v-model="HBeginDate">
<view>{{HBeginDate}}</view>
</uni-datetime-picker>
@@ -15,7 +15,7 @@
<uni-datetime-picker type="date" :clear-icon="false" v-model="HEndDate">
<view>{{HEndDate}}</view>
</uni-datetime-picker>
- </view>
+ </view> -->
</view>
</view>
<view class="buttons">
@@ -109,8 +109,8 @@
panelHeight: 0,
HProcessName: '',
HMaterName: '',
- HBeginDate: dayjs(new Date()).subtract(30, 'd').format("YYYY-MM-DD"),
- HEndDate: dayjs(new Date()).format("YYYY-MM-DD"),
+ // HBeginDate: dayjs(new Date()).subtract(30, 'd').format("YYYY-MM-DD"),
+ // HEndDate: dayjs(new Date()).format("YYYY-MM-DD"),
multiSouceBillList: []
};
},
@@ -161,9 +161,9 @@
getsWhere() {
let sWhere =
` and ISNULL(瀹℃牳浜�,'')!='' and HOrgID = '${ uni.getStorageSync("OrganizationID")}'`
- if (this.HBeginDate && this.HEndDate) {
- sWhere += ` and CONVERT(varchar(100),鏃ユ湡, 23) between '${this.HBeginDate}' and '${this.HEndDate}'`
- }
+ // if (this.HBeginDate && this.HEndDate) {
+ // sWhere += ` and CONVERT(varchar(100),鏃ユ湡, 23) between '${this.HBeginDate}' and '${this.HEndDate}'`
+ // }
if (this.HMaterName && this.HProcessName) {
sWhere += ` and 鐗╂枡鍚嶇О = '${this.HMaterName}' and 宸ュ簭鍚嶇О = '${this.HProcessName}'`
diff --git a/pages/MJGL/mujulingliaochukudan/MouldProdOutBill.vue b/pages/MJGL/mujulingliaochukudan/MouldProdOutBill.vue
index bcfae5f..db2e66c 100644
--- a/pages/MJGL/mujulingliaochukudan/MouldProdOutBill.vue
+++ b/pages/MJGL/mujulingliaochukudan/MouldProdOutBill.vue
@@ -94,7 +94,7 @@
<view class="form-item">
<view class="title">婧愬崟绫诲瀷:</view>
<view class="right" v-show="showHMainSourceBillType">
- <picker :range="arrayHMainSourceBillType" v-model="HMainSourceBillType"
+ <picker :range="arrayHMainSourceBillType"
@change="HMainSourceBillTypeChange">
<input name="HMainSourceBillType" disabled v-model="HMainSourceBillType"
placeholder="璇烽�夋嫨婧愬崟绫诲瀷" />
@@ -232,12 +232,12 @@
HBarCode: '',
HInterID: '',
HBillType: 3802,
- HWHName: getUserInfo().HWHName,
+ HWHName: getUserInfo().HWhName,
HWHID: getUserInfo().HWhID,
HStockPlaceName: getUserInfo().HSPName,
HStockPlaceID: getUserInfo().HSPID,
- HKeeperName: getUserInfo().User,
- HKeeperID: getUserInfo().User,//鍙戞枡浜�
+ HKeeperName: getUserInfo().HKeeperName,
+ HKeeperID: getUserInfo().HKeeperID,//鍙戞枡浜�
HSecManagerName: getUserInfo().HEmpName,
HSecManagerID: getUserInfo().HEmpID,//棰嗘枡浜�
HDeptName: getUserInfo().HDept,
diff --git a/pages/MJGL/mujulingliaotuikudan/Sc_MouldProdBackBill.vue b/pages/MJGL/mujulingliaotuikudan/Sc_MouldProdBackBill.vue
index 6ab3387..ae4969a 100644
--- a/pages/MJGL/mujulingliaotuikudan/Sc_MouldProdBackBill.vue
+++ b/pages/MJGL/mujulingliaotuikudan/Sc_MouldProdBackBill.vue
@@ -273,7 +273,7 @@
HBarCode: '',
HInterID: '',
HBillType: 3803,
- HWHName: getUserInfo().HWHName,
+ HWHName: getUserInfo().HWhName,
HWHID: getUserInfo().HWhID,
HStockPlaceName: getUserInfo().HSPName,
HStockPlaceID: getUserInfo().HSPID,
@@ -282,8 +282,8 @@
HDeptID: getUserInfo().HDeptID,
HSecManagerID: getUserInfo().HEmpID,
HSecManagerName: getUserInfo().HEmpName,
- HKeeperID: 0,
- HKeeperName: '',
+ HKeeperName: getUserInfo().HKeeperName,
+ HKeeperID: getUserInfo().HKeeperID,//鍙戞枡浜�
//婧愬崟淇℃伅
HMainSourceBillType: uni.getStorageSync('billType_3803') ? uni.getStorageSync('billType_3803') :
3849,
diff --git a/pages/ZLGL/QualityReportStep/QualityReportStepBill.vue b/pages/ZLGL/QualityReportStep/QualityReportStepBill.vue
index 0e9f667..3df60d0 100644
--- a/pages/ZLGL/QualityReportStep/QualityReportStepBill.vue
+++ b/pages/ZLGL/QualityReportStep/QualityReportStepBill.vue
@@ -511,7 +511,8 @@
HBarCode: HBarCode,
HInterID: 0,
HEntryID: 0,
- Mode: 1 //鎵爜妯″紡
+ Mode: 1 ,//鎵爜妯″紡
+ user:getUserInfo()["Czymc"]
}
})
@@ -571,7 +572,8 @@
HBarCode: "",
HInterID: e?.HInterID,
HEntryID: e?.HEntryID,
- Mode: 2 //閫夊崟妯″紡
+ Mode: 2 ,//閫夊崟妯″紡
+ user:getUserInfo()["Czymc"]
}
})
diff --git a/pages/ZLGL/chuchangjiaoyandan/QC_OutCompCheckBill.vue b/pages/ZLGL/chuchangjiaoyandan/QC_OutCompCheckBill.vue
index f4b7b7a..d222463 100644
--- a/pages/ZLGL/chuchangjiaoyandan/QC_OutCompCheckBill.vue
+++ b/pages/ZLGL/chuchangjiaoyandan/QC_OutCompCheckBill.vue
@@ -775,7 +775,8 @@
HBarCode: "",
HInterID: e?.HInterID,
HEntryID: e?.HEntryID,
- Mode: 2 //閫夊崟妯″紡
+ Mode: 2 ,//閫夊崟妯″紡
+ user:getUserInfo()["Czymc"]
}
})
diff --git a/pages/ZLGL/lailiaojianyan/POStockInCheckBill.vue b/pages/ZLGL/lailiaojianyan/POStockInCheckBill.vue
index 20c744b..512fb27 100644
--- a/pages/ZLGL/lailiaojianyan/POStockInCheckBill.vue
+++ b/pages/ZLGL/lailiaojianyan/POStockInCheckBill.vue
@@ -769,7 +769,8 @@
HBarCode: "",
HInterID: e?.HInterID,
HEntryID: e?.HEntryID,
- Mode: 2 //閫夊崟妯″紡
+ Mode: 2 ,//閫夊崟妯″紡
+ user:getUserInfo()["Czymc"]
}
})
@@ -868,7 +869,8 @@
HBarCode: HBarCode,
HInterID: 0,
HEntryID: 0,
- Mode: 1 //鎵爜妯″紡
+ Mode: 1 ,//鎵爜妯″紡
+ user:getUserInfo()["Czymc"]
}
})
diff --git a/pages/ZLGL/mojianjianyan/lastPieceCheckBill.vue b/pages/ZLGL/mojianjianyan/lastPieceCheckBill.vue
index 7b428ee..212e1c0 100644
--- a/pages/ZLGL/mojianjianyan/lastPieceCheckBill.vue
+++ b/pages/ZLGL/mojianjianyan/lastPieceCheckBill.vue
@@ -696,7 +696,8 @@
HBarCode: HBarCode,
HInterID: 0,
HEntryID: 0,
- Mode: 1 //鎵爜妯″紡
+ Mode: 1, //鎵爜妯″紡
+ user:getUserInfo()["Czymc"]
}
})
@@ -709,7 +710,7 @@
if (count == 1) {
this.hform.HMaterID = data[0]['HMaterID']
this.hform.HMaterName = data[0]['浜у搧鍚嶇О']
- this.hform.HMaterNumber = data[0]['HMaterNumber']
+ this.hform.HMaterNumber = data[0]['浜у搧浠g爜']
this.hform.HMainSourceBillNo = data[0]['HBillNo']
this.hform.HSourceBillNo = data[0]['HBillNo']
this.hform.HMainSourceInterID = data[0].HInterID
@@ -739,6 +740,69 @@
})
}
},
+ async HandleBillSelectComplete(e) {
+ try {
+ let res = await CommonUtils.doRequest2Async({
+ url: "/WEBSController/get_CheckBillBarCode_Json_CheckItem",
+ data: {
+ HBillType: this.hform.HBillType,
+ HSourceBillType: this.hform.HSourceBillType,
+ HBarCode: "",
+ HInterID: e?.HInterID,
+ HEntryID: e?.HEntryID,
+ Mode: 2 ,//閫夊崟妯″紡
+ user:getUserInfo()["Czymc"]
+ }
+ })
+
+ let {
+ data,
+ Message,
+ count
+ } = res.data
+ if (count == 1) {
+ console.log('鑾峰彇婧愬崟锛�', data)
+ this.hform.HMaterID = data[0]['HMaterID']
+ this.hform.HMaterName = data[0]['浜у搧鍚嶇О']
+ this.hform.HMaterNumber = data[0]['浜у搧浠g爜']
+ this.hform.HMainSourceBillNo = data[0]['HBillNo']
+ this.hform.HSourceBillNo = data[0]['HBillNo']
+ this.hform.HMainSourceInterID = data[0].HInterID
+ this.hform.HMainSourceEntryID = data[0].HEntryID
+ this.hform.HQCSchemeName = data[0].妫�楠屾柟妗堝悕绉�
+ this.hform.HQCSchemeID = data[0].妫�楠屾柟妗圛D
+ this.hform.HSourceBillQty = data[0].HSourceBillQty
+ this.hform.HICMOBillNo= data[0].浠诲姟鍗曞彿
+ this.hform.HICMOInterID= data[0].HICMOInterID
+ this.hform.HICMOEntryID= data[0].HICMOEntryID
+ this.hform.HICMOQty= data[0].鐢熶骇鏁伴噺
+ this.hform.HProcExchBillNo= data[0].鍗曟嵁鍙�
+ this.hform.HProcExchInterID= data[0].HInterID
+ this.hform.HProcExchEntryID= data[0].HEntryID
+ this.hform.HProcExchQty= data[0].娴佽浆鍗℃暟閲�
+ this.hform.HSourceName= data[0].鐢熶骇璧勬簮
+ this.hform.HSourceID= data[0].HSourceID
+ this.hform.HProcID= data[0].HProcID
+ this.hform.HProcName= data[0].褰撳墠宸ュ簭
+
+ this.get_CheckItem();
+ this.hasSourceBill = true
+ this.$refs['billList'].exit()
+ } else {
+ CommonUtils.showTips({
+ title: '娓╅Θ鎻愮ず',
+ message: Message
+ })
+ }
+
+ } catch (err) {
+ CommonUtils.showTips({
+ title: '娓╅Θ鎻愮ず',
+ message: "婧愬崟涓嬫帹閿欒: " + err
+ })
+ }
+
+ },
async GetCheckItemID() {
if (!this.hform.HMaterName && !this.hform.HProcName) {
try {
diff --git a/pages/ZLGL/shengchanrukujiaoyan/QC_LastPieceCheckBill_v2.vue b/pages/ZLGL/shengchanrukujiaoyan/QC_LastPieceCheckBill_v2.vue
index 5551ec4..dfef792 100644
--- a/pages/ZLGL/shengchanrukujiaoyan/QC_LastPieceCheckBill_v2.vue
+++ b/pages/ZLGL/shengchanrukujiaoyan/QC_LastPieceCheckBill_v2.vue
@@ -782,7 +782,8 @@
HBarCode: "",
HInterID: e?.HInterID,
HEntryID: e?.HEntryID,
- Mode: 2 //閫夊崟妯″紡
+ Mode: 2 ,//閫夊崟妯″紡
+ user:getUserInfo()["Czymc"]
}
})
@@ -880,7 +881,8 @@
HBarCode: HBarCode,
HInterID: 0,
HEntryID: 0,
- Mode: 1 //鎵爜妯″紡
+ Mode: 1, //鎵爜妯″紡
+ user:getUserInfo()["Czymc"]
}
})
diff --git a/pages/ZLGL/shoujianjianyan/firstCheckBill.vue b/pages/ZLGL/shoujianjianyan/firstCheckBill.vue
index d507198..4509b14 100644
--- a/pages/ZLGL/shoujianjianyan/firstCheckBill.vue
+++ b/pages/ZLGL/shoujianjianyan/firstCheckBill.vue
@@ -705,7 +705,7 @@
toScanCode() {
MpaasScan.scanCode((res) => {
if (res) {
- this.getSourceBillInfo(HBarCode);
+ this.getSourceBillInfo(res);
}
});
},
@@ -719,7 +719,8 @@
HBarCode: HBarCode,
HInterID: 0,
HEntryID: 0,
- Mode: 1 //鎵爜妯″紡
+ Mode: 1, //鎵爜妯″紡
+ user:getUserInfo()["Czymc"]
}
})
@@ -732,7 +733,7 @@
if (count == 1) {
this.hform.HMaterID = data[0]['HMaterID']
this.hform.HMaterName = data[0]['浜у搧鍚嶇О']
- this.hform.HMaterNumber = data[0]['HMaterNumber']
+ this.hform.HMaterNumber = data[0]['浜у搧浠g爜']
this.hform.HMainSourceBillNo = data[0]['HBillNo']
this.hform.HSourceBillNo = data[0]['HBillNo']
this.hform.HMainSourceInterID = data[0].HInterID
@@ -772,6 +773,69 @@
// }
},
+ async HandleBillSelectComplete(e) {
+ try {
+ let res = await CommonUtils.doRequest2Async({
+ url: "/WEBSController/get_CheckBillBarCode_Json_CheckItem",
+ data: {
+ HBillType: this.hform.HBillType,
+ HSourceBillType: this.hform.HSourceBillType,
+ HBarCode: "",
+ HInterID: e?.HInterID,
+ HEntryID: e?.HEntryID,
+ Mode: 2 ,//閫夊崟妯″紡
+ user:getUserInfo()["Czymc"]
+ }
+ })
+
+ let {
+ data,
+ Message,
+ count
+ } = res.data
+ if (count == 1) {
+ console.log('鑾峰彇婧愬崟锛�', data)
+ this.hform.HMaterID = data[0]['HMaterID']
+ this.hform.HMaterName = data[0]['浜у搧鍚嶇О']
+ this.hform.HMaterNumber = data[0]['浜у搧浠g爜']
+ this.hform.HMainSourceBillNo = data[0]['HBillNo']
+ this.hform.HSourceBillNo = data[0]['HBillNo']
+ this.hform.HMainSourceInterID = data[0].HInterID
+ this.hform.HMainSourceEntryID = data[0].HEntryID
+ this.hform.HQCSchemeName = data[0].妫�楠屾柟妗堝悕绉�
+ this.hform.HQCSchemeID = data[0].妫�楠屾柟妗圛D
+ this.hform.HSourceBillQty = data[0].HSourceBillQty
+ this.hform.HICMOBillNo= data[0].浠诲姟鍗曞彿
+ this.hform.HICMOInterID= data[0].HICMOInterID
+ this.hform.HICMOEntryID= data[0].HICMOEntryID
+ this.hform.HICMOQty= data[0].鐢熶骇鏁伴噺
+ this.hform.HProcExchBillNo= data[0].鍗曟嵁鍙�
+ this.hform.HProcExchInterID= data[0].HInterID
+ this.hform.HProcExchEntryID= data[0].HEntryID
+ this.hform.HProcExchQty= data[0].娴佽浆鍗℃暟閲�
+ this.hform.HSourceName= data[0].鐢熶骇璧勬簮
+ this.hform.HSourceID= data[0].HSourceID
+ this.hform.HProcID= data[0].HProcID
+ this.hform.HProcName= data[0].褰撳墠宸ュ簭
+
+ this.get_CheckItem();
+ this.hasSourceBill = true
+ this.$refs['billList'].exit()
+ } else {
+ CommonUtils.showTips({
+ title: '娓╅Θ鎻愮ず',
+ message: Message
+ })
+ }
+
+ } catch (err) {
+ CommonUtils.showTips({
+ title: '娓╅Θ鎻愮ず',
+ message: "婧愬崟涓嬫帹閿欒: " + err
+ })
+ }
+
+ },
async GetCheckItemID() {
if (!this.hform.HMaterName && !this.hform.HProcName) {
try {
diff --git a/pages/index/mine.vue b/pages/index/mine.vue
index 1cb0c33..ff8cc08 100644
--- a/pages/index/mine.vue
+++ b/pages/index/mine.vue
@@ -27,12 +27,16 @@
<script>
import { getUserInfo } from "@/utils/auth.js";
+ import {
+ CommonUtils
+ } from '@/utils/common'
export default {
data() {
return {
userInfo:getUserInfo(),
serverUrl: uni.getStorageSync('serverUrl')||'http://47.96.97.237/API',
vers:uni.getStorageSync('vers'),
+ checkCount:0,
itemData:[{
img:'../../static/icon00.png',
text:'寰呮垜瀹℃牳',
@@ -69,8 +73,11 @@
]
}
},
- onLoad() {
+ async onLoad() {
console.log(this.userInfo)
+ await this.cmdSearchFirst()
+ await this.cmdSearchLast()
+ this.itemData[0].text = `寰呮垜瀹℃牳(${this.checkCount})`
},
methods: {
toUrl(item){
@@ -100,8 +107,84 @@
}
}
});
+ },
+ //鑾峰彇寰呭鎵规�绘暟棣栦欢
+ async cmdSearchFirst() {
+
+ try {
+ let res = await CommonUtils.doRequest2Sync({
+ url: '/LEMS/CheckFlowList',
+ data: {
+ "sWhere": ' ',
+ "billType":8505,
+ "type":2,
+ "userid": getUserInfo()["Czybm"]
+ },
+ })
+ if (!res) {
+ return
+ }
+ let {
+ data,
+ count,
+ Message
+ } = res.data
+ if (count > 0) {
+ this.checkCount += res.data.data.length
+ console.log(res.data.data.length)
+
+ } else {
+ uni.showToast({
+ icon: 'none',
+ title: Message
+ })
+ }
+ } catch (err) {
+ console.warn(err);
+ uni.showToast({
+ title: '鎺ュ彛璇锋眰澶辫触:' + err,
+ icon: 'none'
+ })
+ }
+ },
+ //鏈欢鍏ㄩ儴
+ async cmdSearchLast(){
+ try {
+ let res = await CommonUtils.doRequest2Sync({
+ url: '/LEMS/CheckFlowList',
+ data: {
+ "sWhere": ' ',
+ "billType":8507,
+ "type":2,
+ "userid": getUserInfo()["Czybm"]
+ },
+ })
+ if (!res) {
+ return
+ }
+ let {
+ data,
+ count,
+ Message
+ } = res.data
+ if (count > 0) {
+ this.checkCount += res.data.data.length
+
+ } else {
+ uni.showToast({
+ icon: 'none',
+ title: Message
+ })
+ }
+ } catch (err) {
+ console.warn(err);
+ uni.showToast({
+ title: '鎺ュ彛璇锋眰澶辫触:' + err,
+ icon: 'none'
+ })
+ }
}
- }
+ }
}
</script>
diff --git a/pages/index/tab4.vue b/pages/index/tab4.vue
index 23966cd..2e86cc1 100644
--- a/pages/index/tab4.vue
+++ b/pages/index/tab4.vue
@@ -102,7 +102,7 @@
},
{
"img": "../../static/icon/icon8.png",
- "text": "鐢熶骇鍏ュ簱鏍¢獙鍗�",
+ "text": "鐢熶骇鍏ュ簱妫�楠屽崟",
"url": "/pages/ZLGL/shengchanrukujiaoyan/QC_LastPieceCheckBill_v2",
"id": 53,
"hidden": false
diff --git a/pages/mujvzhuangtai/mujvzhuangtai.vue b/pages/mujvzhuangtai/mujvzhuangtai.vue
index c8d6fb0..f640c33 100644
--- a/pages/mujvzhuangtai/mujvzhuangtai.vue
+++ b/pages/mujvzhuangtai/mujvzhuangtai.vue
@@ -3,13 +3,15 @@
<view class="container">
<view class="warehouse-selector">
<view class="left">褰撳墠浠撳簱锛�</view>
- <picker :range="warehouseRange" :value="warehouseSelected" @change="warehouseChange">
- <view class="right">
- <input type="text" disabled v-model="warehouseSelected" placeholder="璇烽�夋嫨褰撳墠浠撳簱">
- <uni-icons type="forward" color="#808080"
- style="border-left: 1rpx solid #aaaaaa;padding: 0 8rpx;" size="18"></uni-icons>
- </view>
- </picker>
+ <zxz-uni-data-select
+ v-model="HWHID"
+ dataKey="HName"
+ dataValue="HItemID"
+ :filterable="true"
+ :localdata="HWHList"
+ :clear="false"
+ @change="warehouseChange"
+ ></zxz-uni-data-select>
</view>
<!-- 鍒嗗壊绾� -->
@@ -31,6 +33,9 @@
</view>
<view class="detail" v-if="item['浠撳簱']">
<text>浠撳簱锛�</text>{{item['浠撳簱']}}
+ </view>
+ <view class="detail" v-if="item['浠撲綅']">
+ <text>浠撲綅锛�</text>{{item['浠撲綅']}}
</view>
<view class="detail" v-if="item['璁捐瀵垮懡']">
<text>璁捐瀵垮懡锛�</text>{{item['璁捐瀵垮懡']}}
@@ -80,12 +85,12 @@
import {
getUserInfo
} from "@/utils/auth.js";
+ import { CommonUtils } from '@/utils/common';
export default {
data() {
return {
- warehouseRange: [],
- warehouseIDRange: [],
- warehouseSelected: "",
+ HWHList: [],
+ HWHID:getUserInfo()["HWhID"],
userInfo: getUserInfo(),
organInfo: {
id: uni.getStorageSync("OrganizationID") || "",
@@ -130,10 +135,8 @@
})
uni.hideLoading()
},
- async warehouseChange(e) {
- let index = e.detail.value
- this.warehouseSelected = this.warehouseRange[index]
- let id = this.warehouseIDRange[index]
+ async warehouseChange() {
+ let id = this.HWHID
this.moulds = []
this.doRequest(
"/Web/Get_Sc_MouldStatusAnalysisList", {
@@ -163,36 +166,27 @@
)
},
async initWHSelector() {
- this.doRequest(
- "/Gy_Warehouse/listTree", {
- sWhere: "",
- user: this.userInfo.Czymc,
- Organization: this.organInfo.name
- },
- function(res) {
- console.log(res)
- let {
- count,
- data
- } = res.data
- this.warehouseRange = []
- this.warehouseIDRange = []
- if (count > 0) {
- JSON.parse(data)[0].children.forEach(item => {
- this.warehouseRange.push(`${item.Number}-${item.Title}`)
- this.warehouseIDRange.push(item.Id)
- })
- }
-
- this.warehouseChange({
- detail: {
- value: 0
- }
- })
- },
- function(err) {
- console.error(err)
- },
+ CommonUtils.doRequest(
+ "/Web/GetWarehouseList_Json_New", {
+ Warehouse: "",
+ HOrgID: uni.getStorageSync('OrganizationID')
+ },
+ (res) => {
+ let res1 = res.data
+ let {
+ data,
+ count
+ } = res1
+ if (count == 1) {
+ this.HWHList = data
+ this.warehouseChange();
+ } else {
+ uni.showToast({
+ title: '浠撳簱鏁版嵁璇锋眰澶辫触',
+ icon: 'none'
+ })
+ }
+ },
)
},
ToDetail(item) {
@@ -205,37 +199,35 @@
await this.initWHSelector()
},
onPullDownRefresh() {
- let whIndex = this.warehouseRange.indexOf(this.warehouseSelected);
- if(whIndex != -1){
- let id = this.warehouseIDRange[whIndex]
- this.moulds = []
- this.doRequest(
- "/Web/Get_Sc_MouldStatusAnalysisList", {
- sWhere: ` and HWHID = ${id}`,
- user: this.userInfo.Czymc,
- Organization: this.organInfo.name
- },
- function(res) {
- console.log(res)
- let res1 = res.data
- let {
- data,
- count
- } = res1
- if (count > 0) {
- console.log(data)
- this.moulds = data.map(item => {
- return Object.assign(item, {
- imgSrc: "../../static/mold.png"
- })
+ let id = this.HWHID
+ this.moulds = []
+ this.doRequest(
+ "/Web/Get_Sc_MouldStatusAnalysisList", {
+ sWhere: ` and HWHID = ${id} and HUSEORGID = ${uni.getStorageSync("OrganizationID")}`,
+ user: this.userInfo.Czymc,
+ Organization: this.organInfo.name
+ },
+ function(res) {
+ console.log(res)
+ let res1 = res.data
+ let {
+ data,
+ count
+ } = res1
+ if (count > 0) {
+ console.log(data)
+ this.moulds = data.map(item => {
+ return Object.assign(item, {
+ imgSrc: "../../static/mold.png"
})
- }
- },
- function(err) {
- console.error(err)
+ })
}
- )
- }
+ },
+ function(err) {
+ console.error(err)
+ }
+ )
+
uni.stopPullDownRefresh()
}
}
diff --git a/pages/qijvguzhangdengji/mouldMistakeBill.vue b/pages/qijvguzhangdengji/mouldMistakeBill.vue
index f9d29af..72018db 100644
--- a/pages/qijvguzhangdengji/mouldMistakeBill.vue
+++ b/pages/qijvguzhangdengji/mouldMistakeBill.vue
@@ -803,9 +803,10 @@
message = '鏈~鍐欓儴闂�'
} else if (!this.hform.HEmpName) {
message = '鏈~鍐欏彂鐜颁汉'
- } else if (!this.hform.HManagerName) {
- message = '鏈~鍐欒礋璐d汉'
- }
+ }
+ // else if (!this.hform.HManagerName) {
+ // message = '鏈~鍐欒礋璐d汉'
+ // }
if (!message) {
return true
diff --git a/utils/auth.js b/utils/auth.js
index 7574e40..488f616 100644
--- a/utils/auth.js
+++ b/utils/auth.js
@@ -74,7 +74,7 @@
}
export function getUserInfo() {
let userinfo = uni.getStorageSync('userinfo');
- // console.log('userinfo', userinfo)
+ console.log('userinfo', userinfo)
if (userinfo) {
return JSON.parse(userinfo);
}
--
Gitblit v1.9.1