From ced838f29fdbb94d836eacc1294da6797b150684 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BB=8A=E6=99=9A=E6=89=93=E8=80=81=E8=99=8E?= Date: Tue, 25 Jun 2024 04:42:14 +0000 Subject: [PATCH 1/4] =?UTF-8?q?fix(bpm):=20=E5=8F=91=E8=B5=B7=E7=94=A8?= =?UTF-8?q?=E6=88=B7=E5=8F=AF=E8=83=BD=E6=B2=A1=E6=9C=89=E9=83=A8=E9=97=A8?= =?UTF-8?q?=20=E5=8F=91=E8=B5=B7=E7=94=A8=E6=88=B7=E5=8F=AF=E8=83=BD?= =?UTF-8?q?=E6=B2=A1=E6=9C=89=E9=83=A8=E9=97=A8=EF=BC=8C=E5=AF=BC=E8=87=B4?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E9=83=A8=E9=97=A8=E4=BF=A1=E6=81=AF=E6=97=B6?= =?UTF-8?q?=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 今晚打老虎 --- .../bpm/controller/admin/task/BpmProcessInstanceController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/BpmProcessInstanceController.java b/yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/BpmProcessInstanceController.java index 819ce366f..9b1b9cf24 100644 --- a/yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/BpmProcessInstanceController.java +++ b/yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/BpmProcessInstanceController.java @@ -135,7 +135,7 @@ public class BpmProcessInstanceController { processDefinitionService.getProcessDefinitionBpmnModel(processInstance.getProcessDefinitionId())); AdminUserRespDTO startUser = adminUserApi.getUser(NumberUtils.parseLong(processInstance.getStartUserId())).getCheckedData(); DeptRespDTO dept = null; - if (startUser != null) { + if (startUser != null && startUser.getDeptId() != null) { dept = deptApi.getDept(startUser.getDeptId()).getCheckedData(); } return success(BpmProcessInstanceConvert.INSTANCE.buildProcessInstance(processInstance, From bb2a10ba4a667883af078ca9e2ddbe4689b8b7f4 Mon Sep 17 00:00:00 2001 From: OnPeaceOfMind Date: Tue, 16 Jul 2024 06:12:01 +0000 Subject: [PATCH 2/4] =?UTF-8?q?=E3=80=90=E4=BF=AE=E5=A4=8D=E3=80=91AI?= =?UTF-8?q?=E6=A8=A1=E5=9D=97redis=E9=85=8D=E7=BD=AE=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: OnPeaceOfMind --- .../src/main/resources/application-local.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/yudao-module-ai/yudao-module-ai-biz/src/main/resources/application-local.yaml b/yudao-module-ai/yudao-module-ai-biz/src/main/resources/application-local.yaml index dbfdf0cfc..dfc7f41db 100644 --- a/yudao-module-ai/yudao-module-ai-biz/src/main/resources/application-local.yaml +++ b/yudao-module-ai/yudao-module-ai-biz/src/main/resources/application-local.yaml @@ -75,8 +75,8 @@ spring: password: 123456 # Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优 - redis: - data: + data: + redis: host: 127.0.0.1 # 地址 port: 6379 # 端口 database: 0 # 数据库索引 From 40800bd728de42d73ca666bb4e5ea726b0a94a9a Mon Sep 17 00:00:00 2001 From: OnPeaceOfMind Date: Tue, 16 Jul 2024 06:14:38 +0000 Subject: [PATCH 3/4] =?UTF-8?q?=E3=80=90=E4=BE=9D=E8=B5=96=E3=80=91spring?= =?UTF-8?q?=20boot=20from=203.2.2=20to=203.3.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: OnPeaceOfMind --- yudao-dependencies/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yudao-dependencies/pom.xml b/yudao-dependencies/pom.xml index 947d3da08..f2a813688 100644 --- a/yudao-dependencies/pom.xml +++ b/yudao-dependencies/pom.xml @@ -17,7 +17,7 @@ 2.1.0-snapshot 1.6.0 - 3.2.2 + 3.3.1 2023.0.3 2023.0.1.2 From c9a64030da1353d6b00b057750d72c5f56a2a86e Mon Sep 17 00:00:00 2001 From: YunaiV Date: Sat, 27 Jul 2024 15:41:35 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E3=80=90=E5=90=8C=E6=AD=A5=E3=80=91BOOT=20?= =?UTF-8?q?=E5=92=8C=20CLOUD=20=E7=9A=84=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../apilog/core/filter/ApiAccessLogFilter.java | 2 +- .../yudao/module/bpm/enums/DictTypeConstants.java | 3 --- .../vo/receivable/CrmReceivableRespVO.java | 13 +++++++------ .../controller/admin/config/ConfigController.java | 2 +- .../framework/file/core/client/s3/S3FileClient.java | 12 ++++++++++++ .../file/core/client/s3/S3FileClientConfig.java | 1 + .../module/infra/service/config/ConfigService.java | 2 +- .../src/main/resources/codegen/sql/h2.vm | 2 +- .../main/resources/codegen/vue/views/index.vue.vm | 4 ++-- .../main/resources/codegen/vue3/views/index.vue.vm | 4 ++-- .../resources/codegen/vue3_vben/views/index.vue.vm | 3 ++- .../trade/convert/order/TradeOrderConvert.java | 2 +- .../dal/mysql/brokerage/BrokerageRecordMapper.java | 4 ++-- 13 files changed, 33 insertions(+), 21 deletions(-) diff --git a/yudao-framework/yudao-spring-boot-starter-web/src/main/java/cn/iocoder/yudao/framework/apilog/core/filter/ApiAccessLogFilter.java b/yudao-framework/yudao-spring-boot-starter-web/src/main/java/cn/iocoder/yudao/framework/apilog/core/filter/ApiAccessLogFilter.java index a4c05a366..d0e84e837 100644 --- a/yudao-framework/yudao-spring-boot-starter-web/src/main/java/cn/iocoder/yudao/framework/apilog/core/filter/ApiAccessLogFilter.java +++ b/yudao-framework/yudao-spring-boot-starter-web/src/main/java/cn/iocoder/yudao/framework/apilog/core/filter/ApiAccessLogFilter.java @@ -181,7 +181,7 @@ public class ApiAccessLogFilter extends ApiRequestFilter { // ========== 请求和响应的脱敏逻辑,移除类似 password、token 等敏感字段 ========== private static String sanitizeMap(Map map, String[] sanitizeKeys) { - if (CollUtil.isNotEmpty(map)) { + if (CollUtil.isEmpty(map)) { return null; } if (sanitizeKeys != null) { diff --git a/yudao-module-bpm/yudao-module-bpm-api/src/main/java/cn/iocoder/yudao/module/bpm/enums/DictTypeConstants.java b/yudao-module-bpm/yudao-module-bpm-api/src/main/java/cn/iocoder/yudao/module/bpm/enums/DictTypeConstants.java index 7abb3e1db..c00638694 100644 --- a/yudao-module-bpm/yudao-module-bpm-api/src/main/java/cn/iocoder/yudao/module/bpm/enums/DictTypeConstants.java +++ b/yudao-module-bpm/yudao-module-bpm-api/src/main/java/cn/iocoder/yudao/module/bpm/enums/DictTypeConstants.java @@ -7,7 +7,4 @@ package cn.iocoder.yudao.module.bpm.enums; */ public interface DictTypeConstants { - String TASK_ASSIGN_RULE_TYPE = "bpm_task_assign_rule_type"; // 任务分配规则类型 - String TASK_ASSIGN_SCRIPT = "bpm_task_assign_script"; // 任务分配自定义脚本 - } diff --git a/yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/vo/receivable/CrmReceivableRespVO.java b/yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/vo/receivable/CrmReceivableRespVO.java index 12dcbaa02..6d712e3a5 100644 --- a/yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/vo/receivable/CrmReceivableRespVO.java +++ b/yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/vo/receivable/CrmReceivableRespVO.java @@ -1,6 +1,9 @@ package cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.receivable; +import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat; +import cn.iocoder.yudao.framework.excel.core.convert.DictConvert; import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractRespVO; +import cn.iocoder.yudao.module.crm.enums.DictTypeConstants; import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; import com.alibaba.excel.annotation.ExcelProperty; import io.swagger.v3.oas.annotations.media.Schema; @@ -27,7 +30,8 @@ public class CrmReceivableRespVO { private Long planId; @Schema(description = "回款方式", example = "2") - @ExcelProperty("回款方式") + @ExcelProperty(value = "回款方式", converter = DictConvert.class) + @DictFormat(DictTypeConstants.CRM_RECEIVABLE_RETURN_TYPE) private Integer returnType; @Schema(description = "回款金额", requiredMode = Schema.RequiredMode.REQUIRED, example = "9000") @@ -39,7 +43,6 @@ public class CrmReceivableRespVO { private LocalDateTime returnTime; @Schema(description = "客户编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "2") - @ExcelProperty("客户编号") private Long customerId; @Schema(description = "客户名字", requiredMode = Schema.RequiredMode.REQUIRED, example = "test") @ExcelProperty("客户名字") @@ -49,11 +52,9 @@ public class CrmReceivableRespVO { @ExcelProperty("合同编号") private Long contractId; @Schema(description = "合同信息") - @ExcelProperty("合同信息") private CrmContractRespVO contract; @Schema(description = "负责人的用户编号", example = "25682") - @ExcelProperty("负责人的用户编号") private Long ownerUserId; @Schema(description = "负责人名字", example = "25682") @ExcelProperty("负责人名字") @@ -67,7 +68,8 @@ public class CrmReceivableRespVO { private String processInstanceId; @Schema(description = "审批状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") - @ExcelProperty("审批状态") + @ExcelProperty(value = "审批状态", converter = DictConvert.class) + @DictFormat(DictTypeConstants.CRM_AUDIT_STATUS) private Integer auditStatus; @Schema(description = "工作流编号", example = "备注") @@ -83,7 +85,6 @@ public class CrmReceivableRespVO { private LocalDateTime updateTime; @Schema(description = "创建人", example = "25682") - @ExcelProperty("创建人") private String creator; @Schema(description = "创建人名字", example = "test") @ExcelProperty("创建人名字") diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/ConfigController.java b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/ConfigController.java index d3af2a954..43e64c02a 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/ConfigController.java +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/ConfigController.java @@ -96,7 +96,7 @@ public class ConfigController { @Operation(summary = "导出参数配置") @PreAuthorize("@ss.hasPermission('infra:config:export')") @ApiAccessLog(operateType = EXPORT) - public void exportConfig(@Valid ConfigPageReqVO exportReqVO, + public void exportConfig(ConfigPageReqVO exportReqVO, HttpServletResponse response) throws IOException { exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); List list = configService.getConfigPage(exportReqVO).getList(); diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClient.java b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClient.java index 67995caa2..43ff2733b 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClient.java +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClient.java @@ -37,6 +37,7 @@ public class S3FileClient extends AbstractFileClient { .region(buildRegion()) // Region .credentials(config.getAccessKey(), config.getAccessSecret()) // 认证密钥 .build(); + enableVirtualStyleEndpoint(); } /** @@ -86,6 +87,17 @@ public class S3FileClient extends AbstractFileClient { return null; } + /** + * 开启 VirtualStyle 模式 + */ + private void enableVirtualStyleEndpoint() { + if (StrUtil.containsAll(config.getEndpoint(), + S3FileClientConfig.ENDPOINT_TENCENT, // 腾讯云 https://cloud.tencent.com/document/product/436/41284 + S3FileClientConfig.ENDPOINT_VOLCES)) { // 火山云 https://www.volcengine.com/docs/6349/1288493 + client.enableVirtualStyleEndpoint(); + } + } + @Override public String upload(byte[] content, String path, String type) throws Exception { // 执行上传 diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClientConfig.java b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClientConfig.java index 3d9e3c561..d25f3deb2 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClientConfig.java +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClientConfig.java @@ -19,6 +19,7 @@ public class S3FileClientConfig implements FileClientConfig { public static final String ENDPOINT_QINIU = "qiniucs.com"; public static final String ENDPOINT_ALIYUN = "aliyuncs.com"; public static final String ENDPOINT_TENCENT = "myqcloud.com"; + public static final String ENDPOINT_VOLCES = "volces.com"; // 火山云(字节) /** * 节点地址 diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/config/ConfigService.java b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/config/ConfigService.java index 087c4669d..8ff2fb168 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/config/ConfigService.java +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/config/ConfigService.java @@ -58,6 +58,6 @@ public interface ConfigService { * @param reqVO 分页条件 * @return 分页列表 */ - PageResult getConfigPage(@Valid ConfigPageReqVO reqVO); + PageResult getConfigPage(ConfigPageReqVO reqVO); } diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/sql/h2.vm b/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/sql/h2.vm index b22389b0b..a073fdba1 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/sql/h2.vm +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/sql/h2.vm @@ -23,7 +23,7 @@ CREATE TABLE IF NOT EXISTS "${table.tableName.toLowerCase()}" ( "${column.columnName}" ${dataType} DEFAULT '', #elseif (${column.columnName} == 'deleted') "deleted" bit NOT NULL DEFAULT FALSE, - #elseif (${column.columnName} == 'tenantId') + #elseif (${column.columnName} == 'tenant_id') "tenant_id" bigint NOT NULL DEFAULT 0, #else "${column.columnName.toLowerCase()}" ${dataType}#if (${column.nullable} == false) NOT NULL#end, diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue/views/index.vue.vm b/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue/views/index.vue.vm index 2328007a0..9c1e124dc 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue/views/index.vue.vm +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue/views/index.vue.vm @@ -306,8 +306,8 @@ export default { await this.#[[$modal]]#.confirm('是否确认导出所有${table.classComment}数据项?'); try { this.exportLoading = true; - const res = await ${simpleClassName}Api.export${simpleClassName}Excel(this.queryParams); - this.#[[$]]#download.excel(res.data, '${table.classComment}.xls'); + const data = await ${simpleClassName}Api.export${simpleClassName}Excel(this.queryParams); + this.#[[$]]#download.excel(data, '${table.classComment}.xls'); } catch { } finally { this.exportLoading = false; diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/index.vue.vm b/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/index.vue.vm index 361d379fa..399b58e34 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/index.vue.vm +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/index.vue.vm @@ -74,7 +74,7 @@ start-placeholder="开始日期" end-placeholder="结束日期" :default-time="[new Date('1 00:00:00'), new Date('1 23:59:59')]" - class="!w-240px" + class="!w-220px" /> #end @@ -181,7 +181,7 @@ #end #end #end - +