From f02142ed034f1c7c09ea0b4a3bbd1e99c900e1f9 Mon Sep 17 00:00:00 2001 From: aikai Date: Tue, 1 Jul 2025 09:35:42 +0800 Subject: [PATCH 1/4] =?UTF-8?q?refactor(bpm):=20=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E8=AE=A2=E5=8D=95=E7=9B=B8=E5=85=B3=20SQL=20?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E4=B8=AD=E7=9A=84=E6=97=B6=E9=97=B4=E8=8C=83?= =?UTF-8?q?=E5=9B=B4=E6=90=9C=E7=B4=A2=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 将单一的 BETWEEN 条件拆分为两个独立的条件 - 允许单独搜索开始时间和结束时间 - 提高了查询的灵活性和准确性 --- .../mapper/oa/BpmOAWorkOrderMapper.xml | 27 ++++++++++++++----- 1 file changed, 21 insertions(+), 6 deletions(-) diff --git a/yudao-module-bpm/yudao-module-bpm-biz/src/main/resources/mapper/oa/BpmOAWorkOrderMapper.xml b/yudao-module-bpm/yudao-module-bpm-biz/src/main/resources/mapper/oa/BpmOAWorkOrderMapper.xml index debb1856..93e0a311 100644 --- a/yudao-module-bpm/yudao-module-bpm-biz/src/main/resources/mapper/oa/BpmOAWorkOrderMapper.xml +++ b/yudao-module-bpm/yudao-module-bpm-biz/src/main/resources/mapper/oa/BpmOAWorkOrderMapper.xml @@ -81,8 +81,13 @@ AND w.level = #{req.level} - - AND w.create_time BETWEEN #{req.createTime[0]} AND #{req.createTime[1]} + + + AND w.create_time >= #{req.createTime[0]} + + + AND w.create_time <= #{req.createTime[1]} + ORDER BY w.id DESC @@ -128,8 +133,13 @@ AND w.status = #{req.status} - - AND w.create_time BETWEEN #{req.createTime[0]} AND #{req.createTime[1]} + + + AND w.create_time >= #{req.createTime[0]} + + + AND w.create_time <= #{req.createTime[1]} + ORDER BY w.id DESC @@ -175,8 +185,13 @@ AND w.status = #{req.status} - - AND w.create_time BETWEEN #{req.createTime[0]} AND #{req.createTime[1]} + + + AND w.create_time >= #{req.createTime[0]} + + + AND w.create_time <= #{req.createTime[1]} + ORDER BY w.id DESC From 2a0824349139a5c35b46c24088c0e0554d391291 Mon Sep 17 00:00:00 2001 From: aikai Date: Tue, 1 Jul 2025 09:47:59 +0800 Subject: [PATCH 2/4] =?UTF-8?q?refactor(system):=20=E7=A7=BB=E9=99=A4?= =?UTF-8?q?=E8=80=83=E5=8B=A4=E5=9C=B0=E5=9D=80=E7=BB=84=E6=9B=B4=E6=96=B0?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 删除了 AttendanceAddressGroupController 中的 updateAttendanceAddressGroup 方法 -优化了代码结构,提高了代码的可维护性 --- .../addressgroup/AttendanceAddressGroupController.java | 8 -------- 1 file changed, 8 deletions(-) diff --git a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/addressgroup/AttendanceAddressGroupController.java b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/addressgroup/AttendanceAddressGroupController.java index 5a026776..5a29928a 100644 --- a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/addressgroup/AttendanceAddressGroupController.java +++ b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/addressgroup/AttendanceAddressGroupController.java @@ -49,14 +49,6 @@ public class AttendanceAddressGroupController { return success(attendanceAddressGroupService.createAttendanceAddressGroup(createReqVO)); } -// @PutMapping("/update") -// @Operation(summary = "更新考勤地址组") -// @PreAuthorize("@ss.hasPermission('system:attendance-address-group:update')") -// public CommonResult updateAttendanceAddressGroup(@Valid @RequestBody AttendanceAddressGroupSaveReqVO updateReqVO) { -// attendanceAddressGroupService.updateAttendanceAddressGroup(updateReqVO); -// return success(true); -// } - @DeleteMapping("/delete") @Operation(summary = "删除考勤地址组") @Parameter(name = "id", description = "编号", required = true) From 018604a7351e65a465a3c9944933ba36e243fc29 Mon Sep 17 00:00:00 2001 From: aikai Date: Thu, 3 Jul 2025 11:26:04 +0800 Subject: [PATCH 3/4] =?UTF-8?q?fix(zn-module-smartfactory):=20=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D=E5=A4=84=E7=90=86=E7=BB=84=E6=9F=A5=E8=AF=A2=E8=AF=AD?= =?UTF-8?q?=E5=8F=A5=E4=B8=AD=E7=9A=84=E6=97=B6=E9=97=B4=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 将 STR_TO_DATE(c.date_str, '%Y-%m-%d') 中的表别名从 c 修改为 a- 修复了查询语句中创建时间条件的错误 --- .../main/resources/mapper/handlinggroup/HandlingGroupMapper.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zn-module-smartfactory/zn-module-smartfactory-biz/src/main/resources/mapper/handlinggroup/HandlingGroupMapper.xml b/zn-module-smartfactory/zn-module-smartfactory-biz/src/main/resources/mapper/handlinggroup/HandlingGroupMapper.xml index 6a3911ac..6351eb9f 100644 --- a/zn-module-smartfactory/zn-module-smartfactory-biz/src/main/resources/mapper/handlinggroup/HandlingGroupMapper.xml +++ b/zn-module-smartfactory/zn-module-smartfactory-biz/src/main/resources/mapper/handlinggroup/HandlingGroupMapper.xml @@ -107,7 +107,7 @@ - and STR_TO_DATE( c.date_str, '%Y-%m-%d' ) >= #{vo.createTime[0]} + and STR_TO_DATE( a.date_str, '%Y-%m-%d' ) >= #{vo.createTime[0]} and STR_TO_DATE( a.date_str, '%Y-%m-%d' ) <= #{vo.createTime[1]} From b17e26581813a53fb52eaefc4f468650c9393e8f Mon Sep 17 00:00:00 2001 From: aikai Date: Thu, 3 Jul 2025 11:45:55 +0800 Subject: [PATCH 4/4] =?UTF-8?q?refactor(smartfactory):=20=E4=BC=98?= =?UTF-8?q?=E5=8C=96=20HandlingGroupMapper=20=E5=B9=B6=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E4=B8=8A=E4=BC=A0=E5=88=86=E7=89=87=E5=A4=A7?= =?UTF-8?q?=E5=B0=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 移除了 HandlingGroupMapper 中未使用的导入语句 - 清理了 HandlingGroupMapper 中的冗余代码- 调整了 MultipartUploadServiceImpl 中的默认分片大小,从 5MB 增加到 200MB --- .../infra/service/file/MultipartUploadServiceImpl.java | 2 +- .../dal/mysql/handlinggroup/HandlingGroupMapper.java | 6 ------ 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/file/MultipartUploadServiceImpl.java b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/file/MultipartUploadServiceImpl.java index a2e2acac..436fb004 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/file/MultipartUploadServiceImpl.java +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/file/MultipartUploadServiceImpl.java @@ -46,7 +46,7 @@ public class MultipartUploadServiceImpl implements MultipartUploadService { // 3. 计算总分片数 Integer chunkSize = request.getChunkSize(); if (chunkSize == null || chunkSize <= 0) { - chunkSize = 50 * 1024 * 1024; // 默认5MB + chunkSize = 200 * 1024 * 1024; // 默认500MB } Integer totalChunks = (int) Math.ceil((double) request.getFileSize() / chunkSize); diff --git a/zn-module-smartfactory/zn-module-smartfactory-biz/src/main/java/cn/iocoder/yudao/module/smartfactory/dal/mysql/handlinggroup/HandlingGroupMapper.java b/zn-module-smartfactory/zn-module-smartfactory-biz/src/main/java/cn/iocoder/yudao/module/smartfactory/dal/mysql/handlinggroup/HandlingGroupMapper.java index 0b6d9491..1069ab1d 100644 --- a/zn-module-smartfactory/zn-module-smartfactory-biz/src/main/java/cn/iocoder/yudao/module/smartfactory/dal/mysql/handlinggroup/HandlingGroupMapper.java +++ b/zn-module-smartfactory/zn-module-smartfactory-biz/src/main/java/cn/iocoder/yudao/module/smartfactory/dal/mysql/handlinggroup/HandlingGroupMapper.java @@ -7,16 +7,10 @@ import cn.iocoder.yudao.module.smartfactory.controller.admin.handlinggroup.vo.Ha import cn.iocoder.yudao.module.smartfactory.controller.admin.handlinggroupamountspecifications.dto.HandlingGroupAmountSpecificationsPageReqDTO; import cn.iocoder.yudao.module.smartfactory.controller.admin.handlinggroupamountspecifications.vo.HandlingGroupAmountSpecificationsVO; import cn.iocoder.yudao.module.smartfactory.dal.dataobject.handlinggroup.HandlingGroupDO; -import cn.iocoder.yudao.module.smartfactory.dal.dataobject.handlinggroupamountspecifications.HandlingGroupAmountSpecificationsDO; import com.baomidou.mybatisplus.core.metadata.IPage; -import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; -import org.apache.ibatis.annotations.Result; -import org.apache.ibatis.annotations.Results; - -import java.util.List; /** * 搬运组 Mapper