diff --git a/src/common/basic.js b/src/common/basic.js index 3a7f4b54..8d1fb95d 100644 --- a/src/common/basic.js +++ b/src/common/basic.js @@ -878,6 +878,67 @@ export function getBatch8() { return year + month + day; } +/** + * 获取前几天和后几天的日期 2024-07-07 + */ +export function lastThreeDays(grapDay) { + let dates = []; + for (let i = grapDay; i >= 0; i--) { + // 创建新的Date对象,并减去i天 + let date = new Date(); + date.setDate(date.getDate() - i); + // 将格式化的日期字符串添加到数组中 + dates.push(formatDate(date)); + } + + for (let i = 0; i self.indexOf(item) === index); + return arr.filter((item, index, self) => self.indexOf(item) === index); } \ No newline at end of file diff --git a/src/mycomponents/detail/comDetailCard.vue b/src/mycomponents/detail/comDetailCard.vue index b15bb0fa..9a968002 100644 --- a/src/mycomponents/detail/comDetailCard.vue +++ b/src/mycomponents/detail/comDetailCard.vue @@ -107,14 +107,14 @@ }, mounted() { - // if (this.detailOptions.length == 0) { - // this.detailOptions = getDetailOption(); - // } - // if (this.scanOptions.length == 0) { - // this.scanOptions = getPurchaseReceiptOption(this.settingParam.allowModifyQty, false) - // } + if (this.detailOptions.length == 0) { + this.detailOptions = getDetailOption(); + } + if (this.scanOptions.length == 0) { + this.scanOptions = getPurchaseReceiptOption(this.settingParam.allowModifyQty, false) + } - this.showLocation(); + // this.showLocation(); }, methods: { diff --git a/src/mycomponents/job/jobFilter.vue b/src/mycomponents/job/jobFilter.vue index af91fa70..deeb70ad 100644 --- a/src/mycomponents/job/jobFilter.vue +++ b/src/mycomponents/job/jobFilter.vue @@ -59,7 +59,7 @@ import winScanAsnNumber from "@/mycomponents/scan/winScanAsnNumber.vue" export default { - emits: ["switchChangeToday", "switchChangeWait", "onScanNumber", "onScanAsnNumber","productionLineCode","fromLocationCode"], + emits: ["switchChangeToday", "switchChangeWait", "onScanNumber", "onScanAsnNumber","productionLineCode","fromLocationCode","fromLocationCodeConfirm"], components: { winScanJobNumber, winScanAsnNumber @@ -128,13 +128,8 @@ }, methods: { // 生产线 - productionLineCodeConfirm(){ - var lineCode="" - this.productionline.forEach(item=>{ - if(item.text==this.productionLineCode){ - lineCode=item.value - } - }) + productionLineCodeConfirm(e){ + var lineCode=e this.$emit("productionLineCode", lineCode) }, @@ -174,10 +169,12 @@ scanNumberClick() { this.$refs.scanNumber.openScanPopup(); + this.closeScanPopup(); }, scanOtherClick() { this.$refs.scanAsnNumber.openScanPopup(); + this.closeScanPopup(); }, getScanAsNumber(val) { diff --git a/src/mycomponents/scan/winScanItem.vue b/src/mycomponents/scan/winScanItem.vue index d0e7aae3..39dd7d31 100644 --- a/src/mycomponents/scan/winScanItem.vue +++ b/src/mycomponents/scan/winScanItem.vue @@ -83,11 +83,6 @@ closeScanPopup() { this.$refs.popup.close() }, - getfocus() { - if (this.isShow) { - this.$refs.scan.getfocus() - } - }, scanClick() { this.$refs.scan.clickScanMsg(); }, @@ -159,10 +154,14 @@ }) }, getfocus() { - this.$refs.scan.getfocus(); + if(this.$refs.scan){ + this.$refs.scan.getfocus(); + } }, losefocus() { - this.$refs.scan.losefocus(); + if(this.$refs.scan){ + this.$refs.scan.losefocus(); + } }, } diff --git a/src/pages.json b/src/pages.json index 3f08e9c1..4f875fc9 100644 --- a/src/pages.json +++ b/src/pages.json @@ -82,6 +82,36 @@ } } }, + + { + "path": "pages/query/pack", + "style": { + "enablePullDownRefresh": true, // 是否配置下拉刷新的功能 + "navigationBarTitleText": "按包装号查询库存", + "titleNView": { + // "autoBackButton": "true", + "buttons": [ + // 右边按钮 + { + + "float": "right", + "fontSize": "58rpx", //按钮上文字的大小 + "text": "\ue696", + "fontSrc": "/static/ali_icon/iconfont.ttf" + + }, + { + + "float": "right", + "fontSize": "52rpx", //按钮上文字的大小 + "text": "\ue6e2", + "fontSrc": "/static/ali_icon/iconfont.ttf" + } + ] + } + } + }, + { "path": "pages/query/location", "style": { diff --git a/src/pages/fg/coms/comReceiptPopup.vue b/src/pages/fg/coms/comReceiptPopup.vue index f6ad6dfd..6a018045 100644 --- a/src/pages/fg/coms/comReceiptPopup.vue +++ b/src/pages/fg/coms/comReceiptPopup.vue @@ -29,7 +29,21 @@ - + + 计划日期: + + {{planDate}} + + + + + + + + + 物料代码: @@ -45,17 +59,7 @@ - - - - 批次: - - - - - - + + + + + + \ No newline at end of file