From 8819121a611c36046798583b60a6893c7cb18d1f Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Mon, 29 Jul 2024 14:50:20 +0800 Subject: [PATCH 1/5] =?UTF-8?q?=E8=A1=A5=E6=96=99=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E3=80=81=E5=8F=91=E6=96=99=E4=BB=BB=E5=8A=A1=EF=BC=8C=E9=9C=80?= =?UTF-8?q?=E8=A6=81=E5=A2=9E=E5=8A=A0=E5=85=B3=E9=97=AD=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E5=8A=9F=E8=83=BD=EF=BC=8C=E5=8F=AA=E6=9C=89=E5=BE=85=E5=A4=84?= =?UTF-8?q?=E7=90=86=E7=9A=84=E4=BB=BB=E5=8A=A1=E5=8F=AF=E4=BB=A5=E5=85=B3?= =?UTF-8?q?=E9=97=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/request2.js | 24 +++++++++++ src/common/array.js | 20 +++++++++- src/pages/issue/job/issueJob.vue | 51 +++++++++++++++++++----- src/pages/repleinsh/job/repleinshJob.vue | 38 ++++++++++++++++-- 4 files changed, 119 insertions(+), 14 deletions(-) diff --git a/src/api/request2.js b/src/api/request2.js index 163e023e..1ab89ad3 100644 --- a/src/api/request2.js +++ b/src/api/request2.js @@ -1418,6 +1418,18 @@ export function cancleTakeIssueJob(id) { data: {}, }); } +/** + * 发料 关闭任务 + * @param {*} id + * + */ +export function closeTakeIssueJob(id) { + return request({ + url: baseApi + "/wms/issue-job-main/close?id=" + id, + method: "put", + data: {}, + }); +} /** * 发料任务 提交 @@ -3861,6 +3873,18 @@ export function cancleTakeRepleinshJob(id) { }); } +/** + * 补料任务 关闭任务 + * @param {*} id + * + */ +export function closeTakeRepleinshJob(id) { + return request({ + url: baseApi + "/wms/repleinsh-job-main/close?id=" + id, + method: "put", + data: {}, + }); +} /** * 补料任务 提交 * @param {*} params diff --git a/src/common/array.js b/src/common/array.js index e87d780f..ed1cf95d 100644 --- a/src/common/array.js +++ b/src/common/array.js @@ -223,7 +223,7 @@ export function getDetailEditRemoveOption() { } -//详情编辑放弃 +//详情编辑关闭 export function getDetailGiveupOption() { let option_detail_giveup = [{ text: '详情', @@ -241,7 +241,23 @@ export function getDetailGiveupOption() { return option_detail_giveup; } - +//详情放弃 +export function getDetailCloseOption() { + let option_detail_giveup = [{ + text: '详情', + style: { + backgroundColor: '#3C9CFF' + } + }, + { + text: '关闭', + style: { + backgroundColor: '#F56C6C' + } + } + ]; + return option_detail_giveup; +} //详情编辑移除 export function getEditRemoveOption() { diff --git a/src/pages/issue/job/issueJob.vue b/src/pages/issue/job/issueJob.vue index 16a826ee..89c241e3 100644 --- a/src/pages/issue/job/issueJob.vue +++ b/src/pages/issue/job/issueJob.vue @@ -9,7 +9,8 @@ - @@ -34,7 +35,8 @@ import { cancleTakeIssueJob, getIssueJobList, - getIssueJobByProductionline + getIssueJobByProductionline, + closeTakeIssueJob } from '@/api/request2.js'; import { goHome, @@ -43,7 +45,8 @@ import { getDetailOption, - getDetailGiveupOption + getDetailGiveupOption, + getDetailCloseOption } from '@/common/array.js'; import comEmptyView from '@/mycomponents/common/comEmptyView.vue' @@ -80,7 +83,8 @@ status: '1,2', //待处理 、进行中 detailOptions: [], detailGiveupOptions: [], - productionlineList: [], + productionlineList: [], + detailCloseOptions: [], title:'', productionLine:"", fromLocation:"" @@ -97,6 +101,7 @@ onReady() { this.detailOptions = getDetailOption(); this.detailGiveupOptions = getDetailGiveupOption(); + this.detailCloseOptions = getDetailCloseOption(); }, onReachBottom() { //避免多次触发 @@ -289,11 +294,18 @@ this.openjobInfoPopup(dataContent); } else if (e.content.text == "放弃") { this.$refs.comMessage.showQuestionMessage("确定要放弃当前任务?", - res => { - if (res) { - this.cancleJob(dataContent.masterId); - } - }); + res => { + if (res) { + this.cancleJob(dataContent.masterId); + } + }); + }else if (e.content.text == "关闭") { + this.$refs.comMessage.showQuestionMessage("确定要关闭当前任务?", + res => { + if (res) { + this.closeJob(dataContent.masterId); + } + }); } }, @@ -315,6 +327,27 @@ this.showMessage(error) }) }, + closeJob(id) { + uni.showLoading({ + title: "加载中....", + mask: true + }); + + closeTakeIssueJob(id).then(res => { + uni.hideLoading() + if(res.data){ + this.getList("refresh") + uni.showToast({ + title:"关闭任务成功" + }) + }else { + this.showMessage("关闭任务失败") + } + }).catch(error => { + uni.hideLoading() + this.showMessage(error) + }) + }, switchChangeToday(state, creationTime) { this.checkedToday = state; diff --git a/src/pages/repleinsh/job/repleinshJob.vue b/src/pages/repleinsh/job/repleinshJob.vue index db5cd0b9..8b17f8f2 100644 --- a/src/pages/repleinsh/job/repleinshJob.vue +++ b/src/pages/repleinsh/job/repleinshJob.vue @@ -9,7 +9,7 @@ @@ -31,7 +31,8 @@ import { getRepleinshJobList, - cancleTakeRepleinshJob + cancleTakeRepleinshJob, + closeTakeRepleinshJob } from '@/api/request2.js'; import { @@ -41,7 +42,8 @@ import { getDetailOption, - getDetailGiveupOption + getDetailGiveupOption, + getDetailCloseOption } from '@/common/array.js'; import comEmptyView from '@/mycomponents/common/comEmptyView.vue' @@ -77,6 +79,7 @@ status: '1,2', //待处理 、进行中 detailOptions: [], detailGiveupOptions: [], + detailCloseOptions: [], title:'', scanMessage:"" }; @@ -92,6 +95,7 @@ onReady() { this.detailOptions = getDetailOption(); this.detailGiveupOptions = getDetailGiveupOption(); + this.detailCloseOptions = getDetailCloseOption(); }, //后退按钮 @@ -231,6 +235,13 @@ this.cancleJob(dataContent.masterId); } }); + }else if (e.content.text == "关闭") { + this.$refs.comMessage.showQuestionMessage("确定要关闭当前任务?", + res => { + if (res) { + this.closeJob(dataContent.masterId); + } + }); } }, @@ -252,6 +263,27 @@ this.showMessage(error) }) }, + closeJob(id) { + uni.showLoading({ + title: "加载中....", + mask: true + }); + + closeTakeRepleinshJob(id).then(res => { + uni.hideLoading() + if(res.data){ + this.getList("refresh") + uni.showToast({ + title:"关闭任务成功" + }) + }else { + this.showMessage("关闭任务失败") + } + }).catch(error => { + uni.hideLoading() + this.showMessage(error) + }) + }, switchChangeToday(state, creationTime) { this.checkedToday = state; From 2614e0bb492fb9313d2aba7551b0583ac677a632 Mon Sep 17 00:00:00 2001 From: lijuncheng Date: Tue, 30 Jul 2024 17:09:50 +0800 Subject: [PATCH 2/5] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=9B=98=E7=82=B9?= =?UTF-8?q?=E5=BA=93=E4=BD=8D=E8=B5=8B=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/count/job/countLightDetail.vue | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/pages/count/job/countLightDetail.vue b/src/pages/count/job/countLightDetail.vue index 3bed66ac..ff66ec25 100644 --- a/src/pages/count/job/countLightDetail.vue +++ b/src/pages/count/job/countLightDetail.vue @@ -391,6 +391,8 @@ selectItem.handleQty = Number(qty) selectItem.packQty = pack.packQty selectItem.packUnit = pack.packUnit + selectItem.locationCode =this.fromLocationCode + selectItem.fromLocationCode =this.fromLocationCode this.$refs.countQtyEdit.openEditPopupShowSeconds(selectItem, null); @@ -463,6 +465,7 @@ countQty: 0, balanceQty: Number(qty), fromLocationCode: this.fromLocationCode, + locationCode:this.fromLocationCode, creator: this.$store.state.user.id, countTime: new Date() } @@ -490,6 +493,8 @@ if (!item.scaned) { item.scaned = true; item.handleQty = 0 + item.locationCode =this.fromLocationCode + item.fromLocationCode =this.fromLocationCode } }) this.submitJob(); From 36a20a84e02e5813ff14de112abec75ec0dc273e Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Tue, 30 Jul 2024 17:16:17 +0800 Subject: [PATCH 3/5] =?UTF-8?q?PDA=E9=9A=94=E7=A6=BB=E6=8A=A5=E5=B7=A5?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E6=8F=90=E4=BA=A4=E5=90=8E=EF=BC=8C=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E8=BF=94=E5=9B=9E=E5=BA=94=E8=AF=A5=E5=88=B7=E6=96=B0?= =?UTF-8?q?=EF=BC=8C=E5=B7=B2=E5=AE=8C=E6=88=90=E7=9A=84=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E5=BA=94=E8=AF=A5=E6=B6=88=E5=A4=B1=EF=BC=8C=E7=9B=AE=E5=89=8D?= =?UTF-8?q?=E6=B2=A1=E6=B6=88=E5=A4=B1BUG?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/productReceipt/job/scrapReceiptJob.vue | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/pages/productReceipt/job/scrapReceiptJob.vue b/src/pages/productReceipt/job/scrapReceiptJob.vue index 973ed32b..adc29e07 100644 --- a/src/pages/productReceipt/job/scrapReceiptJob.vue +++ b/src/pages/productReceipt/job/scrapReceiptJob.vue @@ -20,6 +20,11 @@ onLoad(option){ this.title = option.title }, + onShow(){ + this.$nextTick(()=>{ + this.$refs.productreceiptjob.refresh() + }) + }, onReachBottom() { this.$refs.productreceiptjob.onReach(); }, From 5a42a54da9518a204ba9451b4425fe7036b4cbfe Mon Sep 17 00:00:00 2001 From: lijuncheng Date: Tue, 30 Jul 2024 17:28:22 +0800 Subject: [PATCH 4/5] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=BF=BB=E5=8C=85?= =?UTF-8?q?=E6=89=93=E5=8D=B0=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/common/config.js | 2 + src/mycomponents/print/print.vue | 150 ++++++++++++++++++ src/pages/index/index.vue | 5 + src/pages/login/index.vue | 7 +- .../package/record/overPackageRecord.vue | 13 +- src/pages/setter/index.vue | 4 +- 6 files changed, 176 insertions(+), 5 deletions(-) create mode 100644 src/common/config.js create mode 100644 src/mycomponents/print/print.vue diff --git a/src/common/config.js b/src/common/config.js new file mode 100644 index 00000000..1288b666 --- /dev/null +++ b/src/common/config.js @@ -0,0 +1,2 @@ +export const overPagePrint="overPage_print" +export const overPageTemplate="overPage_Template" \ No newline at end of file diff --git a/src/mycomponents/print/print.vue b/src/mycomponents/print/print.vue new file mode 100644 index 00000000..f7e5439d --- /dev/null +++ b/src/mycomponents/print/print.vue @@ -0,0 +1,150 @@ + + + + + + + + diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue index ce10f123..bff5bd9a 100644 --- a/src/pages/index/index.vue +++ b/src/pages/index/index.vue @@ -77,6 +77,11 @@ getSwitchByCode, getBusinessType } from '@/api/request2.js'; + + import { + overPagePrint, + overPageTemplate + } from '@/common/config.js'; export default { components: {}, diff --git a/src/pages/login/index.vue b/src/pages/login/index.vue index 2206d6d9..20a86f20 100644 --- a/src/pages/login/index.vue +++ b/src/pages/login/index.vue @@ -97,6 +97,7 @@ import { getCaptchaImage } from '@/api/request2.js'; + import storage from '@/common/utils/storage' import { mapState, mapMutations @@ -124,8 +125,10 @@ // computed: mapState(['forcedLogin', 'hasLogin']), mounted() { this.tenantValue = this.tenantArray[0].value - uni.clearStorageSync() - uni.clearStorage(); //清除缓存 + // uni.clearStorageSync() + // uni.clearStorage(); //清除缓存 + + storage.clearStorage() if (process.env.NODE_ENV === 'development') { this.username = "admin" this.password = "win123456"; diff --git a/src/pages/package/record/overPackageRecord.vue b/src/pages/package/record/overPackageRecord.vue index dd5a5d24..e8872f30 100644 --- a/src/pages/package/record/overPackageRecord.vue +++ b/src/pages/package/record/overPackageRecord.vue @@ -4,6 +4,8 @@ + + @@ -110,7 +112,7 @@ import recordComDetailCard from '@/mycomponents/record/recordComDetailCard.vue' import packUnit from '@/mycomponents/qty/packUnit.vue' import winComScanBalance from '@/mycomponents/scan/winComScanBalance.vue' - + import print from '@/mycomponents/print/print.vue' import { getCurrDateTime @@ -128,7 +130,8 @@ packageTarget, recordComDetailCard, packUnit, - winComScanBalance + winComScanBalance, + print }, onLoad(option){ uni.setNavigationBarTitle({ @@ -235,6 +238,12 @@ }, getScanResult(result) { this.setData(result); + + setTimeout(res=>{ + + this.$res.printService.setDefaultData() + + }) }, setData(result) { diff --git a/src/pages/setter/index.vue b/src/pages/setter/index.vue index a8fb8437..a3e6a7e1 100644 --- a/src/pages/setter/index.vue +++ b/src/pages/setter/index.vue @@ -42,6 +42,8 @@ removeToken } from '@/common/utils/auth' + import storage from '@/common/utils/storage' + // #ifdef APP-PLUS import { appUpdate @@ -109,7 +111,7 @@ }; function clearStorage() { - uni.clearStorageSync() + storage.clearStorage() removeToken(); }; From d95b0fc036db280357246dc6ceeb7e1bd202ef52 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Tue, 30 Jul 2024 18:30:11 +0800 Subject: [PATCH 5/5] =?UTF-8?q?=E9=95=BF=E6=98=A5=E6=B5=B7=E6=8B=89?= =?UTF-8?q?=E6=B5=8B=E8=AF=95=E7=8E=AF=E5=A2=83PDA=E5=88=B6=E5=93=81?= =?UTF-8?q?=E5=9B=9E=E6=94=B6=E4=BB=BB=E5=8A=A1=E6=89=AB=E6=8F=8F=E7=AE=B1?= =?UTF-8?q?=E7=A0=81=E5=BC=B9=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/productRecycle/job/productRecycleJobDetail.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/src/pages/productRecycle/job/productRecycleJobDetail.vue b/src/pages/productRecycle/job/productRecycleJobDetail.vue index 0b9b7661..f42cacaa 100644 --- a/src/pages/productRecycle/job/productRecycleJobDetail.vue +++ b/src/pages/productRecycle/job/productRecycleJobDetail.vue @@ -273,6 +273,7 @@ }) if(itemDetail){ + let itemStatus = getInventoryStatusName(itemDetail.inventoryStatus); //箱码、批次、库位相等,状态不相等 if (this.jobContent.allowModifyInventoryStatus == "TRUE") { this.showQuestionMessage('实际库存状态[' + balanceStatus + ']与推荐库存状态[' + itemStatus +