diff --git a/src/api/request2.js b/src/api/request2.js index b4cce1fa..c25d17c1 100644 --- a/src/api/request2.js +++ b/src/api/request2.js @@ -1895,6 +1895,7 @@ export function getProductReceiptJobList(params) { }); } + /** * 制品收货 获取任务明细 * @param {*} id 任务id diff --git a/src/common/style/new_style.css b/src/common/style/new_style.css index 9516a3f7..adf36fbc 100644 --- a/src/common/style/new_style.css +++ b/src/common/style/new_style.css @@ -2077,22 +2077,11 @@ button::after { padding: 5px; } -.card_packing_code_content { - font-size: 32rpx; - padding: 5px; -} - .card_batch { color: #9747FF; padding: 5px; } - -.card_batch_content { - font-size: 32rpx; - padding: 5px; -} - .card_container { color: #0076F6; padding: 5px; @@ -2131,12 +2120,28 @@ button::after { .card_supportCode { color: #DA8910; + padding: 5px; } .card_supportCode_content { font-size: 32rpx; } +.card_item_code { + color: #F1A532; + padding: 5px; +} + +.card_product_date { + color: #329362; + padding: 5px; +} + +.card_order { + color: #0076F6; + padding: 5px; +} + .scan_view { /* #0CC2B6 20% */ background: linear-gradient(90deg, rgba(12, 194, 182, 0.2) 0%, rgba(12, 194, 182, 0) 100%) diff --git a/src/mycomponents/scan/winComScanFG.vue b/src/mycomponents/scan/winComScanFG.vue new file mode 100644 index 00000000..d6e2628e --- /dev/null +++ b/src/mycomponents/scan/winComScanFG.vue @@ -0,0 +1,263 @@ + + + + + + + \ No newline at end of file diff --git a/src/mycomponents/scan/winScanFGLabel.vue b/src/mycomponents/scan/winScanFGLabel.vue new file mode 100644 index 00000000..30ba9746 --- /dev/null +++ b/src/mycomponents/scan/winScanFGLabel.vue @@ -0,0 +1,114 @@ + + + + + \ No newline at end of file diff --git a/src/pages.json b/src/pages.json index e60e9da7..79b15b87 100644 --- a/src/pages.json +++ b/src/pages.json @@ -821,7 +821,7 @@ { "path": "pages/productReceipt/job/fgProductReceiptJob", "style": { - "navigationBarTitleText": "装配完工收货任务", + "navigationBarTitleText": "装配收货任务", "enablePullDownRefresh": true, "titleNView": { // "autoBackButton": "true", @@ -847,14 +847,14 @@ { "path": "pages/productReceipt/job/fgProductReceiptDetail", "style": { - "navigationBarTitleText": "装配完工收货详情", + "navigationBarTitleText": "装配收货详情", "enablePullDownRefresh": false } }, { "path": "pages/productReceipt/job/semiProductReceiptJob", "style": { - "navigationBarTitleText": "预生产完工收货任务", + "navigationBarTitleText": "预生产收货任务", "enablePullDownRefresh": true, "titleNView": { // "autoBackButton": "true", diff --git a/src/pages/productReceipt/coms/comFgCard.vue b/src/pages/productReceipt/coms/comFgCard.vue new file mode 100644 index 00000000..3f6ce428 --- /dev/null +++ b/src/pages/productReceipt/coms/comFgCard.vue @@ -0,0 +1,62 @@ + + + + + \ No newline at end of file diff --git a/src/pages/productReceipt/coms/comProductDetailCard.vue b/src/pages/productReceipt/coms/comProductDetailCard.vue index 0f22e954..b9ca0dc1 100644 --- a/src/pages/productReceipt/coms/comProductDetailCard.vue +++ b/src/pages/productReceipt/coms/comProductDetailCard.vue @@ -5,21 +5,20 @@ - + - + - - + @@ -35,7 +34,7 @@ import jobDetailPopup from '@/mycomponents/detail/jobDetailPopup.vue' import productDetailInfoPopup from '@/pages/productReceipt/coms/productDetailInfoPopup.vue' import winScanLocation from "@/mycomponents/scan/winScanLocation.vue" - + import { getDetailOption, getPurchaseReceiptOption @@ -63,8 +62,8 @@ type: Array, default: null }, - - + + }, watch: { dataContent: { @@ -90,7 +89,7 @@ } }, - locatonItem:{}, + locatonItem: {}, detailOptions: [], scanOptions: [] } @@ -101,7 +100,8 @@ this.detailOptions = getDetailOption(); } if (this.scanOptions.length == 0) { - this.scanOptions = getPurchaseReceiptOption(this.settingParam.allowModifyQty,this.settingParam.allowModifyLocation) + this.scanOptions = getPurchaseReceiptOption(this.settingParam.allowModifyQty, this.settingParam + .allowModifyLocation) } }, @@ -111,7 +111,7 @@ this.detail(item) } else if (e.content.text == "编辑") { this.edit(item) - } else if (e.content.text == "库位") { + } else if (e.content.text == "库位") { this.showLocation(item) } else if (e.content.text == "移除") { this.remove(item) @@ -119,15 +119,15 @@ }, edit(item) { this.editItem = item; - this.$refs.receiptEdit.openTaskEditPopup(item.qty, item.handleQty,item.labelQty); + this.$refs.receiptEdit.openTaskEditPopup(item.qty, item.handleQty, item.labelQty); }, showLocation(item) { - this.locatonItem =item; + this.locatonItem = item; this.$refs.scanLocationCode.openScanPopup(); }, //扫描源库位 getLocation(location, code) { - this.locatonItem.toLocationCode =code; + this.locatonItem.toLocationCode = code; this.$emit('updateData') }, @@ -155,4 +155,4 @@ + \ No newline at end of file diff --git a/src/pages/productReceipt/job/FgProductReceiptDetail.vue b/src/pages/productReceipt/job/FgProductReceiptDetail.vue index 6759a483..230afd1e 100644 --- a/src/pages/productReceipt/job/FgProductReceiptDetail.vue +++ b/src/pages/productReceipt/job/FgProductReceiptDetail.vue @@ -14,11 +14,15 @@ - - + + + + - + @@ -27,8 +31,8 @@ - @@ -38,7 +42,7 @@ - + @@ -75,11 +79,11 @@ import winScanButton from '@/mycomponents/scan/winScanButton.vue' import locationCompare from '@/mycomponents/location/locationCompare.vue' - import winScanPack from "@/mycomponents/scan/winScanPack.vue" + import winScanFgLabel from "@/mycomponents/scan/winScanFgLabel.vue" import comDetailCard from "@/mycomponents/detail/comDetailCard.vue" import jobTop from '@/mycomponents/job/jobTop.vue' import comProductDetailCard from "@/pages/productReceipt/coms/comProductDetailCard.vue" - + import comFgCard from "@/pages/productReceipt/coms/comFgCard.vue" export default { name: 'receipt_detail', @@ -87,9 +91,10 @@ winScanButton, comDetailCard, locationCompare, - winScanPack, + winScanFgLabel, jobTop, - comProductDetailCard + comProductDetailCard, + comFgCard }, data() { return { @@ -103,9 +108,9 @@ detailSource: [], //绑定在页面上的数据源 toLocationTypeList: [], managementList: [], - jobStatus:"", - jobToLocationCode:"" - + jobStatus: "", + jobToLocationCode: "", + fgList: [] }; }, onLoad(option) { @@ -132,7 +137,7 @@ onBackPress(e) { //已经接收但是没提交任务 if (e.from == 'backbutton') { - if (this.jobStatus=="2") { + if (this.jobStatus == "2") { //取消承接任务 cancleTakeProductReceiptJob(this.id).then(res => { uni.navigateBack(); @@ -197,36 +202,8 @@ }, getScanResult(result) { - let label = result.label; - var packingNumber = label.packingNumber; - var batch = label.batch; - var qty = label.qty; - var itemCode = label.itemCode; - - var detail = this.detailSource.find(r => r.itemCode == itemCode); - if (detail == undefined) { - this.showErrorMessage("物料号【" + itemCode + "】不在列表中") - } else { - var itemDetail = detail.subList.find(r => - r.packingNumber == packingNumber && - r.batch == batch); - if (itemDetail == undefined) { - this.showErrorMessage("箱码[" + packingNumber + "]" + "批次[" + batch + "]不在任务列表中") - } else { - if (itemDetail.scaned) { - this.showErrorMessage("箱码[" + packingNumber + "]" + "批次[" + batch + "]已经扫描") - } else { - itemDetail.scaned = true; - itemDetail.handleQty = Number(result.label.qty); - itemDetail.toLocationCode = this.toLocationCode; - itemDetail.labelQty = Number(result.label.qty); - calcHandleQty(this.detailSource); - this.continueScan() - this.$forceUpdate() - } - - } - } + let source = that.detailSource; + this.fgList.push(result); }, //继续扫描 @@ -415,4 +392,4 @@ + \ No newline at end of file diff --git a/src/pages/productReceipt/job/FgProductReceiptJob.vue b/src/pages/productReceipt/job/FgProductReceiptJob.vue index c5e524a7..8fd0dd95 100644 --- a/src/pages/productReceipt/job/FgProductReceiptJob.vue +++ b/src/pages/productReceipt/job/FgProductReceiptJob.vue @@ -1,287 +1,33 @@ + \ No newline at end of file diff --git a/src/pages/productReceipt/job/SemiProductReceiptJob.vue b/src/pages/productReceipt/job/SemiProductReceiptJob.vue index c5e524a7..87dcbb32 100644 --- a/src/pages/productReceipt/job/SemiProductReceiptJob.vue +++ b/src/pages/productReceipt/job/SemiProductReceiptJob.vue @@ -1,287 +1,33 @@ + \ No newline at end of file diff --git a/src/pages/productReceipt/job/productReceiptJob.vue b/src/pages/productReceipt/job/productReceiptJob.vue index c047a1ba..6e83cdda 100644 --- a/src/pages/productReceipt/job/productReceiptJob.vue +++ b/src/pages/productReceipt/job/productReceiptJob.vue @@ -5,12 +5,11 @@ @switchChangeWait="switchChangeWait" @onScanNumber="getScanNumber" :checkedToday="checkedToday" :checkedWaitTask="checkedWaitTask"> - + - @@ -73,16 +72,17 @@ detailGiveupOptions: [], }; }, - - onShow() { - this.getList("refresh") + // 装配收货:type = 'assemble' + // 预生产收货:type = 'predict' + props: { + type: 'assemble', }, onReady() { this.detailOptions = getDetailOption(); this.detailGiveupOptions = getDetailGiveupOption(); }, - + onReachBottom() { //避免多次触发 if (this.loadingType == 'loading' || this.loadingType == 'nomore') { @@ -90,7 +90,7 @@ } this.getList("more"); }, - + onPullDownRefresh() { this.getList('refresh'); }, @@ -135,27 +135,33 @@ value: this.todayTime }) } - + filters.push({ column: "status", action: "in", value: this.status }) - + var params = { filters: filters, pageNo: this.pageNo, pageSize: this.pageSize, + type: this.type } + getProductReceiptJobList(params).then(res => { uni.hideLoading(); if (type === "refresh") { uni.stopPullDownRefresh(); } - + var list = res.data.list; this.totalCount = res.data.total - updateTitle("制品收货(" + this.totalCount + ")"); + if (this.type == 'predict') { + updateTitle("预生产收货任务(" + this.totalCount + ")"); + } else { + updateTitle("装配收货任务(" + this.totalCount + ")"); + } this.loadingType = "loadmore"; if (list == null || list.length == 0) { this.loadingType = "nomore"; @@ -163,13 +169,17 @@ } this.jobList = type === "refresh" ? list : this.jobList.concat(list); this.pageNo++; - + }).catch(error => { if (type === "refresh") { uni.stopPullDownRefresh(); } - updateTitle("制品收货"); + if (this.type == 'predict') { + updateTitle("预生产收货任务(" + this.totalCount + ")"); + } else { + updateTitle("装配收货任务(" + this.totalCount + ")"); + } this.loadingType = ""; uni.hideLoading(); that.showMessage(error) @@ -177,9 +187,15 @@ }, openJobDetail(item) { - uni.navigateTo({ - url: './productReceiptDetail?id=' + item.id + '&status=' + item.status - }); + if (this.type == 'predict') { + uni.navigateTo({ + url: './productReceiptDetail?id=' + item.id + '&status=' + item.status + }); + } else { + uni.navigateTo({ + url: './fgProductReceiptDetail?id=' + item.id + '&status=' + item.status + }); + } }, showItemList(itemList) { @@ -209,12 +225,12 @@ cancleJob(id) { cancleTakeProductReceiptJob(id).then(res => { - if(res.data){ + if (res.data) { this.getList("refresh") uni.showToast({ - title:"放弃任务成功" + title: "放弃任务成功" }) - }else { + } else { this.showMessage("放弃任务失败") } }).catch(error => { @@ -253,7 +269,7 @@ action: "==", value: code }) - + var params = { filters: filters, pageNo: 1, @@ -285,4 +301,4 @@ + \ No newline at end of file