From 1fbc85cdb1eb213366a28faf3fd936257b660f35 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 29 Feb 2024 16:48:45 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A3=80=E4=BF=AE=E5=B7=A5=E5=8D=95=E7=82=B9?= =?UTF-8?q?=E6=A3=80=E5=B7=A5=E5=8D=95=EF=BC=8C=E4=BF=9D=E5=85=BB=E5=B7=A5?= =?UTF-8?q?=E5=8D=95,=E9=A2=86=E7=94=A8=E7=94=B3=E8=AF=B7=EF=BC=8C?= =?UTF-8?q?=E9=A2=86=E7=94=A8=E7=94=B3=E8=AF=B7=E5=AE=A1=E6=89=B9=EF=BC=8C?= =?UTF-8?q?=E5=A4=87=E4=BB=B6=E7=BB=B4=E4=BF=AE=E5=B7=A5=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages.json | 7 + src/pages/deviceReport/addForm.vue | 2 +- src/pages/deviceReport/index.vue | 49 ++--- src/pages/deviceReport/myDeviceReport.vue | 56 ++++-- src/pages/index.vue | 16 +- src/pages/mine/index.vue | 12 +- src/pages/mold/index.vue | 18 ++ src/pages/overhaulOrder/addForm.vue | 14 +- src/pages/overhaulOrder/addServiceRecord.vue | 14 +- src/pages/overhaulOrder/detail.vue | 50 ++--- src/pages/overhaulOrder/index.vue | 2 +- src/pages/repairOrder/addForm.vue | 8 +- src/pages/repairOrder/addServiceRecord.vue | 2 +- src/pages/repairOrder/detail.vue | 7 +- src/pages/repairOrder/myOrder.vue | 7 +- src/pages/repairOrder/transfer.vue | 8 +- src/pages/spareParts/index.vue | 67 ++++--- src/pages/sparePartsApplication/addForm.vue | 4 +- src/pages/sparePartsApplication/detail.vue | 7 +- .../mySparePartsApplication.vue | 16 -- .../mySparePartsApplicationApprove.vue | 171 ++++++++++++++++++ .../addForm.vue | 14 +- src/pages/spotCheckOrder/addForm.vue | 10 +- src/pages/upkeepOrder/addServiceRecord.vue | 30 +-- src/pages/upkeepOrder/detail.vue | 83 ++++----- src/pages/upkeepOrder/myOrder.vue | 3 + src/permission.js | 2 +- src/static/images/banner/icon7.png | Bin 0 -> 24795 bytes src/static/images/icon6.png | Bin 22827 -> 23264 bytes src/static/images/icon7.png | Bin 0 -> 22004 bytes 30 files changed, 455 insertions(+), 224 deletions(-) create mode 100644 src/pages/sparePartsApplicationApprove/mySparePartsApplicationApprove.vue create mode 100644 src/static/images/banner/icon7.png create mode 100644 src/static/images/icon7.png diff --git a/src/pages.json b/src/pages.json index b77cd12..66f3a32 100644 --- a/src/pages.json +++ b/src/pages.json @@ -217,6 +217,13 @@ "navigationStyle": "custom", "navigationBarTextStyle": "white" } + },{ + "path": "pages/sparePartsApplicationApprove/mySparePartsApplicationApprove", + "style": { + "navigationBarTitleText": "我的领用审批", + "navigationBarBackgroundColor": "#409eff", + "navigationBarTextStyle": "white" + } },{ "path": "pages/mine/agreement", "style": { diff --git a/src/pages/deviceReport/addForm.vue b/src/pages/deviceReport/addForm.vue index 8129005..2083ad4 100644 --- a/src/pages/deviceReport/addForm.vue +++ b/src/pages/deviceReport/addForm.vue @@ -60,7 +60,7 @@ + :list="singleColumnList" @confirm="chooseSingleColumn" @cancle='singleColumnShow = false'> diff --git a/src/pages/deviceReport/index.vue b/src/pages/deviceReport/index.vue index f920cc1..c6f7c22 100644 --- a/src/pages/deviceReport/index.vue +++ b/src/pages/deviceReport/index.vue @@ -33,14 +33,15 @@ 所属厂区:{{item.factoryAreaName}} - + - + - + 所属厂区:{{item.factoryAreaName}} + + + - + - + - - - + + + @@ -54,7 +58,7 @@ params: { pageNo: 1, pageSize: 10, - flag:1 + flag: 1 }, status: 'loadmore', //是否显示没有更多了 list: [], @@ -84,8 +88,8 @@ }) }, // 撤销 - cancle(item){ - this.$modal.confirm('确定撤销报修吗?').then(()=>{ + cancle(item) { + this.$modal.confirm('确定撤销报修吗?').then(() => { deviceApi.rejected(item.id).then((res) => { this.params.pageNo = 1 this.list = [] @@ -93,7 +97,22 @@ this.getList() }) }) - + + }, + previewImage(current, array) { + uni.previewImage({ + urls: array, + current: current, + longPressActions: { + itemList: ['发送给朋友', '保存图片', '收藏'], + success: function(data) { + console.log('选中了第' + (data.tapIndex + 1) + '个按钮,第' + (data.index + 1) + '张图片'); + }, + fail: function(err) { + console.log(err.errMsg); + } + } + }); } }, onShow() { @@ -155,7 +174,7 @@ border-top: 1px solid #E4E4E4; padding: 20rpx 0px; height: 90rpx; - + } } } @@ -211,7 +230,8 @@ .status { flex: 1; } - .button{ + + .button { position: absolute; right: 0rpx; } @@ -219,4 +239,16 @@ } } } + + .images { + display: flex; + width: 100%; + + image { + width: 30%; + margin-right: 20rpx; + height: 200rpx; + border-radius: 10rpx; + } + } \ No newline at end of file diff --git a/src/pages/index.vue b/src/pages/index.vue index 2e8882f..ebc0e70 100644 --- a/src/pages/index.vue +++ b/src/pages/index.vue @@ -102,7 +102,7 @@ - + 保养工单 @@ -111,16 +111,16 @@ 备件管理 - - + + - 领用申请审批 + 领用申请 - - - - 领用申请 + + + + 领用申请审批 diff --git a/src/pages/mine/index.vue b/src/pages/mine/index.vue index 4205dac..c0963c3 100644 --- a/src/pages/mine/index.vue +++ b/src/pages/mine/index.vue @@ -45,14 +45,14 @@ 巡检点检 - - - 领用审批 - - + 我的领用 + + + 领用审批 + 备件维修 @@ -145,7 +145,7 @@ this.$tab.navigateTo('/pages/sparePartsApplication/mySparePartsApplication?flag=1') }, handleSparePartsApplicationApprove(){ - this.$tab.navigateTo('/pages/sparePartsApplication/mySparePartsApplication?flag=2') + this.$tab.navigateTo('/pages/sparePartsApplicationApprove/mySparePartsApplicationApprove?flag=1') }, handleSparePartsService(){ this.$tab.navigateTo('/pages/sparePartsServiceWorkOrderList/mySparePartsService') diff --git a/src/pages/mold/index.vue b/src/pages/mold/index.vue index 4fcf0c9..7e1bfb3 100644 --- a/src/pages/mold/index.vue +++ b/src/pages/mold/index.vue @@ -1,7 +1,12 @@ @@ -51,6 +57,7 @@ }, status: 'loadmore', //是否显示没有更多了 list: [], + token:'' } }, methods: { @@ -85,6 +92,7 @@ }, onShow() { if (getAccessToken()) { + this.token = getAccessToken() this.params.pageNo = 1 this.list = [] this.status = 'loadmore' @@ -134,4 +142,14 @@ .image-error { text-align: center; } + .cartNull { + text-align: center; + padding: 500rpx 40rpx 0; + font-size: 28rpx; + color: #888; + } + + .cartNull navigator { + color: #2979ff; + } \ No newline at end of file diff --git a/src/pages/overhaulOrder/addForm.vue b/src/pages/overhaulOrder/addForm.vue index edffb3a..5bb05e8 100644 --- a/src/pages/overhaulOrder/addForm.vue +++ b/src/pages/overhaulOrder/addForm.vue @@ -8,7 +8,7 @@ - {{selectFormat(form.maintenanceNumber,repairOrderList)}} + {{form.maintenanceNumber}} {{`请选择维修工单`}} @@ -18,8 +18,8 @@ - - {{selectFormat(form.deviceNumber,deviceList)}} + + {{form.deviceName}} {{`请输入${type=='DEVICE'?'设备' : '模具'}名称`}} @@ -50,7 +50,7 @@ + :list="singleColumnList" @confirm="chooseSingleColumn" @cancle='singleColumnShow = false'> @@ -71,6 +71,7 @@ id: '', describes: "", maintenanceNumber: '', + factoryAreaNumber:'', faultType: '' }, repairOrderList: [], //维修工单列表 @@ -104,6 +105,8 @@ describes: this.form.describes, maintenanceNumber: this.form.maintenanceNumber, deviceNumber: this.form.deviceNumber, + factoryAreaNumber: this.form.factoryAreaNumber, + type:this.type, faultType: this.form.faultType, } if (this.form.id) { @@ -191,6 +194,7 @@ this.choosesingleColumnItem = this.singleColumnList.filter(item => item.number == e[0].value) this.form.deviceName = this.choosesingleColumnItem[0].name this.form.deviceNumber = this.choosesingleColumnItem[0].deviceNumber + this.form.deviceName = this.choosesingleColumnItem[0].name this.form.factoryAreaName = this.choosesingleColumnItem[0].factoryAreaName this.form.factoryAreaNumber = this.choosesingleColumnItem[0].factoryAreaNumber this.isDisabled = true @@ -255,7 +259,7 @@ factoryAreaName: data.factoryAreaName, faultType: data.faultType, } - this.isDisabled = this.form.maintenanceNumber ? true:false + this.isDisabled = this.form.maintenanceNumber ||this.form.id ? true:false }; await this.getRepairOrderList() this.getDeviceList() diff --git a/src/pages/overhaulOrder/addServiceRecord.vue b/src/pages/overhaulOrder/addServiceRecord.vue index 5494dd0..5104106 100644 --- a/src/pages/overhaulOrder/addServiceRecord.vue +++ b/src/pages/overhaulOrder/addServiceRecord.vue @@ -36,7 +36,7 @@ - + {{formatDate}} @@ -51,7 +51,7 @@ - + @@ -133,7 +133,7 @@ + :list="singleColumnList" @confirm="chooseSingleColumn" @cancle='singleColumnShow = false'> @@ -205,7 +205,7 @@ this.$modal.showToast('请输入检修描述') return; } - if (!this.form.peoples) { + if (!this.form.peoples || this.form.peoples==0) { this.$modal.showToast('请输入预估人数') return; } @@ -213,7 +213,7 @@ this.$modal.showToast('预估人数不得超出100') return; } - if (!this.form.estimatedMinutes) { + if (!this.form.estimatedMinutes || this.form.estimatedMinutes==0) { this.$modal.showToast(`请输入预估分钟`) return; } @@ -396,7 +396,7 @@ this.$modal.showToast('请选择备件') return; } - if (!this.form1.qty) { + if (!this.form1.qty||this.form1.qty==0) { this.$modal.showToast('请输入数量') return; } @@ -461,7 +461,7 @@ .data)).id) { this.form = JSON.parse(decodeURIComponent(option.data)) this.$set(this.form,'itemNumbers',this.form.items) - this.formatDate =this.form.completionTime ? this.$time.formatDate(this.form.completionTime):'' + this.formatDate =this.form.completionTime ? this.$time.formatDate(this.form.completionTime*1000):'' }; this.jxDetailsStatus = await dictApi.getDict('jx_details_status') diff --git a/src/pages/overhaulOrder/detail.vue b/src/pages/overhaulOrder/detail.vue index 03f7776..1f4026d 100644 --- a/src/pages/overhaulOrder/detail.vue +++ b/src/pages/overhaulOrder/detail.vue @@ -18,9 +18,13 @@ 故障类型: {{data.faultTypeName}} + + 创建时间: + {{$time.formatDate(data.createTime)}} + - 维修工: - {{data.maintenance}} + 检修人员: + {{data.maintenanceName}} @@ -38,19 +42,19 @@ 设备编号: - {{deviceInfo.number}} + {{data.number}} 设备名称: - {{deviceInfo.name}} + {{data.name}} 所属厂区: - {{deviceInfo.factoryAreaName}} + {{data.factoryAreaName}} 设备类型: - {{deviceInfo.typeName}} + {{data.type == 'DEVICE'?'设备':data.type == 'TECH'?'工艺':'模具'}} @@ -82,17 +86,17 @@ 完成情况: - {{item.status==0?'完成':'未完成'}} + {{item.status===0 || item.status === '0'? '完成':item.status===1 ||item.status === '1'?'未完成':''}} - + 完成时间: - {{$time.formatDate(item.completionTime)}} + {{$time.formatDate(item.completionTime*1000)}} 工程师确认: {{item.engineer}} - + 未完成原因: {{item.uncompleted}} @@ -131,7 +135,6 @@ + + \ No newline at end of file diff --git a/src/pages/sparePartsServiceWorkOrderList/addForm.vue b/src/pages/sparePartsServiceWorkOrderList/addForm.vue index af4212f..6686052 100644 --- a/src/pages/sparePartsServiceWorkOrderList/addForm.vue +++ b/src/pages/sparePartsServiceWorkOrderList/addForm.vue @@ -95,7 +95,7 @@ + :list="singleColumnList" @confirm="chooseSingleColumn" @cancle='singleColumnShow = false'> @@ -223,13 +223,13 @@ chickRightButton(field) { uni.scanCode({ success: function(res) { - this.form.locationNumber = res.result + this.form1.locationNumber = res.result this.getLocation() } }); }, getLocation(){ - locationApi.getLocation(this.form.locationNumber).then(res=>{ + locationApi.getLocation(this.form1.locationNumber).then(res=>{ if(!res.data){ this.$modal.showToast('找不到该库位') return; @@ -296,7 +296,13 @@ return; } } - +if (this.form.itemNumbers && this.form.itemNumbers.length > 0) { + let arr1 = this.form.itemNumbers.filter(item => item.locationNumber == this.form1.locationNumber) + if (arr1 && arr1.length > 0) { + this.$modal.showToast('该库位已经绑定备件') + return; + } + } this.form.itemNumbers.push(this.form1) this.isPopupShow = false }, diff --git a/src/pages/spotCheckOrder/addForm.vue b/src/pages/spotCheckOrder/addForm.vue index 3beb1a6..3ac3e63 100644 --- a/src/pages/spotCheckOrder/addForm.vue +++ b/src/pages/spotCheckOrder/addForm.vue @@ -15,8 +15,8 @@ - - + + @@ -66,7 +66,7 @@ + :list="singleColumnList" @confirm="chooseSingleColumn" @cancle='singleColumnShow = false'> @@ -152,6 +152,10 @@ this.$modal.showToast('请选择班次') return; } + if (this.subList.length==0) { + this.$modal.showToast('该设备无检修项目') + return; + } const data = { describes: this.form.describes, deviceNumber: this.form.deviceNumber, diff --git a/src/pages/upkeepOrder/addServiceRecord.vue b/src/pages/upkeepOrder/addServiceRecord.vue index 5f3d976..423a6b0 100644 --- a/src/pages/upkeepOrder/addServiceRecord.vue +++ b/src/pages/upkeepOrder/addServiceRecord.vue @@ -8,10 +8,10 @@ - + - + @@ -39,7 +39,7 @@ - + {{formatDate}} @@ -54,7 +54,7 @@ - + @@ -136,8 +136,8 @@ - + :list="singleColumnList" @confirm="chooseSingleColumn" @cancle='singleColumnShow = false'> + @@ -204,18 +204,18 @@ // 触发提交表单 submit() { // 校验 - if (!this.form.peoples) { - this.$modal.showToast('请输入预估人数') - return; - } + // if (!this.form.peoples) { + // this.$modal.showToast('请输入预估人数') + // return; + // } if (this.form.peoples>100) { this.$modal.showToast('预估人数不得超出100') return; } - if (!this.form.estimatedMinutes) { - this.$modal.showToast(`请输入预估分钟`) - return; - } + // if (!this.form.estimatedMinutes) { + // this.$modal.showToast(`请输入预估分钟`) + // return; + // } if (!this.form.actualMinutes) { this.$modal.showToast('请输入实际分钟') return; @@ -461,7 +461,7 @@ .data)).id) { this.form = JSON.parse(decodeURIComponent(option.data)) this.$set(this.form,'itemNumbers',this.form.items) - this.formatDate =this.form.completionTime ? this.$time.formatDate(this.form.completionTime):'' + this.formatDate =this.form.completionTime ? this.$time.formatDate(this.form.completionTime*1000):'' }; console.log(this.form) this.jxDetailsStatus = await dictApi.getDict('jx_details_status') diff --git a/src/pages/upkeepOrder/detail.vue b/src/pages/upkeepOrder/detail.vue index 42d9d05..90d5804 100644 --- a/src/pages/upkeepOrder/detail.vue +++ b/src/pages/upkeepOrder/detail.vue @@ -18,19 +18,34 @@ 故障类型: {{data.faultTypeName}} - - 维修工: - {{data.maintenance}} + + 创建时间: + {{$time.formatDate(data.createTime)}} + + + 创建人员: + {{data.creator}} + + + 接单时间: + {{$time.formatDate(data.receivingTime)}} + + + 维修人员: + {{data.maintenanceName}} + + + 完成时间: + {{$time.formatDate(data.completionTime)}}
- + - {{changeItem.name}} @@ -38,19 +53,19 @@ 设备编号: - {{deviceInfo.number}} + {{data.number}} 设备名称: - {{deviceInfo.name}} + {{data.name}} 所属厂区: - {{deviceInfo.factoryAreaName}} + {{data.factoryAreaName}} 设备类型: - {{deviceInfo.typeName}} + {{data.type == 'DEVICE'?'设备':data.type == 'TECH'?'工艺':'模具'}} @@ -68,15 +83,15 @@ --> 预估人数: - {{item.peoples}}人 + {{item.peoples}}人 预估分钟: - {{item.estimatedMinutes}}分钟 + {{item.estimatedMinutes}}分钟 实际分钟: - {{item.actualMinutes}}分钟 + {{item.actualMinutes}}分钟 责任人: @@ -84,17 +99,17 @@ 完成情况: - {{item.status==0?'完成':'未完成'}} + {{item.status===0 || item.status === '0'? '完成':item.status===1 ||item.status === '1'?'未完成':''}} - + 完成时间: - {{$time.formatDate(item.completionTime)}} + {{$time.formatDate(item.completionTime*1000)}} 工程师确认: {{item.engineer}} - + 未完成原因: {{item.uncompleted}} @@ -131,7 +146,6 @@