diff --git a/mycomponents/scan/winScanProdline.vue b/mycomponents/scan/winScanProdline.vue deleted file mode 100644 index e174fcfd..00000000 --- a/mycomponents/scan/winScanProdline.vue +++ /dev/null @@ -1,113 +0,0 @@ - - - - - diff --git a/pages/count/job/countDetail.vue b/pages/count/job/countDetail.vue index b5d9c19c..375e14b7 100644 --- a/pages/count/job/countDetail.vue +++ b/pages/count/job/countDetail.vue @@ -288,11 +288,15 @@ this.$refs.scanPopup.openScanPopupForJob(fromlocationCode, fromlocationList, this.jobContent); }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.packGetFocus(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.packGetFocus(); + } }, getScanResult(result) { diff --git a/pages/count/record/countRecord.vue b/pages/count/record/countRecord.vue index 9e6dac39..8f7e4bc7 100644 --- a/pages/count/record/countRecord.vue +++ b/pages/count/record/countRecord.vue @@ -116,7 +116,7 @@ this.tolocationTypeList = res.tolocationTypeList; this.showFromLocationPopup(); } else { - this.$refs.comMessage.showBreakMessage(res.message ); + this.showErrorMessage(res.message) } }); @@ -218,11 +218,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.packGetFocus(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.packGetFocus(); + } }, getScanResult(result) { diff --git a/pages/customerReturn/job/returnDetail.vue b/pages/customerReturn/job/returnDetail.vue index a0e68845..04b46221 100644 --- a/pages/customerReturn/job/returnDetail.vue +++ b/pages/customerReturn/job/returnDetail.vue @@ -466,11 +466,15 @@ }, scanPopupGetFocus() { - this.$refs.scanPopup.packGetFocus(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.packGetFocus(); + } }, scanPopupLoseFocus() { - this.$refs.scanPopup.packLoseFocus(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.packLoseFocus(); + } }, afterCloseMessage() { diff --git a/pages/customerReturn/record/returnRecord.vue b/pages/customerReturn/record/returnRecord.vue index 02ed207b..e4f854e6 100644 --- a/pages/customerReturn/record/returnRecord.vue +++ b/pages/customerReturn/record/returnRecord.vue @@ -218,11 +218,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanLocationCode(location, code) { @@ -388,15 +392,18 @@ showCommitSuccessMessage(hint) { this.$refs.comMessage.showSuccessMessage(hint, res => { - this.fromLocationCode = ''; - this.subList = []; - this.detailSource = []; - this.toLocationCode = ''; - this.dataContent = {} - this.toWarehouseCode = "" - + this.clearData() }) }, + + clearData(){ + this.fromLocationCode = ''; + this.subList = []; + this.detailSource = []; + this.toLocationCode = ''; + this.dataContent = {} + this.toWarehouseCode = "" + }, updateData() { this.calcHandleQty(); diff --git a/pages/customerReturn/request/customerReturnRequest.vue b/pages/customerReturn/request/customerReturnRequest.vue index fa2d29f1..a85fd3c7 100644 --- a/pages/customerReturn/request/customerReturnRequest.vue +++ b/pages/customerReturn/request/customerReturnRequest.vue @@ -33,9 +33,7 @@ goHome, updateTitle } from '@/common/basic.js'; - import { - getBusinessType, - } from '@/common/record.js'; + import { getCustomerReturnRequestList, } from '@/api/request2.js'; diff --git a/pages/deliver/record/deliverRecord.vue b/pages/deliver/record/deliverRecord.vue index 9a9af942..f4e9945e 100644 --- a/pages/deliver/record/deliverRecord.vue +++ b/pages/deliver/record/deliverRecord.vue @@ -251,11 +251,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.getfocus(); + } }, scanLocationCode(location, code) { @@ -423,15 +427,18 @@ showCommitSuccessMessage(hint) { this.$refs.comMessage.showSuccessMessage(hint, res => { - this.fromLocationCode = ''; - this.subList = []; - this.detailSource = []; - this.toLocationCode = ''; - this.dataContent = {} - this.toWarehouseCode = "" - + this.clearData(); }) }, + + clearData(){ + this.fromLocationCode = ''; + this.subList = []; + this.detailSource = []; + this.toLocationCode = ''; + this.dataContent = {} + this.toWarehouseCode = "" + }, updateData() { this.calcHandleQty(); diff --git a/pages/deliver/request/deliverRequest.vue b/pages/deliver/request/deliverRequest.vue index 2554664d..4c0f5792 100644 --- a/pages/deliver/request/deliverRequest.vue +++ b/pages/deliver/request/deliverRequest.vue @@ -33,9 +33,6 @@ goHome, updateTitle } from '@/common/basic.js'; - import { - getBusinessType, - } from '@/common/record.js'; import { getDeliverRequestList, } from '@/api/request2.js'; diff --git a/pages/inventoryMove/coms/comMove.vue b/pages/inventoryMove/coms/comMove.vue index 8e4959a8..976003c0 100644 --- a/pages/inventoryMove/coms/comMove.vue +++ b/pages/inventoryMove/coms/comMove.vue @@ -271,15 +271,17 @@ }, showCommitSuccessMessage(hint) { this.$refs.comMessage.showSuccessMessage(hint, res => { - this.fromLocationCode = ''; - this.subList = []; - this.detailSource = []; - this.toLocationCode = ''; - this.dataContent = {} - this.toWarehouseCode = "" - + this.clearData() }) }, + clearData(){ + this.fromLocationCode = ''; + this.subList = []; + this.detailSource = []; + this.toLocationCode = ''; + this.dataContent = {} + this.toWarehouseCode = "" + }, commit() { if (this.toLocationCode == "") { diff --git a/pages/issue-按批次推荐/job/issueDetail.vue b/pages/issue-按批次推荐/job/issueDetail.vue index 5d5578af..14c05d03 100644 --- a/pages/issue-按批次推荐/job/issueDetail.vue +++ b/pages/issue-按批次推荐/job/issueDetail.vue @@ -597,10 +597,11 @@ }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, - showMessage(message) { this.$refs.comMessage.showMessage(message, res => { if (res) { diff --git a/pages/issue/record/issueRecord.vue b/pages/issue/record/issueRecord.vue index 9bccea91..81613792 100644 --- a/pages/issue/record/issueRecord.vue +++ b/pages/issue/record/issueRecord.vue @@ -103,7 +103,7 @@ this.toInventoryStatuses = res.toInventoryStatuses this.goScan(true) } else { - this.$refs.comMessage.showBreakMessage(res.message); + this.showErrorMessage(res.message) } }); diff --git a/pages/issue/request/issueRequest.vue b/pages/issue/request/issueRequest.vue index 62eda712..8d7793ce 100644 --- a/pages/issue/request/issueRequest.vue +++ b/pages/issue/request/issueRequest.vue @@ -36,9 +36,6 @@ clearTirmAndWrap } from '@/common/basic.js'; - import { - getBusinessType, - } from '@/common/record.js'; import { getIssueRequestList, issueRequestClose, diff --git a/pages/package/record/mergePackageRecord.vue b/pages/package/record/mergePackageRecord.vue index 9cf29be0..5f69eb74 100644 --- a/pages/package/record/mergePackageRecord.vue +++ b/pages/package/record/mergePackageRecord.vue @@ -35,7 +35,8 @@ - + + @@ -46,7 +47,7 @@ import { goHome } from '@/common/basic.js'; - + import { getInventoryStatusDesc, getDirectoryItemArray @@ -118,7 +119,7 @@ this.tolocationTypeList = res.tolocationTypeList; this.showFromLocationPopup(); } else { - this.$refs.comMessage.showBreakMessage(res.message); + this.showErrorMessage(res.message) } }); }, @@ -134,7 +135,7 @@ onPullDownRefresh() {}, mounted() {}, - + methods: { scanPopupPack() { this.$refs.scanPopupPack.openScanPopup(); @@ -219,11 +220,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanLocationCode(location, code) { diff --git a/pages/package/record/overPackageRecord.vue b/pages/package/record/overPackageRecord.vue index eef1d1d0..a0157c9a 100644 --- a/pages/package/record/overPackageRecord.vue +++ b/pages/package/record/overPackageRecord.vue @@ -30,7 +30,8 @@ - + + @@ -43,7 +44,7 @@ import { goHome } from '@/common/basic.js'; - + import { getInventoryStatusDesc, getDirectoryItemArray @@ -243,11 +244,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanLocationCode(location, code) { diff --git a/pages/package/record/splitPackageRecord.vue b/pages/package/record/splitPackageRecord.vue index 4c70c950..a343480a 100644 --- a/pages/package/record/splitPackageRecord.vue +++ b/pages/package/record/splitPackageRecord.vue @@ -29,7 +29,8 @@ - + + @@ -42,7 +43,7 @@ import { goHome, } from '@/common/basic.js'; - + import { getInventoryStatusDesc, getDirectoryItemArray @@ -243,11 +244,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanLocationCode(location, code) { diff --git a/pages/pallet/record/bindPalletRecord.vue b/pages/pallet/record/bindPalletRecord.vue index 6cfafc89..076051be 100644 --- a/pages/pallet/record/bindPalletRecord.vue +++ b/pages/pallet/record/bindPalletRecord.vue @@ -111,7 +111,7 @@ this.tolocationTypeList = res.tolocationTypeList; this.showFromLocationPopup(); } else { - this.$refs.comMessage.showBreakMessage(res.message); + this.showErrorMessage(res.message) } }); }, diff --git a/pages/pallet/record/unBindPalletRecord.vue b/pages/pallet/record/unBindPalletRecord.vue index c40b08d9..d99d928a 100644 --- a/pages/pallet/record/unBindPalletRecord.vue +++ b/pages/pallet/record/unBindPalletRecord.vue @@ -49,7 +49,7 @@ import { goHome } from '@/common/basic.js'; - + import { getDirectoryItemArray } from '@/common/directory.js'; @@ -242,15 +242,19 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + this.$refs.scanPopup.closeScanPopup(); }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanPopupLoseFocus() { - this.$refs.scanPopup.losefocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.losefocus(); + } }, @@ -261,7 +265,7 @@ } }, - + showMessage(message) { setTimeout(r => { this.scanPopupLoseFocus(); diff --git a/pages/productDismantle/record/productDismantleRecord.vue b/pages/productDismantle/record/productDismantleRecord.vue index 462309cb..a7a66579 100644 --- a/pages/productDismantle/record/productDismantleRecord.vue +++ b/pages/productDismantle/record/productDismantleRecord.vue @@ -119,7 +119,7 @@ this.tolocationTypeList = res.tolocationTypeList; this.showFromLocationPopup(); } else { - this.$refs.comMessage.showBreakMessage(res.message); + this.showErrorMessage(res.message) } }); }, @@ -214,11 +214,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanLocationCode(location, code) { diff --git a/pages/productPutaway/record/productPutawayRecord.vue b/pages/productPutaway/record/productPutawayRecord.vue index f1dbbdca..1ffe223d 100644 --- a/pages/productPutaway/record/productPutawayRecord.vue +++ b/pages/productPutaway/record/productPutawayRecord.vue @@ -18,13 +18,13 @@ - + - @@ -43,7 +43,6 @@ diff --git a/pages/productionReturn/record/returnToStore.vue b/pages/productionReturn/record/returnToStore.vue index 11c23ad5..fb54d4bb 100644 --- a/pages/productionReturn/record/returnToStore.vue +++ b/pages/productionReturn/record/returnToStore.vue @@ -456,12 +456,15 @@ showCommitSuccessMessage(hint) { this.$refs.comMessage.showSuccessMessage(hint, res => { - this.subList = []; - this.detailSource = []; - this.toLocationCode = ''; - this.dataContent = {}; + this.clearData(); }) }, + clearData(){ + this.subList = []; + this.detailSource = []; + this.toLocationCode = ''; + this.dataContent = {}; + } } } diff --git a/pages/purchaseReceipt/job/receiptDetail.vue b/pages/purchaseReceipt/job/receiptDetail.vue index 4443c572..c58955a4 100644 --- a/pages/purchaseReceipt/job/receiptDetail.vue +++ b/pages/purchaseReceipt/job/receiptDetail.vue @@ -421,11 +421,15 @@ }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanPopupLoseFocus() { - this.$refs.scanPopup.losefocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.losefocus(); + } }, diff --git a/pages/purchaseReturn/job/returnDetail.vue b/pages/purchaseReturn/job/returnDetail.vue index beb7f379..de1333e6 100644 --- a/pages/purchaseReturn/job/returnDetail.vue +++ b/pages/purchaseReturn/job/returnDetail.vue @@ -428,7 +428,7 @@ showCommitSuccessMessage(number) { this.$refs.comMessage.showSuccessMessage('提交成功
生成退货记录:' + number, res => { - navigateBack() + navigateBack(1) }) } } diff --git a/pages/purchaseReturn/record/returnRecord.vue b/pages/purchaseReturn/record/returnRecord.vue index 88bdeb15..f79ec716 100644 --- a/pages/purchaseReturn/record/returnRecord.vue +++ b/pages/purchaseReturn/record/returnRecord.vue @@ -108,7 +108,7 @@ this.tolocationTypeList = res.tolocationTypeList; this.showFromLocationPopup(); } else { - this.$refs.comMessage.showBreakMessage(res.message); + this.showErrorMessage(res.message) } }); }, diff --git a/pages/purchaseReturn/request/returnRequest.vue b/pages/purchaseReturn/request/returnRequest.vue index a751475e..0d43048c 100644 --- a/pages/purchaseReturn/request/returnRequest.vue +++ b/pages/purchaseReturn/request/returnRequest.vue @@ -30,9 +30,6 @@ import requestInfoPopup from '@/pages/purchaseReturn/coms/requestInfoPopup.vue' import requestButton from '@/mycomponents/button/requestButton.vue' - import { - getBusinessType, - } from '@/common/record.js'; import { goHome, updateTitle, diff --git a/pages/purchaseReturn/request/returnRequestCreate.vue b/pages/purchaseReturn/request/returnRequestCreate.vue index 8f37e68e..986c8772 100644 --- a/pages/purchaseReturn/request/returnRequestCreate.vue +++ b/pages/purchaseReturn/request/returnRequestCreate.vue @@ -101,7 +101,7 @@ this.tolocationTypeList = res.tolocationTypeList; this.showFromLocationPopup(); } else { - this.$refs.comMessage.showBreakMessage(res.message); + this.showErrorMessage(res.message) } }); }, diff --git a/pages/putaway/record/putawayRecord.vue b/pages/putaway/record/putawayRecord.vue index 8286d84b..f047ea6e 100644 --- a/pages/putaway/record/putawayRecord.vue +++ b/pages/putaway/record/putawayRecord.vue @@ -260,11 +260,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, // scanLocationCode(location, code) { diff --git a/pages/putaway/request/putawayRequest.vue b/pages/putaway/request/putawayRequest.vue index 0846c7ed..37a8a6a1 100644 --- a/pages/putaway/request/putawayRequest.vue +++ b/pages/putaway/request/putawayRequest.vue @@ -30,10 +30,6 @@ import requestInfoPopup from '@/pages/putaway/coms/requestInfoPopup.vue' import requestButton from '@/mycomponents/button/requestButton.vue' - import { - getBusinessType, - } from '@/common/record.js'; - import { goHome, updateTitle diff --git a/pages/query/container.vue b/pages/query/container.vue index 752cb7a7..0f9847a7 100644 --- a/pages/query/container.vue +++ b/pages/query/container.vue @@ -2,16 +2,16 @@ - + @@ -22,7 +22,7 @@ - + 、 @@ -81,7 +81,7 @@ old: { scrollTop: 0 }, - + detailList: [], summarysList: [], dataList: [], @@ -95,8 +95,7 @@ goHome(); } }, - filters: { - }, + filters: {}, mounted() { this.openScanPopup() }, @@ -114,13 +113,13 @@ this.occupieds = []; this.getItemInfo(code); }, - + getItemInfo(code) { uni.showLoading({ title: "正在查询器具信息...", mask: true }); - + getContainerByNumber(code).then(res => { uni.hideLoading(); if (res.data.list.length > 0) { @@ -131,7 +130,7 @@ } else { this.showMessage('未查找到零件【' + code + '】'); } - + }).catch(error => { uni.hideLoading(); this.containerNumber = ""; @@ -139,7 +138,7 @@ }) }, - getSummary(pageNo,pageSize) { + getSummary(pageNo, pageSize) { let that = this; uni.showLoading({ title: "加载中...", @@ -154,7 +153,7 @@ uni.hideLoading(); if (res.data.list.length > 0) { this.summarysList = this.setShowList(res.data.list) - this.$refs.paging.complete(this.summarysList); + this.$refs.paging.complete(this.summarysList); } else { this.$refs.paging.complete(false); this.showMessage('未查找到器具【' + this.containerNumber + '】'); @@ -167,7 +166,7 @@ }, - getDetailList(pageNo,pageSize) { + getDetailList(pageNo, pageSize) { let that = this; uni.showLoading({ title: "加载中...", @@ -231,17 +230,15 @@ return resultlist; }, - getContentByTab(index,pageNo, pageSize) { + getContentByTab(index, pageNo, pageSize) { if (index === 0) { this.getSummary(pageNo, pageSize); } else if (index === 1) this.getDetailList(pageNo, pageSize) - - }, - upper: function(e) { - }, - lower: function(e) { }, + + upper: function(e) {}, + lower: function(e) {}, tabChange(index) { this.tabIndex = index; this.$refs.paging.reload(true); @@ -254,14 +251,16 @@ }); }, afterCloseMessage() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, queryList(pageNo, pageSize) { console.log("加载", pageNo) if (this.containerNumber != "") { this.getContentByTab(this.tabIndex, pageNo, pageSize) } - + }, } }; diff --git a/pages/query/item.vue b/pages/query/item.vue index 901411c9..3d6a24b2 100644 --- a/pages/query/item.vue +++ b/pages/query/item.vue @@ -244,7 +244,9 @@ }); }, afterCloseMessage() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, tabChange(index) { this.tabIndex = index; diff --git a/pages/query/item_copy.vue b/pages/query/item_copy.vue index 64c3925c..726ff0ff 100644 --- a/pages/query/item_copy.vue +++ b/pages/query/item_copy.vue @@ -17,26 +17,26 @@ - + + - + - + - + @@ -204,7 +204,7 @@ uni.hideLoading(); this.balances = ""; this.showMessage(error); - + }) }, @@ -303,7 +303,9 @@ }); }, afterCloseMessage() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } } } }; diff --git a/pages/query/location.vue b/pages/query/location.vue index e04f22da..750579d4 100644 --- a/pages/query/location.vue +++ b/pages/query/location.vue @@ -2,7 +2,7 @@ - + @@ -22,7 +22,7 @@ - + @@ -35,7 +35,6 @@ - - + + + + + diff --git a/pages/scrap/record/scrapRecord.vue b/pages/scrap/record/scrapRecord.vue index 9150d69f..6f6a2871 100644 --- a/pages/scrap/record/scrapRecord.vue +++ b/pages/scrap/record/scrapRecord.vue @@ -55,7 +55,6 @@ import { goHome, - updateTitle, } from '@/common/basic.js'; import { @@ -232,17 +231,20 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if(this.$refs.scanPopup!=undefined){ + this.$refs.scanPopup.getfocus(); + } }, - commit() { if(this.reasonText==""){ - this.showMessage("请先选择报废原因") + this.showErrorMessage("请先选择报废原因") return; } //允许部分提交 @@ -302,14 +304,6 @@ }, - - - - showMessage(message) { - this.$refs.comMessage.showMessage(message, res => { - if (res) {} - }); - }, showErrorMessage(message) { this.$refs.comMessage.showErrorMessage(message, res => { if (res) { @@ -339,15 +333,17 @@ showCommitSuccessMessage(hint) { this.$refs.comMessage.showSuccessMessage(hint, res => { - this.reasonCode = "" - this.reasonText = ""; - this.detailSource = []; - this.subList =[]; - this.managementList =[]; - this.dataContent ={} - + this.clearData(); }) }, + clearData(){ + this.reasonCode = "" + this.reasonText = ""; + this.detailSource = []; + this.subList =[]; + this.managementList =[]; + this.dataContent ={} + }, updateData() { this.calcHandleQty(); diff --git a/pages/scrap/request/scrapRequestCreate.vue b/pages/scrap/request/scrapRequestCreate.vue index b4c921f4..dfe29d07 100644 --- a/pages/scrap/request/scrapRequestCreate.vue +++ b/pages/scrap/request/scrapRequestCreate.vue @@ -128,7 +128,7 @@ this.tolocationTypeList = res.tolocationTypeList; this.showFromLocationPopup(); } else { - this.$refs.comMessage.showBreakMessage(res.message); + this.showErrorMessage(res.message) } }); @@ -228,11 +228,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, diff --git a/pages/setter/index.vue b/pages/setter/index.vue index ab58b855..c27cc6ac 100644 --- a/pages/setter/index.vue +++ b/pages/setter/index.vue @@ -55,12 +55,12 @@ import { onLoad } from "@dcloudio/uni-app"; + const userName = ref(store.state.user.name); let test = ref("123"); let userInfo = ref(null); onLoad(() => { - console.log(11) getUserProfile().then(res => { userInfo.value = res.data // nextTick(()=>{ diff --git a/pages/transfer/coms/comTransferRecord.vue b/pages/transfer/coms/comTransferRecord.vue index 667b2558..f547133a 100644 --- a/pages/transfer/coms/comTransferRecord.vue +++ b/pages/transfer/coms/comTransferRecord.vue @@ -107,7 +107,7 @@ businessType: {}, managementList: [], dataContent: {}, - toWarehouseCode:'' + toWarehouseCode: '' }; }, @@ -155,7 +155,7 @@ if (item == undefined) { var itemp = createItemInfo(balance, pack); let newDetail = createDetailInfo(balance, pack); // - newDetail.inventoryStatus ="OK" + newDetail.inventoryStatus = "OK" itemp.subList.push(newDetail); this.detailSource.push(itemp) } else { @@ -221,11 +221,15 @@ }, closeScanPopup() { - this.$refs.scanPopup.closeScanPopup(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.closeScanPopup(); + } }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanLocationCode(location, code) { @@ -241,7 +245,7 @@ }, commit() { - + if (this.toLocationCode == "") { this.showMessage("请先选择目标库位") return; @@ -254,7 +258,7 @@ }); this.managementList = []; var precisionStrategParams = this.setPrecisionStrategParams() - + getPrecisionStrategyList(precisionStrategParams, res => { if (res.success) { this.managementList = res.list; @@ -340,7 +344,7 @@ detail.itemName = detail.package.itemName; detail.itemDesc1 = detail.package.itemDesc1; detail.itemDesc2 = detail.package.itemDesc2; - + detail.inventoryStatus = detail.inventoryStatus; detail.fromPackingNumber = info.packingNumber; @@ -399,7 +403,7 @@ this.openScanPopup(); }, getToLocationCode(location, code) { - this.toWarehouseCode =location.warehouseCode + this.toWarehouseCode = location.warehouseCode // if (this.fromLocationCode == code) { // uni.showToast({ // title: "来源库位[" + this.fromLocationCode + "]不能与目标库位[" + code + "]一致", @@ -412,15 +416,17 @@ showCommitSuccessMessage(hint) { this.$refs.comMessage.showSuccessMessage(hint, res => { - this.fromLocationCode = ''; - this.subList = []; - this.detailSource = []; - this.toLocationCode = ''; - this.dataContent = {} - this.toWarehouseCode = "" - + this.clearData(); }) }, + clearData(){ + this.fromLocationCode = ''; + this.subList = []; + this.detailSource = []; + this.toLocationCode = ''; + this.dataContent = {} + this.toWarehouseCode = "" + }, updateData() { this.calcHandleQty(); diff --git a/pages/unPlanned/job/receiptJobDetail.vue b/pages/unPlanned/job/receiptJobDetail.vue index a8a18ab0..3342d8b5 100644 --- a/pages/unPlanned/job/receiptJobDetail.vue +++ b/pages/unPlanned/job/receiptJobDetail.vue @@ -73,7 +73,7 @@ import comMessage from '@/mycomponents/common/comMessage.vue' import comReceiptDetailCard from '@/pages/unPlanned/coms/comReceiptDetailCard.vue' import jobTop from '@/mycomponents/job/jobTop.vue' - + export default { name: 'receipt_detail', components: { @@ -243,16 +243,16 @@ } }, - commit() { - this.scanCount = getScanCount(this.subList); - if( this.scanCount==0){ - this.showErrorMessage("扫描数为0,请先扫描") - return; - } - //校验库位、 - if (!this.checkLocation()) { - return - } + commit() { + this.scanCount = getScanCount(this.subList); + if (this.scanCount == 0) { + this.showErrorMessage("扫描数为0,请先扫描") + return; + } + //校验库位、 + if (!this.checkLocation()) { + return + } //扫描数量和任务数量相等,直接提交 if (this.scanCount == this.subList.length) { this.submitJob(); @@ -273,19 +273,19 @@ } } }, - + checkLocation() { var isPass = true; if (this.toLocationCode == "" || this.toLocationCode == null) { this.showMessageHint('请扫描目标库位', callback => { this.$refs.comScanLocation.showLocation(); }) - + return isPass = false; } return isPass; }, - + showMessageHint(hint, callback) { this.$refs.comMessage.showErrorMessage(hint, res => { if (res) { @@ -295,7 +295,7 @@ }, - submitJob() { + submitJob() { uni.showLoading({ title: "提交中....", mask: true @@ -317,7 +317,7 @@ } else { this.showErrorMessage("提交失败[" + res.msg + "]") } - + }).catch(error => { uni.hideLoading() this.showErrorMessage(error) @@ -385,11 +385,15 @@ }, scanPopupGetFocus() { - this.$refs.scanPopup.getfocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.getfocus(); + } }, scanPopupLoseFocus() { - this.$refs.scanPopup.losefocus(); + if (this.$refs.scanPopup != undefined) { + this.$refs.scanPopup.losefocus(); + } }, showCommitSuccessMessage(hint) { diff --git a/pages/unPlanned/record/issueRecord.vue b/pages/unPlanned/record/issueRecord.vue index c134f140..e5d9b738 100644 --- a/pages/unPlanned/record/issueRecord.vue +++ b/pages/unPlanned/record/issueRecord.vue @@ -54,10 +54,6 @@ unPlannedIssueRecordSubmit } from '@/api/request2.js'; - import { - getBalanceByUniquecode, - } from '@/api/request.js'; - import { getBusinessType, } from '@/common/record.js'; @@ -278,13 +274,16 @@ }, showCommitSuccessMessage(hint) { this.$refs.comMessage.showSuccessMessage(hint, res => { - this.reasonCode = "" - this.reasonText = ""; - this.detailSource = []; - this.managementList =[]; - this.dataContent ={} + }) }, + clearData(){ + this.reasonCode = "" + this.reasonText = ""; + this.detailSource = []; + this.managementList =[]; + this.dataContent ={} + } } } diff --git a/pages/unPlanned/record/receiptRecord.vue b/pages/unPlanned/record/receiptRecord.vue index f56bf620..fc0f6e59 100644 --- a/pages/unPlanned/record/receiptRecord.vue +++ b/pages/unPlanned/record/receiptRecord.vue @@ -351,14 +351,17 @@ }, showCommitSuccessMessage(hint) { this.$refs.comMessage.showSuccessMessage(hint, res => { - this.reasonCode = "" - this.reasonText = ""; - this.detailSource = []; - this.managementList=[]; - this.dataContent ={} - this.toLocationCode ="" + this.clearData(); }) }, + clearData(){ + this.reasonCode = "" + this.reasonText = ""; + this.detailSource = []; + this.managementList=[]; + this.dataContent ={} + this.toLocationCode ="" + } } diff --git a/pages/unPlanned/request/issueRequest.vue b/pages/unPlanned/request/issueRequest.vue index 4895f0a1..fea2284c 100644 --- a/pages/unPlanned/request/issueRequest.vue +++ b/pages/unPlanned/request/issueRequest.vue @@ -36,9 +36,7 @@ updateTitle, clearTirmAndWrap } from '@/common/basic.js'; - import { - getBusinessType, - } from '@/common/record.js'; + import { getUnPlannedIssueRequestList, unPlannedIssueRequestApprove, diff --git a/pages/unPlanned/request/issueRequestCreate.vue b/pages/unPlanned/request/issueRequestCreate.vue index 4e96ea9f..433a0f8f 100644 --- a/pages/unPlanned/request/issueRequestCreate.vue +++ b/pages/unPlanned/request/issueRequestCreate.vue @@ -60,10 +60,6 @@ unPlannedIssueRequestCreate, } from '@/api/request2.js'; - import { - getBalanceByUniquecode, - } from '@/api/request.js'; - import { getBusinessType, } from '@/common/record.js'; @@ -128,7 +124,7 @@ this.fromLocationTypeArray = res.fromlocationTypeList; this.showFromLocationPopup(); } else { - this.$refs.comMessage.showBreakMessage(res.message); + this.showErrorMessage(res.message) } }); diff --git a/pages/unPlanned/request/receiptRequest.vue b/pages/unPlanned/request/receiptRequest.vue index 77dacb7a..d304ef4c 100644 --- a/pages/unPlanned/request/receiptRequest.vue +++ b/pages/unPlanned/request/receiptRequest.vue @@ -30,9 +30,6 @@ import requestRecInfoPopup from '@/pages/unPlanned/coms/requestRecInfoPopup.vue' import requestButton from '@/mycomponents/button/requestButton.vue' - import { - getBusinessType, - } from '@/common/record.js'; import { goHome, updateTitle,