From ccafc677b2a9fdc2d335d803cc81320dd6eb2685 Mon Sep 17 00:00:00 2001 From: "LAPTOP-R6EHHS26\\86155" <2217640373@qq.com> Date: Tue, 24 Oct 2023 16:03:11 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=A1=B5=E9=9D=A2=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/equipment/Inspection/details.vue | 96 +-- .../equipment/Inspection/detailsview.vue | 47 +- src/pages/equipment/Inspection/index.vue | 28 +- src/pages/equipment/Inspection/model.ts | 4 +- src/pages/equipment/Spotcheck/details.vue | 588 +++++++++++++++++ src/pages/equipment/Spotcheck/detailsview.vue | 608 ++++++++++++++++++ src/pages/equipment/Spotcheck/index.vue | 316 ++++----- 7 files changed, 1422 insertions(+), 265 deletions(-) create mode 100644 src/pages/equipment/Spotcheck/details.vue create mode 100644 src/pages/equipment/Spotcheck/detailsview.vue diff --git a/src/pages/equipment/Inspection/details.vue b/src/pages/equipment/Inspection/details.vue index c292a5c..d92b61e 100644 --- a/src/pages/equipment/Inspection/details.vue +++ b/src/pages/equipment/Inspection/details.vue @@ -9,21 +9,22 @@ -
巡检任务: 巡检任务1
- + +
+
巡检任务: 巡检任务1
-
设备编码: {{ item.itemq }}
-
设备名称: {{ item.itemq }}
+
设备编码: {{ detailsinfo.itemq }}
+
设备名称: {{ detailsinfo.itemq }}
-
车间: {{ item.itemq }}
-
产线: {{ item.itemq }}
+
车间: {{ detailsinfo.itemq }}
+
产线: {{ detailsinfo.itemq }}
- + @@ -121,7 +122,7 @@ export default class ChangePalletNew extends BasePage { // 设备信息 equipmentdata: any = [ { - itemq: '巡检任务1', + itemq: '测试设备1', item2: '已巡检', item3: '2023-08-01 - 2023-08-31', item4: '每月巡检', @@ -133,37 +134,41 @@ export default class ChangePalletNew extends BasePage { imgUrlList2: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg'], listselect: [ { + type: 1, name: '符合标准', + radiovalue: null, }, { + type: 2, name: '未达标', + radiovalue: null, }, ], valuemax: 100, valuemin: 50, }, - { - itemq: '巡检任务2', - item2: '已巡检', - item3: '2023-08-01 - 2023-08-31', - item4: '每月巡检', - item5: 'XXXXX', - item6: '未发现异常', - radiovalue: '符合标准', - value: 10, - imgUrlList1: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg', 'https://cdn.uviewui.com/uview/swiper/3.jpg'], - imgUrlList2: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg'], - listselect: [ - { - name: '符合标准', - }, - { - name: '未达标', - }, - ], - valuemax: 50, - valuemin: 10, - }, + // { + // itemq: '测试设备2', + // item2: '已巡检', + // item3: '2023-08-01 - 2023-08-31', + // item4: '每月巡检', + // item5: 'XXXXX', + // item6: '未发现异常', + // radiovalue: '符合标准', + // value: 10, + // imgUrlList1: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg', 'https://cdn.uviewui.com/uview/swiper/3.jpg'], + // imgUrlList2: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg'], + // listselect: [ + // { + // name: '符合标准', + // }, + // { + // name: '未达标', + // }, + // ], + // valuemax: 50, + // valuemin: 10, + // }, ]; // 设备index equipment equipmentindex: any = ''; @@ -225,9 +230,6 @@ export default class ChangePalletNew extends BasePage { if (str) { this.detailsinfo = JSON.parse(str); this.detailsinfolist.push(this.detailsinfo); - setTimeout(() => { - this.detailsinfolist.push(JSON.parse(str)); - }, 1000); console.log(this.detailsinfo); } } @@ -349,8 +351,8 @@ export default class ChangePalletNew extends BasePage { // return; // } } - search(item, value, index) { - console.log(item, value, index); + search(value) { + console.log(value); } } @@ -392,18 +394,6 @@ export default class ChangePalletNew extends BasePage { height: 88rpx; } } - .quest { - width: 367px; - border-radius: 5px; - border: rgba(121, 121, 121, 1) solid 1px; - background-color: #f2f2f2; - padding: 7px 8px 7px 12px; - box-sizing: border-box; - text-align: center; - font-size: 18px; - font-weight: 600; - color: black; - } .list { margin-top: 15px; @@ -414,6 +404,18 @@ export default class ChangePalletNew extends BasePage { padding: 7px 8px 7px 12px; box-sizing: border-box; .item-name { + .quest { + // width: 367px; + // border-radius: 5px; + // border: rgba(121, 121, 121, 1) solid 1px; + // background-color: #f2f2f2; + padding: 7px 8px 7px 12px; + box-sizing: border-box; + text-align: center; + font-size: 18px; + font-weight: 600; + color: black; + } .details { display: flex; font-size: 16px; diff --git a/src/pages/equipment/Inspection/detailsview.vue b/src/pages/equipment/Inspection/detailsview.vue index bb5a277..3442293 100644 --- a/src/pages/equipment/Inspection/detailsview.vue +++ b/src/pages/equipment/Inspection/detailsview.vue @@ -8,22 +8,22 @@ 巡检详情 -
巡检任务: 巡检任务1
- +
+
巡检任务: 巡检任务1
-
设备编码: {{ item.itemq }}
-
设备名称: {{ item.itemq }}
+
设备编码: {{ detailsinfo.itemq }}
+
设备名称: {{ detailsinfo.itemq }}
-
车间: {{ item.itemq }}
-
产线: {{ item.itemq }}
+
车间: {{ detailsinfo.itemq }}
+
产线: {{ detailsinfo.itemq }}
- + @@ -43,7 +43,7 @@
检查标准: {{ item.item5 }}
实际值: - + 单位:mm
@@ -130,6 +130,7 @@ export default class ChangePalletNew extends BasePage { item6: '未发现异常', radiovalue: '符合标准', value: 55, + isdisabled: true, imgUrlList1: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg', 'https://cdn.uviewui.com/uview/swiper/3.jpg'], imgUrlList2: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg'], listselect: [ @@ -153,6 +154,7 @@ export default class ChangePalletNew extends BasePage { item5: 'XXXXX', item6: '未发现异常', radiovalue: '符合标准', + isdisabled: true, value: 10, imgUrlList1: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg', 'https://cdn.uviewui.com/uview/swiper/3.jpg'], imgUrlList2: ['https://cdn.uviewui.com/uview/swiper/1.jpg', 'https://cdn.uviewui.com/uview/swiper/2.jpg'], @@ -230,11 +232,6 @@ export default class ChangePalletNew extends BasePage { if (str) { this.detailsinfo = JSON.parse(str); this.ischecked = this.detailsinfo.ischecked; - this.detailsinfolist.push(this.detailsinfo); - - setTimeout(() => { - this.detailsinfolist.push(this.detailsinfo); - }, 1000); console.log(this.detailsinfo); } } @@ -396,18 +393,6 @@ export default class ChangePalletNew extends BasePage { height: 88rpx; } } - .quest { - width: 367px; - border-radius: 5px; - border: rgba(121, 121, 121, 1) solid 1px; - background-color: #f2f2f2; - padding: 7px 8px 7px 12px; - box-sizing: border-box; - text-align: center; - font-size: 18px; - font-weight: 600; - color: black; - } .list { margin-top: 15px; width: 367px; @@ -417,6 +402,18 @@ export default class ChangePalletNew extends BasePage { padding: 7px 8px 7px 12px; box-sizing: border-box; .item-name { + .quest { + // width: 367px; + // border-radius: 5px; + // border: rgba(121, 121, 121, 1) solid 1px; + // background-color: #f2f2f2; + padding: 7px 8px 7px 12px; + box-sizing: border-box; + text-align: center; + font-size: 18px; + font-weight: 600; + color: black; + } .details { display: flex; font-size: 16px; diff --git a/src/pages/equipment/Inspection/index.vue b/src/pages/equipment/Inspection/index.vue index 5a10c10..f148620 100644 --- a/src/pages/equipment/Inspection/index.vue +++ b/src/pages/equipment/Inspection/index.vue @@ -87,12 +87,16 @@ export default class ChangePalletNew extends BasePage { item10: '产线1', }, { - itemq: '今日任务', - item2: '今日任务', - item3: '今日任务', - item4: '今日任务', - item5: '今日任务', - item6: '今日任务', + itemq: '巡检任务2', + item2: '未巡检', + item3: '2023-08-01 - 2023-08-31', + item4: '每月巡检', + item5: 'XXXXX', + item6: '未发现异常', + item7: 'AF-0002', + item8: '测试设备1', + item9: '车间1', + item10: '产线1', }, ]; detailsdata: any = [ @@ -105,12 +109,12 @@ export default class ChangePalletNew extends BasePage { item6: '未发现异常', }, { - itemq: '今日任务', - item2: '今日任务', - item3: '今日任务', - item4: '今日任务', - item5: '今日任务', - item6: '今日任务', + itemq: '巡检任务1', + item2: '已巡检', + item3: '2023-08-01 - 2023-08-31', + item4: '每月巡检', + item5: 'XXXXX', + item6: '未发现异常', }, ]; orderNoItemList: any = {}; diff --git a/src/pages/equipment/Inspection/model.ts b/src/pages/equipment/Inspection/model.ts index bc9ef01..681d80b 100644 --- a/src/pages/equipment/Inspection/model.ts +++ b/src/pages/equipment/Inspection/model.ts @@ -36,7 +36,7 @@ export class ChangePalletNew extends VuexModule { const SubmitCode = result.code; return { SubmitCode }; } - //库位下拉列表 + //巡检列表今日任务 DictList: any = []; @MutationAction async getpalletLocation(params) { @@ -52,7 +52,7 @@ export class ChangePalletNew extends VuexModule { return { DictList }; } } - //缓存区下拉列表 + //巡检列表巡检记录 locList: any = []; @MutationAction async getDictList() { diff --git a/src/pages/equipment/Spotcheck/details.vue b/src/pages/equipment/Spotcheck/details.vue new file mode 100644 index 0000000..38a8599 --- /dev/null +++ b/src/pages/equipment/Spotcheck/details.vue @@ -0,0 +1,588 @@ + + + + diff --git a/src/pages/equipment/Spotcheck/detailsview.vue b/src/pages/equipment/Spotcheck/detailsview.vue new file mode 100644 index 0000000..3442293 --- /dev/null +++ b/src/pages/equipment/Spotcheck/detailsview.vue @@ -0,0 +1,608 @@ + + + + diff --git a/src/pages/equipment/Spotcheck/index.vue b/src/pages/equipment/Spotcheck/index.vue index cb41751..6a16c6f 100644 --- a/src/pages/equipment/Spotcheck/index.vue +++ b/src/pages/equipment/Spotcheck/index.vue @@ -5,59 +5,32 @@ - 托盘变更 + 点检
- - - - - rfid: - - - - 查询 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 确定 - - - - 返回 - - + + +
+
{{ item.itemq }}
+
{{ item.item2 }}
+ +
+
任务期限: {{ item.item3 }}
+
周期: {{ item.item4 }}
+
设备名称: {{ item.item5 }}
+
存在异常: {{ item.item6 }}
+
+ + +
+
{{ item.itemq }}
+
{{ item.item2 }}
+ +
+
任务期限: {{ item.item3 }}
+
周期: {{ item.item4 }}
+
设备名称: {{ item.item5 }}
+
存在异常: {{ item.item6 }}
@@ -77,9 +50,19 @@ import jPicker from '@/components/J-Picker/jPicker.vue'; }) export default class ChangePalletNew extends BasePage { model = model; + list: any = [ + { + cate_name: '待处理', + }, + { + cate_name: '点检记录', + }, + ]; + current: any = 0; moren = '选择缓存区'; shouciFocus = true; zaiciFocus = false; + ischecked = false; switchListText = [ { title: '是', @@ -90,6 +73,46 @@ export default class ChangePalletNew extends BasePage { value: 1, }, ]; + listdata: any = [ + { + itemq: '点检任务1', + item2: '未点检', + item3: '2023-08-01 - 2023-08-31', + item4: '每月点检', + item5: 'XXXXX', + item6: '未发现异常', + item7: 'AF-0002', + item8: '测试设备1', + item9: '车间1', + item10: '产线1', + }, + { + itemq: '今日任务', + item2: '今日任务', + item3: '今日任务', + item4: '今日任务', + item5: '今日任务', + item6: '今日任务', + }, + ]; + detailsdata: any = [ + { + itemq: '点检任务1', + item2: '已点检', + item3: '2023-08-01 - 2023-08-31', + item4: '每月点检', + item5: 'XXXXX', + item6: '未发现异常', + }, + { + itemq: '今日任务', + item2: '今日任务', + item3: '今日任务', + item4: '今日任务', + item5: '今日任务', + item6: '今日任务', + }, + ]; orderNoItemList: any = {}; productCodeList: any = {}; productCodelocList: any = {}; @@ -105,85 +128,23 @@ export default class ChangePalletNew extends BasePage { orderNo: any = ''; location: any = ''; locationStatus: any = 1; - async query() { - if (this.orderNo == '' || this.orderNo.length == 0) { - this.customToast('请输入nficl'); - return; - } - await this.model.queryOrderNo(this.orderNo); - //console.log('???',model.orderNoItemList) - if (model.orderNoItemList == undefined) { - this.customToast('该rfid未查到数据,请使用正确的rfid!'); - } else { - this.orderNoItemList = model.orderNoItemList; - } - //console.log('this.orderNoItemList', this.orderNoItemList); + // + change(index) { + this.current = index; + console.log(this.current); } - generateGUID() { - return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) { - var r = (Math.random() * 16) | 0, - v = c === 'x' ? r : (r & 0x3) | 0x8; - return v.toString(16); + linkdetails(item) { + uni.navigateTo({ + url: `/pages/equipment/Spotcheck/details?listitem=` + encodeURIComponent(JSON.stringify(item)), }); } - async onsubmit() { - if (this.orderNo == '' || this.orderNo.length == 0) { - this.customToast('请输入nficl'); - return; - } - var currentDate = new Date(); - - // 获取年份、月份、日期、小时、分钟和秒 - var year = currentDate.getFullYear(); - var month = ('0' + (currentDate.getMonth() + 1)).slice(-2); - var day = ('0' + currentDate.getDate()).slice(-2); - var hours = ('0' + currentDate.getHours()).slice(-2); - var minutes = ('0' + currentDate.getMinutes()).slice(-2); - var seconds = ('0' + currentDate.getSeconds()).slice(-2); - - // 格式化为 "YYYY-MM-DD HH:mm:ss" 结构 - var formattedDate = year + '-' + month + '-' + day + ' ' + hours + ':' + minutes + ':' + seconds; - let params = { - rfidNo: this.orderNo, - reqCode: this.generateGUID(), - reqTime: formattedDate, - sku: this.orderNoItemList.productCode, - spec: this.orderNoItemList.productSpc, - productionState: this.productCodelocList.value, //缓存区:2或者3,成品2,烘房3 - //location: this.location, - locationStatus: this.locationStatus, //是否取走托盘 - location: this.productCodeList.value, //库位,其中 库位是根据选择的缓存区来查询的 - //productionState: this.productCodeList.value, - }; - await this.model.palletInforUpdate(params); - if (model.SubmitCode == 10) { - this.uni.showToast({ title: '成功' }); - this.Clear(); - } - } - Clear() { - this.orderNo = ''; - this.location = ''; - this.locationStatus = 1; - this.productCodeList = {}; - this.productCodelocList = {}; - this.shouciFocus = false; - this.model.empty(); - this.$nextTick(() => { - this.shouciFocus = true; + linkdetailscheck(item) { + this.ischecked = true; + item.ischecked = true; + uni.navigateTo({ + url: `/pages/equipment/Spotcheck/detailsview?listitem=` + encodeURIComponent(JSON.stringify(item)), }); } - switchChangeFun(e) { - //console.log(e); - this.locationStatus = e.swithcSelectItem.value; - } - async selectProductCode(e: any) { - this.productCodeList = e.pickerName; - } - async selectProductlocCode(e: any) { - this.productCodelocList = e.pickerName; - await this.model.getpalletLocation(this.productCodelocList.value); //参数:成型区2,烘房3 - } }