From 3dc2c715158eb69c6c7a2c0a39463305f6a10a30 Mon Sep 17 00:00:00 2001 From: yinq Date: Mon, 29 Jul 2024 17:44:33 +0800 Subject: [PATCH 1/3] =?UTF-8?q?change=20-=20add=E8=BD=A6=E9=97=B4=E6=9F=A5?= =?UTF-8?q?=E7=9C=8B=E5=8E=86=E5=8F=B2=E9=80=9A=E7=9F=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/SysNoticeController.java | 5 +- .../mapper/system/SysNoticeMapper.xml | 2 +- hw-ui/src/components/workshopNotice/index.vue | 221 +++++++++++++++--- hw-ui/src/utils/notice.js | 18 +- 4 files changed, 206 insertions(+), 40 deletions(-) diff --git a/hw-modules/hw-system/src/main/java/com/hw/system/controller/SysNoticeController.java b/hw-modules/hw-system/src/main/java/com/hw/system/controller/SysNoticeController.java index 63c257d..4592e5b 100644 --- a/hw-modules/hw-system/src/main/java/com/hw/system/controller/SysNoticeController.java +++ b/hw-modules/hw-system/src/main/java/com/hw/system/controller/SysNoticeController.java @@ -98,10 +98,11 @@ public class SysNoticeController extends BaseController * @return */ @GetMapping("/workshopNoticeList") - public AjaxResult workshopNoticeList(SysNotice notice) + public TableDataInfo workshopNoticeList(SysNotice notice) { + startPage(); List list = noticeService.workshopNoticeList(notice); - return success(list); + return getDataTable(list); } /** diff --git a/hw-modules/hw-system/src/main/resources/mapper/system/SysNoticeMapper.xml b/hw-modules/hw-system/src/main/resources/mapper/system/SysNoticeMapper.xml index cd0e3f1..9999d76 100644 --- a/hw-modules/hw-system/src/main/resources/mapper/system/SysNoticeMapper.xml +++ b/hw-modules/hw-system/src/main/resources/mapper/system/SysNoticeMapper.xml @@ -76,7 +76,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" AND b.user_id = #{userId} - + AND b.check_status = #{checkStatus} diff --git a/hw-ui/src/components/workshopNotice/index.vue b/hw-ui/src/components/workshopNotice/index.vue index dd163da..0c112a6 100644 --- a/hw-ui/src/components/workshopNotice/index.vue +++ b/hw-ui/src/components/workshopNotice/index.vue @@ -1,42 +1,99 @@ + diff --git a/hw-ui/src/utils/notice.js b/hw-ui/src/utils/notice.js index 56303b4..1412f41 100644 --- a/hw-ui/src/utils/notice.js +++ b/hw-ui/src/utils/notice.js @@ -13,9 +13,15 @@ export const noticeData = { }; }, mounted() { - setInterval(() => { + setInterval(() => this.workshopNoticeTasks(), 5000 * 1000) + }, + methods: { + workshopNoticeTasks() { + if (this.notificationInstance) { + this.notificationInstance.close(); // 手动关闭通知 + } workshopNoticeList({noticeType: '1', checkStatus: '0'}).then(res => { - this.noticeList = res.data; + this.noticeList = res.rows; if (this.noticeList.length > 0) { this.notificationInstance = this.$notify.info({ title: '通知', @@ -35,9 +41,9 @@ export const noticeData = { }); } }); - }, 60 * 1000) - }, - methods: { + }, + + //点击查看弹窗逻辑 handleNotificationClick() { this.noticeListData = this.noticeList[0]; let userNotice = this.noticeListData.sysUserNoticeList[0]; @@ -51,7 +57,7 @@ export const noticeData = { this.notificationInstance.close(); // 手动关闭通知 } }, - } + }, }; From c66f847ffbd26d354c1a500e83a5e160d04123d9 Mon Sep 17 00:00:00 2001 From: yinq Date: Mon, 29 Jul 2024 17:46:53 +0800 Subject: [PATCH 2/3] =?UTF-8?q?change=20-=20add=E8=BD=A6=E9=97=B4=E6=9F=A5?= =?UTF-8?q?=E7=9C=8B=E5=8E=86=E5=8F=B2=E9=80=9A=E7=9F=A5-60=E7=A7=92?= =?UTF-8?q?=E8=BD=AE=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hw-ui/src/utils/notice.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw-ui/src/utils/notice.js b/hw-ui/src/utils/notice.js index 1412f41..912f98c 100644 --- a/hw-ui/src/utils/notice.js +++ b/hw-ui/src/utils/notice.js @@ -13,7 +13,7 @@ export const noticeData = { }; }, mounted() { - setInterval(() => this.workshopNoticeTasks(), 5000 * 1000) + setInterval(() => this.workshopNoticeTasks(), 60 * 1000) }, methods: { workshopNoticeTasks() { From 6f7da0dde36e3dcc3b08fa0dc1c40e38193cf9b2 Mon Sep 17 00:00:00 2001 From: yinq Date: Mon, 29 Jul 2024 20:03:38 +0800 Subject: [PATCH 3/3] =?UTF-8?q?change=20-=20=E7=89=A9=E6=96=99=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=EF=BC=9A=E6=90=9C=E7=B4=A2=E7=89=A9=E6=96=99=E7=BC=96?= =?UTF-8?q?=E7=A0=81=E6=94=B9=E4=B8=BA=E6=A8=A1=E7=B3=8A=EF=BC=8C=E4=B8=8D?= =?UTF-8?q?=E5=8C=BA=E5=88=86=E5=A4=A7=E5=B0=8F=E5=86=99=E3=80=82=E4=BF=AE?= =?UTF-8?q?=E6=94=B9=E7=89=A9=E6=96=99=E7=B1=BB=E5=9E=8B=E6=97=B6=EF=BC=8C?= =?UTF-8?q?=E4=B8=8D=E8=A6=81=E6=98=BE=E7=A4=BA=E9=A1=B6=E7=BA=A7=E8=8A=82?= =?UTF-8?q?=E7=82=B9=EF=BC=8C=E6=98=BE=E7=A4=BA=E7=A9=BA=20=20=20=20=20=20?= =?UTF-8?q?=20=20=20=20=E5=B7=A5=E5=BA=8F=E4=BF=A1=E6=81=AF=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E6=89=80=E5=9C=A8=E6=A5=BC=E5=B1=82=EF=BC=8C=E8=87=AA?= =?UTF-8?q?=E5=8A=A8=E5=8C=96=E5=B7=A5=E5=BA=8F=E4=B8=8D=E9=9C=80=E8=A6=81?= =?UTF-8?q?=E5=85=B3=E8=81=94=E5=88=B0=E4=BA=BA=EF=BC=8C=E4=BA=BA=E5=B7=A5?= =?UTF-8?q?=E5=B7=A5=E5=BA=8F=E5=85=B3=E8=81=94=E5=88=B0=E4=BA=BA=EF=BC=8C?= =?UTF-8?q?=E4=BF=9D=E5=AD=98nickname=E3=80=82=20=20=20=20=20=20=20=20=20?= =?UTF-8?q?=20=E7=89=A9=E6=96=99bom=EF=BC=9A=E9=A1=B6=E7=BA=A7=E8=8A=82?= =?UTF-8?q?=E7=82=B9=E4=B8=8D=E9=9C=80=E8=A6=81=E9=80=89=E6=8B=A9=E6=A3=80?= =?UTF-8?q?=E9=AA=8C=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/mes/MesBaseMaterialInfoMapper.xml | 2 +- hw-ui/src/views/mes/materialBom/index.vue | 2 +- hw-ui/src/views/mes/materialinfo/index.vue | 5 +---- hw-ui/src/views/mes/processInfo/index.vue | 17 +++++++++++++++-- 4 files changed, 18 insertions(+), 8 deletions(-) diff --git a/hw-modules/hw-mes/src/main/resources/mapper/mes/MesBaseMaterialInfoMapper.xml b/hw-modules/hw-mes/src/main/resources/mapper/mes/MesBaseMaterialInfoMapper.xml index 383637f..eb92165 100644 --- a/hw-modules/hw-mes/src/main/resources/mapper/mes/MesBaseMaterialInfoMapper.xml +++ b/hw-modules/hw-mes/src/main/resources/mapper/mes/MesBaseMaterialInfoMapper.xml @@ -82,7 +82,7 @@ and bmi.erp_id = #{erpId} - and bmi.material_code = #{materialCode} + and bmi.material_code like concat('%', #{materialCode},'%') and bmi.old_material_code = #{oldMaterialCode} and bmi.material_name like concat('%', #{materialName}, diff --git a/hw-ui/src/views/mes/materialBom/index.vue b/hw-ui/src/views/mes/materialBom/index.vue index 2a97a5b..7a972f5 100644 --- a/hw-ui/src/views/mes/materialBom/index.vue +++ b/hw-ui/src/views/mes/materialBom/index.vue @@ -202,7 +202,7 @@ - + { - this.baseMaterialTypeOptions = []; - const data = {matrialTypeId: 0, typeName: '顶级节点', children: []}; - data.children = this.handleTree(response.data, "matrialTypeId", "parentId"); - this.baseMaterialTypeOptions.push(data); + this.baseMaterialTypeOptions = this.handleTree(response.data, "matrialTypeId", "parentId"); }); }, /** 删除按钮操作 */ diff --git a/hw-ui/src/views/mes/processInfo/index.vue b/hw-ui/src/views/mes/processInfo/index.vue index 8708da4..dd28e16 100644 --- a/hw-ui/src/views/mes/processInfo/index.vue +++ b/hw-ui/src/views/mes/processInfo/index.vue @@ -85,6 +85,7 @@ +