From d8c126fccff2ef86b78f337982425816cad30e7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=98937886381=E2=80=99?= <‘937886381@qq.com’> Date: Fri, 1 Mar 2024 15:27:01 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.dev | 8 +-- src/views/OperationalOverview/AGVBoard.vue | 3 +- src/views/OperationalOverview/coldBoard.vue | 46 ++++++----------- .../qualityInspectionBoxPermissions/index.vue | 22 ++++++-- .../base/qualityHotMaterial/add-or-updata.vue | 13 +++-- .../base/qualityScrapLog/add-or-updata.vue | 4 +- .../base/qualityScrapLog/detail-or-updata.vue | 51 +++++++++---------- .../monitoring/originalGlassRetrace/index.vue | 8 +-- .../report/productionDayReport/index.vue | 4 +- 9 files changed, 79 insertions(+), 80 deletions(-) diff --git a/.env.dev b/.env.dev index e6eafbc1..6a03e051 100644 --- a/.env.dev +++ b/.env.dev @@ -1,8 +1,8 @@ ### # @Author: Do not edit # @Date: 2023-08-29 09:40:39 - # @LastEditTime: 2024-02-26 08:45:43 - # @LastEditors: DY + # @LastEditTime: 2024-02-29 08:34:48 + # @LastEditors: zhp # @Description: ### # 开发环境配置 @@ -20,10 +20,10 @@ VUE_APP_TITLE = MES系统 # VUE_APP_BASE_API = 'http://192.168.1.8:48082' # VUE_APP_BASE_API = 'http://192.168.4.159:48080' # VUE_APP_BASE_API = 'http://192.168.1.104:48082' -# VUE_APP_BASE_API = 'http://192.168.0.33:48082' +VUE_APP_BASE_API = 'http://192.168.0.33:48082' # VUE_APP_BASE_API = 'http://192.168.1.62:48082' # VUE_APP_BASE_API = 'http://192.168.1.78:48082' -VUE_APP_BASE_API = 'http://192.168.1.47:48082' +# VUE_APP_BASE_API = 'http://192.168.1.47:48082' # socket地址 VUE_APP_Socket_API = 'ws://192.168.0.30:8888' VUE_APP_Socket_Dcs_API = 'ws://10.70.180.10:8081' diff --git a/src/views/OperationalOverview/AGVBoard.vue b/src/views/OperationalOverview/AGVBoard.vue index 4ba4aed8..6493c3c5 100644 --- a/src/views/OperationalOverview/AGVBoard.vue +++ b/src/views/OperationalOverview/AGVBoard.vue @@ -2,7 +2,7 @@ * @Author: zwq * @Date: 2021-07-19 15:18:30 * @LastEditors: zhp - * @LastEditTime: 2024-02-23 16:11:33 + * @LastEditTime: 2024-02-29 15:48:47 * @Description: --> @@ -715,6 +715,7 @@ export default { qualityMonthTableProps, modelMonth: '', qualityList1, + // logoutTime: 43200000, qualityTableProps2, qualityList2, dateType: '0', diff --git a/src/views/OperationalOverview/coldBoard.vue b/src/views/OperationalOverview/coldBoard.vue index 3d07693d..b041214c 100644 --- a/src/views/OperationalOverview/coldBoard.vue +++ b/src/views/OperationalOverview/coldBoard.vue @@ -1,7 +1,7 @@ @@ -341,7 +341,9 @@ export default { // offsetWidth: null, cxNameList, cxDataList, + // time:12, cutProps, + // logoutTime: 43200000, cutTableDataList:[], clientWidth: 0, containerWidth: 111111, @@ -432,36 +434,15 @@ export default { this.beilv2 = _this.clientWidth / 1920 })() } - // let obj = { - // 'a': 11111, - // 'b': 22222, - // 'c': 33333, - // 'd': 44444, - // 'e': 55555, + // logoutInterval = setInterval(() => { + // this.logoutTime -= 1000 + // }, 1000) + // if (this.logoutTime === 0) { + // this.SJGInitWebSocket() + // this.CutInitWebSocket() + // this.funInitWebSocket() + // this.logoutTimeReset() // } - // let index = 0 - // for (let i in obj) { - // index++, - // console.log(index); - // } - // this.getList() - // const _this = this; - // window.onresize = () => { - // return (() => { - // _this.clientWidth = `${document.documentElement.clientWidth}` - // this.beilv2 = _this.clientWidth / 1920 - // })() - // } - // this.beilv2 = window.innerWidth / 1920 - // addEventListener('resize', resizeFun = () => { - // this.beilv2 = window.innerWidth / 1920 - // }) - // erd.listenTo(document, (element) => { - // this.beilv2 = element.offsetWidth / 1920 - - // // var width = element.offsetWidth; - // // var height = element.offsetHeight; - // }); }, // beforeDestroy() { // //离开页面删除检测器和所有侦听器 @@ -469,13 +450,16 @@ export default { // removeEventListener('resize', resizeFun) // }, methods: { + // logoutTimeReset() { + // this.logoutTime = this.time * 60 * 60 * 1000 + // }, CutWebsocketClose(e) { console.log('WebSocket 断开连接', e) }, SJGWebsocketClose(e) { console.log('WebSocket 断开连接', e) }, - funInitWebSocket(e) { + funWebSocketClose(e) { console.log('WebSocket 断开连接', e) }, formatTime(time, option) { diff --git a/src/views/quality/base/basicData/qualityInspectionBoxPermissions/index.vue b/src/views/quality/base/basicData/qualityInspectionBoxPermissions/index.vue index b553af67..364770fe 100644 --- a/src/views/quality/base/basicData/qualityInspectionBoxPermissions/index.vue +++ b/src/views/quality/base/basicData/qualityInspectionBoxPermissions/index.vue @@ -51,8 +51,16 @@ export default { label: '用户名称', selectOptions: [], labelField: 'name', - valueField: 'id', + valueField: 'name', param: 'userName', + }, + { + type: 'select', + label: '用户昵称', + selectOptions: [], + labelField: 'name', + valueField: 'name', + param: 'nickName', }, { type: 'button', @@ -143,10 +151,16 @@ export default { }).then((res) => { this.searchBarFormConfig[0].selectOptions = res.data.map((item) => { return { - id: item.id, + id: item.username, name:item.username } }) + this.searchBarFormConfig[1].selectOptions = res.data.map((item) => { + return { + id: item.nickname, + name: item.nickname + } + }) }) }, getDataList() { @@ -206,7 +220,9 @@ export default { case 'search': this.listQuery.pageNo = 1; this.listQuery.pageSize = 10; - this.listQuery.inspectionDetContent = val.inspectionDetContent ? val.inspectionDetContent : undefined; + this.listQuery.userName = val.userName ? val.userName : undefined; + this.listQuery.nickName = val.nickName ? val.nickName : undefined; + // this.listQuery.teamId = val.teamId ? val.teamId : undefined; this.getDataList() break; diff --git a/src/views/quality/base/qualityHotMaterial/add-or-updata.vue b/src/views/quality/base/qualityHotMaterial/add-or-updata.vue index a7959590..1a974283 100644 --- a/src/views/quality/base/qualityHotMaterial/add-or-updata.vue +++ b/src/views/quality/base/qualityHotMaterial/add-or-updata.vue @@ -1,7 +1,7 @@ @@ -80,8 +80,9 @@ - @@ -91,14 +92,12 @@ - + - + diff --git a/src/views/quality/base/qualityScrapLog/add-or-updata.vue b/src/views/quality/base/qualityScrapLog/add-or-updata.vue index 48866b9e..dc063ca6 100644 --- a/src/views/quality/base/qualityScrapLog/add-or-updata.vue +++ b/src/views/quality/base/qualityScrapLog/add-or-updata.vue @@ -1,7 +1,7 @@ @@ -130,7 +130,7 @@ export default { mounted() { this.getDict() console.log('我看看', this.dataForm) - this.getCurrentTime() + // this.getCurrentTime() this.getWorksectionById() }, methods: { diff --git a/src/views/quality/base/qualityScrapLog/detail-or-updata.vue b/src/views/quality/base/qualityScrapLog/detail-or-updata.vue index 7a6acef7..165c2921 100644 --- a/src/views/quality/base/qualityScrapLog/detail-or-updata.vue +++ b/src/views/quality/base/qualityScrapLog/detail-or-updata.vue @@ -1,7 +1,7 @@ @@ -75,7 +75,7 @@ diff --git a/src/views/quality/monitoring/originalGlassRetrace/index.vue b/src/views/quality/monitoring/originalGlassRetrace/index.vue index 71231acf..75faf29f 100644 --- a/src/views/quality/monitoring/originalGlassRetrace/index.vue +++ b/src/views/quality/monitoring/originalGlassRetrace/index.vue @@ -2,7 +2,7 @@ * @Author: zwq * @Date: 2023-08-01 14:55:51 * @LastEditors: zhp - * @LastEditTime: 2024-02-23 09:16:24 + * @LastEditTime: 2024-03-01 10:27:29 * @Description: --> @@ -124,8 +124,8 @@ export default { label: '工单', selectOptions: [], labelField: 'name', - valueField: 'id', - param: 'workOrderId' + valueField: 'name', + param: 'workOrderName' }, // { // type: 'datePicker', @@ -233,7 +233,7 @@ export default { buttonClick(val) { console.log(val) if (val.btnName === 'search') { - this.listQuery.workOrderId = val.workOrderId ? val.workOrderId :undefined + this.listQuery.workOrderName = val.workOrderName ? val.workOrderName :undefined // this.queryParams.status = val.status // if (val.timeVal && val.timeVal.length != 0 ) { // this.listQuery.startTime = val.timeVal[0] + ' 00:00:00' diff --git a/src/views/report/productionDayReport/index.vue b/src/views/report/productionDayReport/index.vue index 71b69624..9b3a60ba 100644 --- a/src/views/report/productionDayReport/index.vue +++ b/src/views/report/productionDayReport/index.vue @@ -1,7 +1,7 @@ @@ -9,7 +9,7 @@ - + 查询 From 48e7612a787cd8d12567d6f7419e9491afa619c2 Mon Sep 17 00:00:00 2001 From: helloDy <1615073571@qq.com> Date: Fri, 1 Mar 2024 20:39:52 +0800 Subject: [PATCH 2/2] bug second --- .env.dev | 2 +- .../base/coreProductionLine/add-or-updata.vue | 25 +- .../base/alarm/Record/AddOrUpdate.vue | 2 +- .../base/alarm/Record/DialogForm.vue | 520 ++++++++++++++++++ .../config/DataCollection/TableConfig.vue | 6 +- .../base/inspection/Confirm/add-or-updata.vue | 16 +- .../base/inspection/Confirm/index.vue | 19 +- .../base/inspection/Settings/add.vue | 29 +- .../base/repair/CustomDialogForm.vue | 1 + .../equipment/base/repair/Repair--add.vue | 19 +- 10 files changed, 604 insertions(+), 35 deletions(-) create mode 100644 src/views/equipment/base/alarm/Record/DialogForm.vue diff --git a/.env.dev b/.env.dev index 78b9f3e6..b6e1c73b 100644 --- a/.env.dev +++ b/.env.dev @@ -1,7 +1,7 @@ ### # @Author: Do not edit # @Date: 2023-08-29 09:40:39 - # @LastEditTime: 2024-02-29 15:53:50 + # @LastEditTime: 2024-03-01 18:43:05 # @LastEditors: DY # @Description: ### diff --git a/src/views/base/coreProductionLine/add-or-updata.vue b/src/views/base/coreProductionLine/add-or-updata.vue index 0916b746..703339b8 100644 --- a/src/views/base/coreProductionLine/add-or-updata.vue +++ b/src/views/base/coreProductionLine/add-or-updata.vue @@ -2,7 +2,7 @@ * @Author: zwq * @Date: 2021-11-18 14:16:25 * @LastEditors: DY - * @LastEditTime: 2024-02-18 13:53:09 + * @LastEditTime: 2024-03-01 19:52:55 * @Description: --> @@ -33,14 +33,13 @@ + :value="Number(dict.value)" /> @@ -125,6 +124,26 @@ export default { this.getDict() }, methods: { + init(id) { + this.dataForm.id = id || ""; + this.visible = true; + if (this.urlOptions.getOption) { + this.getArr() + } + this.$nextTick(() => { + this.$refs["dataForm"].resetFields(); + if (this.dataForm.id) { + this.urlOptions.infoURL(id).then(response => { + this.dataForm = response.data + // this.dataForm.roomNameDict = String(this.dataForm.roomNameDict) + }); + } else { + if (this.urlOptions.isGetCode) { + this.getCode() + } + } + }); + }, async getDict() { // 工厂列表 const factoryRes = await getFactoryList(); diff --git a/src/views/equipment/base/alarm/Record/AddOrUpdate.vue b/src/views/equipment/base/alarm/Record/AddOrUpdate.vue index 28544fe2..3f180f43 100644 --- a/src/views/equipment/base/alarm/Record/AddOrUpdate.vue +++ b/src/views/equipment/base/alarm/Record/AddOrUpdate.vue @@ -38,7 +38,7 @@ import SmallTitle from './SmallTitle'; import { getworkerAll } from '@/api/base/materialUseLog'; import Editor from '@/components/Editor'; -import DialogForm from '@/components/DialogForm'; +import DialogForm from './DialogForm'; export default { name: 'AlarmHandle', diff --git a/src/views/equipment/base/alarm/Record/DialogForm.vue b/src/views/equipment/base/alarm/Record/DialogForm.vue new file mode 100644 index 00000000..e400bf53 --- /dev/null +++ b/src/views/equipment/base/alarm/Record/DialogForm.vue @@ -0,0 +1,520 @@ + + + + + + + + + + + + + + + + + + + + + + + + + 上传文件 + + + {{ col.uploadTips || '只能上传jpg/png文件, 大小不超过2MB' }} + + + + + + + + + + + + + + + + diff --git a/src/views/equipment/base/config/DataCollection/TableConfig.vue b/src/views/equipment/base/config/DataCollection/TableConfig.vue index 2f9dda7a..2b08eada 100644 --- a/src/views/equipment/base/config/DataCollection/TableConfig.vue +++ b/src/views/equipment/base/config/DataCollection/TableConfig.vue @@ -218,9 +218,9 @@ export default { label: '是否采集', // 是否采集 0 代表不采集, 1 代表采集 prop: 'collection', bind: { - 'active-value': 1, + 'active-value': 1, 'inactive-value': 0, - value: 1, + value: 1, }, }, ], @@ -294,7 +294,7 @@ export default { name: undefined, enName: undefined, description: undefined, - collection: undefined, + collection: 1, }; this.resetForm('form'); }, diff --git a/src/views/equipment/base/inspection/Confirm/add-or-updata.vue b/src/views/equipment/base/inspection/Confirm/add-or-updata.vue index ad653212..af2c6992 100644 --- a/src/views/equipment/base/inspection/Confirm/add-or-updata.vue +++ b/src/views/equipment/base/inspection/Confirm/add-or-updata.vue @@ -2,7 +2,7 @@ * @Author: zwq * @Date: 2021-11-18 14:16:25 * @LastEditors: DY - * @LastEditTime: 2024-02-29 14:59:28 + * @LastEditTime: 2024-03-01 18:57:31 * @Description: --> @@ -78,7 +78,7 @@ v-for="opt in inspectorOptions" :key="opt.value" :label="opt.label" - :value="opt.value" /> + :value="opt.label" /> @@ -418,7 +418,7 @@ export default { }); }, getConfirmed() { - return this.$confirm('是否直接确认巡检记录', '提示', { + return this.$confirm('是否直接确认巡检单', '提示', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning', @@ -431,10 +431,16 @@ export default { } this.$nextTick(() => { this.getConfirmed().then(confirm => { + let checkPersonParam = ''; + if (!this.dataForm.checkPerson || this.dataForm.checkPerson.trim() == '') { + /** 如有必要,更新巡检人 */ + checkPersonParam = `&checkPerson=${this.$store.getters.nickname}`; + } else { + checkPersonParam = `&checkPerson=${this.dataForm.checkPerson}` + } this.$axios({ url: - '/base/equipment-check-order/confirm?confirmPerson=' + - this.$store.getters.userId, + `/base/equipment-check-order/confirm?confirmPerson=${this.$store.getters.nickname}` + checkPersonParam, method: 'put', data: [this.dataForm.id], }).then(res =>{ diff --git a/src/views/equipment/base/inspection/Confirm/index.vue b/src/views/equipment/base/inspection/Confirm/index.vue index eed73765..dc8d983c 100644 --- a/src/views/equipment/base/inspection/Confirm/index.vue +++ b/src/views/equipment/base/inspection/Confirm/index.vue @@ -179,8 +179,13 @@ export default { this.$modal .confirm('是否确认所有选中巡检单"?') .then(() => { + let checkPersonParam = ''; + if (!row.checkPerson || row.checkPerson.trim() == '') { + /** 如有必要,更新巡检人 */ + checkPersonParam = `&checkPerson=${this.$store.getters.nickname}`; + } return this.$axios({ - url: '/base/equipment-check-order/confirm?confirmPerson=' + this.$store.getters.userId, + url: `/base/equipment-check-order/confirm?confirmPerson=${this.$store.getters.nickname}` + checkPersonParam, method: 'put', data: this.$refs['waiting-list-table'].selectedPlan.map( (item) => item.id @@ -394,11 +399,17 @@ export default { this.$modal .confirm('是否确认巡检单"' + row.name + '"?') .then(() => { + let checkPersonParam = ''; + const nickname = this.$store.getters.nickname; + if (!row.checkPerson || row.checkPerson.trim() == '') { + /** 如有必要,更新巡检人 */ + checkPersonParam = `&checkPerson=${nickname}`; + } else { + checkPersonParam = `&checkPerson=${row.checkPerson}` + } return this.$axios({ url: - '/base/equipment-check-order/confirm?confirmPerson=' + - this.$store.getters.userId, - // '/base/equipment-check-order/confirm?ids=' + JSON.stringify([id]).replaceAll("\"", ''), + `/base/equipment-check-order/confirm?confirmPerson=${nickname}` + checkPersonParam, method: 'put', data: [row.id], }); diff --git a/src/views/equipment/base/inspection/Settings/add.vue b/src/views/equipment/base/inspection/Settings/add.vue index 166d054e..4c49f261 100644 --- a/src/views/equipment/base/inspection/Settings/add.vue +++ b/src/views/equipment/base/inspection/Settings/add.vue @@ -2,7 +2,7 @@ * @Author: zwq * @Date: 2021-11-18 14:16:25 * @LastEditors: DY - * @LastEditTime: 2024-02-29 14:58:37 + * @LastEditTime: 2024-03-01 19:44:59 * @Description: --> @@ -11,7 +11,7 @@ :rules="dataRule" ref="dataForm" @keyup.enter.native="dataFormSubmit()" - label-width="120px"> + label-width="150px"> @@ -27,8 +27,6 @@ placeholder="请输入巡检单编码" /> - - - - + + + + + - - @@ -121,7 +122,8 @@ export default { planCheckTime: null, confirmTimeLimit: null, groupClass: null, - remark: null + remark: null, + checkPeriod: null }, groupOptions: [], departmentOptions: [], @@ -137,6 +139,15 @@ export default { ], planCheckTime: [ { required: true, message: '计划巡检时间不能为空', trigger: 'blur' } + ], + checkPeriod: [ + { required: true, message: '巡检频率不能为空', trigger: 'blur' }, + { + type: 'number', + message: '请输入正确的数字类型', + trigger: 'blur', + transform: (val) => Number(val), + } ] } }; diff --git a/src/views/equipment/base/repair/CustomDialogForm.vue b/src/views/equipment/base/repair/CustomDialogForm.vue index 611f0918..ad0ff21e 100644 --- a/src/views/equipment/base/repair/CustomDialogForm.vue +++ b/src/views/equipment/base/repair/CustomDialogForm.vue @@ -160,6 +160,7 @@ import Editor from "@/components/Editor"; import { getDictDatas } from "@/utils/dict"; import { parseTime } from '@/utils/ruoyi' import { getDictDataLabel } from '@/utils/dict'; +import tupleImg from '@/assets/images/tuple.png'; const uploadedFile = { name: 'UploadedFile', diff --git a/src/views/equipment/base/repair/Repair--add.vue b/src/views/equipment/base/repair/Repair--add.vue index 469ae381..712e3103 100644 --- a/src/views/equipment/base/repair/Repair--add.vue +++ b/src/views/equipment/base/repair/Repair--add.vue @@ -29,7 +29,7 @@ - + - + @@ -234,7 +234,7 @@ v-for="opt in workerOptions" :key="opt.value" :label="opt.label" - :value="opt.value" /> + :value="opt.label" /> @@ -597,9 +597,9 @@ export default { /** 设置默认维修工为用户自己 */ setInitWorker() { /** 获取用户自身id */ - const userId = this.$store.getters.userId; + const nickname = this.$store.getters.nickname; this.$nextTick(() => { - this.form.repairman = [userId]; + this.form.repairman = [nickname]; }); }, @@ -630,8 +630,8 @@ export default { /** 获取设备 */ async initEquipment() { const response = await this.$axios('/base/core-equipment/listAll'); - this.equipmentList = response.data || []; - this.equipmentOptions = response.data || []; + this.equipmentList = response.data.filter(item => item.special === false) || []; + this.equipmentOptions = response.data.filter(item => item.special === false) || []; // this.allSpeicalEquipments = equipmentOptions; }, /** 获取维修工 - 同时从用户表和员工表拉取数据 */ @@ -737,6 +737,7 @@ export default { fileType: prop == 'files' ? 2 : 1, }); this.$modal.msgSuccess('上传成功'); + console.log('为我', this.form.files) this.$emit('update', this.form); },