Commit 20583417a4c6a17655104284ef9b231ff3c3a4d1
1 parent
000b6cf4
【重构】V2 操作日志转正,基于注解的可使用变量、可以自定义函数的通用操作日志组件
Showing
84 changed files
with
223 additions
and
484 deletions
yudao-dependencies/pom.xml
| @@ -91,11 +91,6 @@ | @@ -91,11 +91,6 @@ | ||
| 91 | 91 | ||
| 92 | <!-- 业务组件 --> | 92 | <!-- 业务组件 --> |
| 93 | <dependency> | 93 | <dependency> |
| 94 | - <groupId>cn.iocoder.boot</groupId> | ||
| 95 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 96 | - <version>${revision}</version> | ||
| 97 | - </dependency> | ||
| 98 | - <dependency> | ||
| 99 | <groupId>io.github.mouzt</groupId> | 94 | <groupId>io.github.mouzt</groupId> |
| 100 | <artifactId>bizlog-sdk</artifactId> | 95 | <artifactId>bizlog-sdk</artifactId> |
| 101 | <version>${bizlog-sdk.version}</version> | 96 | <version>${bizlog-sdk.version}</version> |
yudao-framework/pom.xml
| @@ -25,7 +25,6 @@ | @@ -25,7 +25,6 @@ | ||
| 25 | <module>yudao-spring-boot-starter-excel</module> | 25 | <module>yudao-spring-boot-starter-excel</module> |
| 26 | <module>yudao-spring-boot-starter-test</module> | 26 | <module>yudao-spring-boot-starter-test</module> |
| 27 | 27 | ||
| 28 | - <module>yudao-spring-boot-starter-biz-operatelog</module> | ||
| 29 | <module>yudao-spring-boot-starter-biz-tenant</module> | 28 | <module>yudao-spring-boot-starter-biz-tenant</module> |
| 30 | <module>yudao-spring-boot-starter-biz-data-permission</module> | 29 | <module>yudao-spring-boot-starter-biz-data-permission</module> |
| 31 | <module>yudao-spring-boot-starter-biz-ip</module> | 30 | <module>yudao-spring-boot-starter-biz-ip</module> |
yudao-framework/yudao-spring-boot-starter-biz-operatelog/pom.xml deleted
| 1 | -<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | -<project xmlns="http://maven.apache.org/POM/4.0.0" | ||
| 3 | - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
| 4 | - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
| 5 | - <parent> | ||
| 6 | - <groupId>cn.iocoder.boot</groupId> | ||
| 7 | - <artifactId>yudao-framework</artifactId> | ||
| 8 | - <version>${revision}</version> | ||
| 9 | - </parent> | ||
| 10 | - <modelVersion>4.0.0</modelVersion> | ||
| 11 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 12 | - <packaging>jar</packaging> | ||
| 13 | - | ||
| 14 | - <name>${project.artifactId}</name> | ||
| 15 | - <description>操作日志</description> | ||
| 16 | - <url>https://github.com/YunaiV/ruoyi-vue-pro</url> | ||
| 17 | - | ||
| 18 | - <dependencies> | ||
| 19 | - <dependency> | ||
| 20 | - <groupId>cn.iocoder.boot</groupId> | ||
| 21 | - <artifactId>yudao-common</artifactId> | ||
| 22 | - </dependency> | ||
| 23 | - | ||
| 24 | - <!-- Spring 核心 --> | ||
| 25 | - <dependency> | ||
| 26 | - <groupId>org.springframework.boot</groupId> | ||
| 27 | - <artifactId>spring-boot-starter-aop</artifactId> | ||
| 28 | - </dependency> | ||
| 29 | - | ||
| 30 | - <!-- Web 相关 --> | ||
| 31 | - <dependency> | ||
| 32 | - <groupId>cn.iocoder.boot</groupId> | ||
| 33 | - <artifactId>yudao-spring-boot-starter-web</artifactId> | ||
| 34 | - <scope>provided</scope> | ||
| 35 | - </dependency> | ||
| 36 | - | ||
| 37 | - <!-- 业务组件 --> | ||
| 38 | - <dependency> | ||
| 39 | - <groupId>cn.iocoder.boot</groupId> | ||
| 40 | - <artifactId>yudao-module-system-api</artifactId> | ||
| 41 | - <version>${revision}</version> | ||
| 42 | - </dependency> | ||
| 43 | - | ||
| 44 | - <!-- 工具类相关 --> | ||
| 45 | - <dependency> | ||
| 46 | - <groupId>com.google.guava</groupId> | ||
| 47 | - <artifactId>guava</artifactId> | ||
| 48 | - </dependency> | ||
| 49 | - | ||
| 50 | - </dependencies> | ||
| 51 | - | ||
| 52 | -</project> |
yudao-framework/yudao-spring-boot-starter-biz-operatelog/src/main/java/cn/iocoder/yudao/framework/operatelog/core/annotations/OperateLog.java deleted
| 1 | -package cn.iocoder.yudao.framework.operatelog.core.annotations; | ||
| 2 | - | ||
| 3 | -import cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum; | ||
| 4 | -import io.swagger.v3.oas.annotations.Operation; | ||
| 5 | -import io.swagger.v3.oas.annotations.tags.Tag; | ||
| 6 | - | ||
| 7 | -import java.lang.annotation.ElementType; | ||
| 8 | -import java.lang.annotation.Retention; | ||
| 9 | -import java.lang.annotation.RetentionPolicy; | ||
| 10 | -import java.lang.annotation.Target; | ||
| 11 | - | ||
| 12 | -/** | ||
| 13 | - * 操作日志注解 | ||
| 14 | - * | ||
| 15 | - * @author 芋道源码 | ||
| 16 | - */ | ||
| 17 | -@Target({ElementType.METHOD}) | ||
| 18 | -@Retention(RetentionPolicy.RUNTIME) | ||
| 19 | -public @interface OperateLog { | ||
| 20 | - | ||
| 21 | - // ========== 模块字段 ========== | ||
| 22 | - | ||
| 23 | - /** | ||
| 24 | - * 操作模块 | ||
| 25 | - * | ||
| 26 | - * 为空时,会尝试读取 {@link Tag#name()} 属性 | ||
| 27 | - */ | ||
| 28 | - String module() default ""; | ||
| 29 | - /** | ||
| 30 | - * 操作名 | ||
| 31 | - * | ||
| 32 | - * 为空时,会尝试读取 {@link Operation#summary()} 属性 | ||
| 33 | - */ | ||
| 34 | - String name() default ""; | ||
| 35 | - /** | ||
| 36 | - * 操作分类 | ||
| 37 | - * | ||
| 38 | - * 实际并不是数组,因为枚举不能设置 null 作为默认值 | ||
| 39 | - */ | ||
| 40 | - OperateTypeEnum[] type() default {}; | ||
| 41 | - | ||
| 42 | - // ========== 开关字段 ========== | ||
| 43 | - | ||
| 44 | - /** | ||
| 45 | - * 是否记录操作日志 | ||
| 46 | - */ | ||
| 47 | - boolean enable() default true; | ||
| 48 | - /** | ||
| 49 | - * 是否记录方法参数 | ||
| 50 | - */ | ||
| 51 | - boolean logArgs() default true; | ||
| 52 | - /** | ||
| 53 | - * 是否记录方法结果的数据 | ||
| 54 | - */ | ||
| 55 | - boolean logResultData() default true; | ||
| 56 | - | ||
| 57 | -} |
yudao-framework/yudao-spring-boot-starter-biz-operatelog/src/main/java/cn/iocoder/yudao/framework/operatelog/core/enums/OperateTypeEnum.java deleted
| 1 | -package cn.iocoder.yudao.framework.operatelog.core.enums; | ||
| 2 | - | ||
| 3 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 4 | -import lombok.AllArgsConstructor; | ||
| 5 | -import lombok.Getter; | ||
| 6 | - | ||
| 7 | -/** | ||
| 8 | - * 操作日志的操作类型 | ||
| 9 | - * | ||
| 10 | - * @author ruoyi | ||
| 11 | - */ | ||
| 12 | -@Getter | ||
| 13 | -@AllArgsConstructor | ||
| 14 | -public enum OperateTypeEnum { | ||
| 15 | - | ||
| 16 | - /** | ||
| 17 | - * 查询 | ||
| 18 | - * | ||
| 19 | - * 绝大多数情况下,不会记录查询动作,因为过于大量显得没有意义。 | ||
| 20 | - * 在有需要的时候,通过声明 {@link OperateLog} 注解来记录 | ||
| 21 | - */ | ||
| 22 | - GET(1), | ||
| 23 | - /** | ||
| 24 | - * 新增 | ||
| 25 | - */ | ||
| 26 | - CREATE(2), | ||
| 27 | - /** | ||
| 28 | - * 修改 | ||
| 29 | - */ | ||
| 30 | - UPDATE(3), | ||
| 31 | - /** | ||
| 32 | - * 删除 | ||
| 33 | - */ | ||
| 34 | - DELETE(4), | ||
| 35 | - /** | ||
| 36 | - * 导出 | ||
| 37 | - */ | ||
| 38 | - EXPORT(5), | ||
| 39 | - /** | ||
| 40 | - * 导入 | ||
| 41 | - */ | ||
| 42 | - IMPORT(6), | ||
| 43 | - /** | ||
| 44 | - * 其它 | ||
| 45 | - * | ||
| 46 | - * 在无法归类时,可以选择使用其它。因为还有操作名可以进一步标识 | ||
| 47 | - */ | ||
| 48 | - OTHER(0); | ||
| 49 | - | ||
| 50 | - /** | ||
| 51 | - * 类型 | ||
| 52 | - */ | ||
| 53 | - private final Integer type; | ||
| 54 | - | ||
| 55 | -} |
yudao-module-bpm/yudao-module-bpm-biz/pom.xml
| @@ -30,10 +30,6 @@ | @@ -30,10 +30,6 @@ | ||
| 30 | <!-- 业务组件 --> | 30 | <!-- 业务组件 --> |
| 31 | <dependency> | 31 | <dependency> |
| 32 | <groupId>cn.iocoder.boot</groupId> | 32 | <groupId>cn.iocoder.boot</groupId> |
| 33 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 34 | - </dependency> | ||
| 35 | - <dependency> | ||
| 36 | - <groupId>cn.iocoder.boot</groupId> | ||
| 37 | <artifactId>yudao-spring-boot-starter-biz-data-permission</artifactId> | 33 | <artifactId>yudao-spring-boot-starter-biz-data-permission</artifactId> |
| 38 | </dependency> | 34 | </dependency> |
| 39 | <dependency> | 35 | <dependency> |
yudao-module-crm/yudao-module-crm-biz/pom.xml
| @@ -36,10 +36,6 @@ | @@ -36,10 +36,6 @@ | ||
| 36 | <!-- 业务组件 --> | 36 | <!-- 业务组件 --> |
| 37 | <dependency> | 37 | <dependency> |
| 38 | <groupId>cn.iocoder.boot</groupId> | 38 | <groupId>cn.iocoder.boot</groupId> |
| 39 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 40 | - </dependency> | ||
| 41 | - <dependency> | ||
| 42 | - <groupId>cn.iocoder.boot</groupId> | ||
| 43 | <artifactId>yudao-spring-boot-starter-biz-ip</artifactId> | 39 | <artifactId>yudao-spring-boot-starter-biz-ip</artifactId> |
| 44 | </dependency> | 40 | </dependency> |
| 45 | <dependency> | 41 | <dependency> |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/business/CrmBusinessController.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.business; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.business; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 7 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | 8 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.crm.controller.admin.business.vo.business.*; | 11 | import cn.iocoder.yudao.module.crm.controller.admin.business.vo.business.*; |
| 12 | import cn.iocoder.yudao.module.crm.dal.dataobject.business.CrmBusinessDO; | 12 | import cn.iocoder.yudao.module.crm.dal.dataobject.business.CrmBusinessDO; |
| 13 | import cn.iocoder.yudao.module.crm.dal.dataobject.business.CrmBusinessProductDO; | 13 | import cn.iocoder.yudao.module.crm.dal.dataobject.business.CrmBusinessProductDO; |
| @@ -39,11 +39,11 @@ import java.util.List; | @@ -39,11 +39,11 @@ import java.util.List; | ||
| 39 | import java.util.Map; | 39 | import java.util.Map; |
| 40 | import java.util.stream.Stream; | 40 | import java.util.stream.Stream; |
| 41 | 41 | ||
| 42 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 42 | import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; | 43 | import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; |
| 43 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 44 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 44 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; | 45 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; |
| 45 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; | 46 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| 46 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 47 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | 47 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| 48 | import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.CUSTOMER_NOT_EXISTS; | 48 | import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.CUSTOMER_NOT_EXISTS; |
| 49 | 49 | ||
| @@ -167,7 +167,7 @@ public class CrmBusinessController { | @@ -167,7 +167,7 @@ public class CrmBusinessController { | ||
| 167 | @GetMapping("/export-excel") | 167 | @GetMapping("/export-excel") |
| 168 | @Operation(summary = "导出商机 Excel") | 168 | @Operation(summary = "导出商机 Excel") |
| 169 | @PreAuthorize("@ss.hasPermission('crm:business:export')") | 169 | @PreAuthorize("@ss.hasPermission('crm:business:export')") |
| 170 | - @OperateLog(type = EXPORT) | 170 | + @ApiAccessLog(operateType = EXPORT) |
| 171 | public void exportBusinessExcel(@Valid CrmBusinessPageReqVO exportReqVO, | 171 | public void exportBusinessExcel(@Valid CrmBusinessPageReqVO exportReqVO, |
| 172 | HttpServletResponse response) throws IOException { | 172 | HttpServletResponse response) throws IOException { |
| 173 | exportReqVO.setPageSize(PAGE_SIZE_NONE); | 173 | exportReqVO.setPageSize(PAGE_SIZE_NONE); |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/clue/CrmClueController.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.clue; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.clue; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| @@ -8,7 +9,6 @@ import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | @@ -8,7 +9,6 @@ import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | ||
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | import cn.iocoder.yudao.framework.ip.core.utils.AreaUtils; | 11 | import cn.iocoder.yudao.framework.ip.core.utils.AreaUtils; |
| 11 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 12 | import cn.iocoder.yudao.module.crm.controller.admin.clue.vo.CrmCluePageReqVO; | 12 | import cn.iocoder.yudao.module.crm.controller.admin.clue.vo.CrmCluePageReqVO; |
| 13 | import cn.iocoder.yudao.module.crm.controller.admin.clue.vo.CrmClueRespVO; | 13 | import cn.iocoder.yudao.module.crm.controller.admin.clue.vo.CrmClueRespVO; |
| 14 | import cn.iocoder.yudao.module.crm.controller.admin.clue.vo.CrmClueSaveReqVO; | 14 | import cn.iocoder.yudao.module.crm.controller.admin.clue.vo.CrmClueSaveReqVO; |
| @@ -37,11 +37,11 @@ import java.util.List; | @@ -37,11 +37,11 @@ import java.util.List; | ||
| 37 | import java.util.Map; | 37 | import java.util.Map; |
| 38 | import java.util.stream.Stream; | 38 | import java.util.stream.Stream; |
| 39 | 39 | ||
| 40 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 41 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 41 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; | 42 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; |
| 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertListByFlatMap; | 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertListByFlatMap; |
| 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 44 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 44 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 45 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | 45 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| 46 | import static java.util.Collections.singletonList; | 46 | import static java.util.Collections.singletonList; |
| 47 | 47 | ||
| @@ -112,7 +112,7 @@ public class CrmClueController { | @@ -112,7 +112,7 @@ public class CrmClueController { | ||
| 112 | @GetMapping("/export-excel") | 112 | @GetMapping("/export-excel") |
| 113 | @Operation(summary = "导出线索 Excel") | 113 | @Operation(summary = "导出线索 Excel") |
| 114 | @PreAuthorize("@ss.hasPermission('crm:clue:export')") | 114 | @PreAuthorize("@ss.hasPermission('crm:clue:export')") |
| 115 | - @OperateLog(type = EXPORT) | 115 | + @ApiAccessLog(operateType = EXPORT) |
| 116 | public void exportClueExcel(@Valid CrmCluePageReqVO pageReqVO, HttpServletResponse response) throws IOException { | 116 | public void exportClueExcel(@Valid CrmCluePageReqVO pageReqVO, HttpServletResponse response) throws IOException { |
| 117 | pageReqVO.setPageSize(PAGE_SIZE_NONE); | 117 | pageReqVO.setPageSize(PAGE_SIZE_NONE); |
| 118 | List<CrmClueDO> list = clueService.getCluePage(pageReqVO, getLoginUserId()).getList(); | 118 | List<CrmClueDO> list = clueService.getCluePage(pageReqVO, getLoginUserId()).getList(); |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/contact/CrmContactController.java
| @@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.crm.controller.admin.contact; | @@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.crm.controller.admin.contact; | ||
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | import cn.hutool.core.lang.Assert; | 4 | import cn.hutool.core.lang.Assert; |
| 5 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| @@ -9,7 +10,6 @@ import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | @@ -9,7 +10,6 @@ import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | ||
| 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 10 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 11 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 11 | import cn.iocoder.yudao.framework.ip.core.utils.AreaUtils; | 12 | import cn.iocoder.yudao.framework.ip.core.utils.AreaUtils; |
| 12 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 13 | import cn.iocoder.yudao.module.crm.controller.admin.contact.vo.*; | 13 | import cn.iocoder.yudao.module.crm.controller.admin.contact.vo.*; |
| 14 | import cn.iocoder.yudao.module.crm.dal.dataobject.contact.CrmContactDO; | 14 | import cn.iocoder.yudao.module.crm.dal.dataobject.contact.CrmContactDO; |
| 15 | import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerDO; | 15 | import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerDO; |
| @@ -37,11 +37,11 @@ import java.util.List; | @@ -37,11 +37,11 @@ import java.util.List; | ||
| 37 | import java.util.Map; | 37 | import java.util.Map; |
| 38 | import java.util.stream.Stream; | 38 | import java.util.stream.Stream; |
| 39 | 39 | ||
| 40 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 41 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 41 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; | 42 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; |
| 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; | 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| 43 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; | 44 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; |
| 44 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 45 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | 45 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| 46 | import static java.util.Collections.singletonList; | 46 | import static java.util.Collections.singletonList; |
| 47 | 47 | ||
| @@ -73,7 +73,6 @@ public class CrmContactController { | @@ -73,7 +73,6 @@ public class CrmContactController { | ||
| 73 | 73 | ||
| 74 | @PutMapping("/update") | 74 | @PutMapping("/update") |
| 75 | @Operation(summary = "更新联系人") | 75 | @Operation(summary = "更新联系人") |
| 76 | - @OperateLog(enable = false) | ||
| 77 | @PreAuthorize("@ss.hasPermission('crm:contact:update')") | 76 | @PreAuthorize("@ss.hasPermission('crm:contact:update')") |
| 78 | public CommonResult<Boolean> updateContact(@Valid @RequestBody CrmContactSaveReqVO updateReqVO) { | 77 | public CommonResult<Boolean> updateContact(@Valid @RequestBody CrmContactSaveReqVO updateReqVO) { |
| 79 | contactService.updateContact(updateReqVO); | 78 | contactService.updateContact(updateReqVO); |
| @@ -142,7 +141,7 @@ public class CrmContactController { | @@ -142,7 +141,7 @@ public class CrmContactController { | ||
| 142 | @GetMapping("/export-excel") | 141 | @GetMapping("/export-excel") |
| 143 | @Operation(summary = "导出联系人 Excel") | 142 | @Operation(summary = "导出联系人 Excel") |
| 144 | @PreAuthorize("@ss.hasPermission('crm:contact:export')") | 143 | @PreAuthorize("@ss.hasPermission('crm:contact:export')") |
| 145 | - @OperateLog(type = EXPORT) | 144 | + @ApiAccessLog(operateType = EXPORT) |
| 146 | public void exportContactExcel(@Valid CrmContactPageReqVO exportReqVO, | 145 | public void exportContactExcel(@Valid CrmContactPageReqVO exportReqVO, |
| 147 | HttpServletResponse response) throws IOException { | 146 | HttpServletResponse response) throws IOException { |
| 148 | exportReqVO.setPageNo(PAGE_SIZE_NONE); | 147 | exportReqVO.setPageNo(PAGE_SIZE_NONE); |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/contract/CrmContractController.java
| @@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.crm.controller.admin.contract; | @@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.crm.controller.admin.contract; | ||
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | import cn.hutool.core.lang.Assert; | 4 | import cn.hutool.core.lang.Assert; |
| 5 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 8 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| @@ -9,7 +10,6 @@ import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | @@ -9,7 +10,6 @@ import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | ||
| 9 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | 10 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; |
| 10 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 11 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 11 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 12 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 12 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 13 | import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractPageReqVO; | 13 | import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractPageReqVO; |
| 14 | import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractRespVO; | 14 | import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractRespVO; |
| 15 | import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractSaveReqVO; | 15 | import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractSaveReqVO; |
| @@ -47,10 +47,10 @@ import java.util.List; | @@ -47,10 +47,10 @@ import java.util.List; | ||
| 47 | import java.util.Map; | 47 | import java.util.Map; |
| 48 | import java.util.stream.Stream; | 48 | import java.util.stream.Stream; |
| 49 | 49 | ||
| 50 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 50 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 51 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 51 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; | 52 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| 52 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; | 53 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; |
| 53 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 54 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | 54 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| 55 | import static java.util.Collections.singletonList; | 55 | import static java.util.Collections.singletonList; |
| 56 | 56 | ||
| @@ -154,7 +154,7 @@ public class CrmContractController { | @@ -154,7 +154,7 @@ public class CrmContractController { | ||
| 154 | @GetMapping("/export-excel") | 154 | @GetMapping("/export-excel") |
| 155 | @Operation(summary = "导出合同 Excel") | 155 | @Operation(summary = "导出合同 Excel") |
| 156 | @PreAuthorize("@ss.hasPermission('crm:contract:export')") | 156 | @PreAuthorize("@ss.hasPermission('crm:contract:export')") |
| 157 | - @OperateLog(type = EXPORT) | 157 | + @ApiAccessLog(operateType = EXPORT) |
| 158 | public void exportContractExcel(@Valid CrmContractPageReqVO exportReqVO, | 158 | public void exportContractExcel(@Valid CrmContractPageReqVO exportReqVO, |
| 159 | HttpServletResponse response) throws IOException { | 159 | HttpServletResponse response) throws IOException { |
| 160 | PageResult<CrmContractDO> pageResult = contractService.getContractPage(exportReqVO, getLoginUserId()); | 160 | PageResult<CrmContractDO> pageResult = contractService.getContractPage(exportReqVO, getLoginUserId()); |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/customer/CrmCustomerController.java
| @@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.crm.controller.admin.customer; | @@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.crm.controller.admin.customer; | ||
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | import cn.hutool.core.map.MapUtil; | 4 | import cn.hutool.core.map.MapUtil; |
| 5 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 5 | import cn.iocoder.yudao.framework.common.core.KeyValue; | 6 | import cn.iocoder.yudao.framework.common.core.KeyValue; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 8 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| @@ -14,7 +15,6 @@ import cn.iocoder.yudao.framework.excel.core.enums.ExcelColumn; | @@ -14,7 +15,6 @@ import cn.iocoder.yudao.framework.excel.core.enums.ExcelColumn; | ||
| 14 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 15 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 15 | import cn.iocoder.yudao.framework.ip.core.Area; | 16 | import cn.iocoder.yudao.framework.ip.core.Area; |
| 16 | import cn.iocoder.yudao.framework.ip.core.utils.AreaUtils; | 17 | import cn.iocoder.yudao.framework.ip.core.utils.AreaUtils; |
| 17 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 18 | import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.customer.*; | 18 | import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.customer.*; |
| 19 | import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerDO; | 19 | import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerDO; |
| 20 | import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerPoolConfigDO; | 20 | import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerPoolConfigDO; |
| @@ -44,10 +44,10 @@ import java.util.List; | @@ -44,10 +44,10 @@ import java.util.List; | ||
| 44 | import java.util.Map; | 44 | import java.util.Map; |
| 45 | import java.util.stream.Stream; | 45 | import java.util.stream.Stream; |
| 46 | 46 | ||
| 47 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 47 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 48 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 48 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; | 49 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; |
| 49 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; | 50 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| 50 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 51 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | 51 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| 52 | import static cn.iocoder.yudao.module.crm.enums.DictTypeConstants.*; | 52 | import static cn.iocoder.yudao.module.crm.enums.DictTypeConstants.*; |
| 53 | import static java.util.Collections.singletonList; | 53 | import static java.util.Collections.singletonList; |
| @@ -242,7 +242,7 @@ public class CrmCustomerController { | @@ -242,7 +242,7 @@ public class CrmCustomerController { | ||
| 242 | @GetMapping("/export-excel") | 242 | @GetMapping("/export-excel") |
| 243 | @Operation(summary = "导出客户 Excel") | 243 | @Operation(summary = "导出客户 Excel") |
| 244 | @PreAuthorize("@ss.hasPermission('crm:customer:export')") | 244 | @PreAuthorize("@ss.hasPermission('crm:customer:export')") |
| 245 | - @OperateLog(type = EXPORT) | 245 | + @ApiAccessLog(operateType = EXPORT) |
| 246 | public void exportCustomerExcel(@Valid CrmCustomerPageReqVO pageVO, | 246 | public void exportCustomerExcel(@Valid CrmCustomerPageReqVO pageVO, |
| 247 | HttpServletResponse response) throws IOException { | 247 | HttpServletResponse response) throws IOException { |
| 248 | pageVO.setPageSize(PAGE_SIZE_NONE); // 不分页 | 248 | pageVO.setPageSize(PAGE_SIZE_NONE); // 不分页 |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/product/CrmProductController.java
| 1 | package cn.iocoder.yudao.module.crm.controller.admin.product; | 1 | package cn.iocoder.yudao.module.crm.controller.admin.product; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.framework.translate.core.TranslateUtils; | 9 | import cn.iocoder.yudao.framework.translate.core.TranslateUtils; |
| 10 | import cn.iocoder.yudao.module.crm.controller.admin.product.vo.product.CrmProductPageReqVO; | 10 | import cn.iocoder.yudao.module.crm.controller.admin.product.vo.product.CrmProductPageReqVO; |
| 11 | import cn.iocoder.yudao.module.crm.controller.admin.product.vo.product.CrmProductRespVO; | 11 | import cn.iocoder.yudao.module.crm.controller.admin.product.vo.product.CrmProductRespVO; |
| @@ -27,9 +27,9 @@ import org.springframework.web.bind.annotation.*; | @@ -27,9 +27,9 @@ import org.springframework.web.bind.annotation.*; | ||
| 27 | import java.io.IOException; | 27 | import java.io.IOException; |
| 28 | import java.util.List; | 28 | import java.util.List; |
| 29 | 29 | ||
| 30 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 30 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 31 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 31 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 32 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 32 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 33 | 33 | ||
| 34 | @Tag(name = "管理后台 - CRM 产品") | 34 | @Tag(name = "管理后台 - CRM 产品") |
| 35 | @RestController | 35 | @RestController |
| @@ -94,7 +94,7 @@ public class CrmProductController { | @@ -94,7 +94,7 @@ public class CrmProductController { | ||
| 94 | @GetMapping("/export-excel") | 94 | @GetMapping("/export-excel") |
| 95 | @Operation(summary = "导出产品 Excel") | 95 | @Operation(summary = "导出产品 Excel") |
| 96 | @PreAuthorize("@ss.hasPermission('crm:product:export')") | 96 | @PreAuthorize("@ss.hasPermission('crm:product:export')") |
| 97 | - @OperateLog(type = EXPORT) | 97 | + @ApiAccessLog(operateType = EXPORT) |
| 98 | public void exportProductExcel(@Valid CrmProductPageReqVO exportReqVO, | 98 | public void exportProductExcel(@Valid CrmProductPageReqVO exportReqVO, |
| 99 | HttpServletResponse response) throws IOException { | 99 | HttpServletResponse response) throws IOException { |
| 100 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 100 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/CrmReceivableController.java
| @@ -2,13 +2,13 @@ package cn.iocoder.yudao.module.crm.controller.admin.receivable; | @@ -2,13 +2,13 @@ package cn.iocoder.yudao.module.crm.controller.admin.receivable; | ||
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | import cn.hutool.core.lang.Assert; | 4 | import cn.hutool.core.lang.Assert; |
| 5 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | 9 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; |
| 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 10 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 11 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 11 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 12 | import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractRespVO; | 12 | import cn.iocoder.yudao.module.crm.controller.admin.contract.vo.contract.CrmContractRespVO; |
| 13 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.receivable.CrmReceivablePageReqVO; | 13 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.receivable.CrmReceivablePageReqVO; |
| 14 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.receivable.CrmReceivableRespVO; | 14 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.receivable.CrmReceivableRespVO; |
| @@ -39,11 +39,12 @@ import java.util.List; | @@ -39,11 +39,12 @@ import java.util.List; | ||
| 39 | import java.util.Map; | 39 | import java.util.Map; |
| 40 | import java.util.stream.Stream; | 40 | import java.util.stream.Stream; |
| 41 | 41 | ||
| 42 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 42 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 43 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 43 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; | 44 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; |
| 44 | -import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; | 45 | +import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertListByFlatMap; |
| 46 | +import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | ||
| 45 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; | 47 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; |
| 46 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 47 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | 48 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| 48 | 49 | ||
| 49 | @Tag(name = "管理后台 - CRM 回款") | 50 | @Tag(name = "管理后台 - CRM 回款") |
| @@ -123,7 +124,7 @@ public class CrmReceivableController { | @@ -123,7 +124,7 @@ public class CrmReceivableController { | ||
| 123 | @GetMapping("/export-excel") | 124 | @GetMapping("/export-excel") |
| 124 | @Operation(summary = "导出回款 Excel") | 125 | @Operation(summary = "导出回款 Excel") |
| 125 | @PreAuthorize("@ss.hasPermission('crm:receivable:export')") | 126 | @PreAuthorize("@ss.hasPermission('crm:receivable:export')") |
| 126 | - @OperateLog(type = EXPORT) | 127 | + @ApiAccessLog(operateType = EXPORT) |
| 127 | public void exportReceivableExcel(@Valid CrmReceivablePageReqVO exportReqVO, | 128 | public void exportReceivableExcel(@Valid CrmReceivablePageReqVO exportReqVO, |
| 128 | HttpServletResponse response) throws IOException { | 129 | HttpServletResponse response) throws IOException { |
| 129 | exportReqVO.setPageSize(PAGE_SIZE_NONE); | 130 | exportReqVO.setPageSize(PAGE_SIZE_NONE); |
yudao-module-crm/yudao-module-crm-biz/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/receivable/CrmReceivablePlanController.java
| @@ -2,12 +2,12 @@ package cn.iocoder.yudao.module.crm.controller.admin.receivable; | @@ -2,12 +2,12 @@ package cn.iocoder.yudao.module.crm.controller.admin.receivable; | ||
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | import cn.hutool.core.lang.Assert; | 4 | import cn.hutool.core.lang.Assert; |
| 5 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | 8 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.plan.CrmReceivablePlanPageReqVO; | 11 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.plan.CrmReceivablePlanPageReqVO; |
| 12 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.plan.CrmReceivablePlanRespVO; | 12 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.plan.CrmReceivablePlanRespVO; |
| 13 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.plan.CrmReceivablePlanSaveReqVO; | 13 | import cn.iocoder.yudao.module.crm.controller.admin.receivable.vo.plan.CrmReceivablePlanSaveReqVO; |
| @@ -39,11 +39,11 @@ import java.util.List; | @@ -39,11 +39,11 @@ import java.util.List; | ||
| 39 | import java.util.Map; | 39 | import java.util.Map; |
| 40 | import java.util.stream.Stream; | 40 | import java.util.stream.Stream; |
| 41 | 41 | ||
| 42 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 42 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 43 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 43 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; | 44 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; |
| 44 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; | 45 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| 45 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; | 46 | import static cn.iocoder.yudao.framework.common.util.collection.MapUtils.findAndThen; |
| 46 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 47 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | 47 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| 48 | 48 | ||
| 49 | @Tag(name = "管理后台 - CRM 回款计划") | 49 | @Tag(name = "管理后台 - CRM 回款计划") |
| @@ -123,7 +123,7 @@ public class CrmReceivablePlanController { | @@ -123,7 +123,7 @@ public class CrmReceivablePlanController { | ||
| 123 | @GetMapping("/export-excel") | 123 | @GetMapping("/export-excel") |
| 124 | @Operation(summary = "导出回款计划 Excel") | 124 | @Operation(summary = "导出回款计划 Excel") |
| 125 | @PreAuthorize("@ss.hasPermission('crm:receivable-plan:export')") | 125 | @PreAuthorize("@ss.hasPermission('crm:receivable-plan:export')") |
| 126 | - @OperateLog(type = EXPORT) | 126 | + @ApiAccessLog(operateType = EXPORT) |
| 127 | public void exportReceivablePlanExcel(@Valid CrmReceivablePlanPageReqVO exportReqVO, | 127 | public void exportReceivablePlanExcel(@Valid CrmReceivablePlanPageReqVO exportReqVO, |
| 128 | HttpServletResponse response) throws IOException { | 128 | HttpServletResponse response) throws IOException { |
| 129 | exportReqVO.setPageSize(PAGE_SIZE_NONE); | 129 | exportReqVO.setPageSize(PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/pom.xml
| @@ -29,10 +29,6 @@ | @@ -29,10 +29,6 @@ | ||
| 29 | </dependency> | 29 | </dependency> |
| 30 | 30 | ||
| 31 | <!-- 业务组件 --> | 31 | <!-- 业务组件 --> |
| 32 | - <dependency> | ||
| 33 | - <groupId>cn.iocoder.boot</groupId> | ||
| 34 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 35 | - </dependency> | ||
| 36 | 32 | ||
| 37 | <!-- Web 相关 --> | 33 | <!-- Web 相关 --> |
| 38 | <dependency> | 34 | <dependency> |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/finance/ErpAccountController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.finance; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.finance; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.account.ErpAccountPageReqVO; | 10 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.account.ErpAccountPageReqVO; |
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.account.ErpAccountRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.account.ErpAccountRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.account.ErpAccountSaveReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.account.ErpAccountSaveReqVO; |
| @@ -26,9 +26,9 @@ import org.springframework.web.bind.annotation.*; | @@ -26,9 +26,9 @@ import org.springframework.web.bind.annotation.*; | ||
| 26 | import java.io.IOException; | 26 | import java.io.IOException; |
| 27 | import java.util.List; | 27 | import java.util.List; |
| 28 | 28 | ||
| 29 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 30 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 30 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 31 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 31 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 32 | 32 | ||
| 33 | @Tag(name = "管理后台 - ERP 结算账户") | 33 | @Tag(name = "管理后台 - ERP 结算账户") |
| 34 | @RestController | 34 | @RestController |
| @@ -103,7 +103,7 @@ public class ErpAccountController { | @@ -103,7 +103,7 @@ public class ErpAccountController { | ||
| 103 | @GetMapping("/export-excel") | 103 | @GetMapping("/export-excel") |
| 104 | @Operation(summary = "导出结算账户 Excel") | 104 | @Operation(summary = "导出结算账户 Excel") |
| 105 | @PreAuthorize("@ss.hasPermission('erp:account:export')") | 105 | @PreAuthorize("@ss.hasPermission('erp:account:export')") |
| 106 | - @OperateLog(type = EXPORT) | 106 | + @ApiAccessLog(operateType = EXPORT) |
| 107 | public void exportAccountExcel(@Valid ErpAccountPageReqVO pageReqVO, | 107 | public void exportAccountExcel(@Valid ErpAccountPageReqVO pageReqVO, |
| 108 | HttpServletResponse response) throws IOException { | 108 | HttpServletResponse response) throws IOException { |
| 109 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 109 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/finance/ErpFinancePaymentController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.finance; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.finance; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| @@ -8,7 +9,6 @@ import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | @@ -8,7 +9,6 @@ import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | ||
| 8 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | 9 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; |
| 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 10 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 11 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 11 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.payment.ErpFinancePaymentPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.payment.ErpFinancePaymentPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.payment.ErpFinancePaymentRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.payment.ErpFinancePaymentRespVO; |
| 14 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.payment.ErpFinancePaymentSaveReqVO; | 14 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.payment.ErpFinancePaymentSaveReqVO; |
| @@ -36,9 +36,9 @@ import java.util.List; | @@ -36,9 +36,9 @@ import java.util.List; | ||
| 36 | import java.util.Map; | 36 | import java.util.Map; |
| 37 | import java.util.stream.Stream; | 37 | import java.util.stream.Stream; |
| 38 | 38 | ||
| 39 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 39 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 40 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; | 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| 41 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 42 | 42 | ||
| 43 | @Tag(name = "管理后台 - ERP 付款单") | 43 | @Tag(name = "管理后台 - ERP 付款单") |
| 44 | @RestController | 44 | @RestController |
| @@ -114,7 +114,7 @@ public class ErpFinancePaymentController { | @@ -114,7 +114,7 @@ public class ErpFinancePaymentController { | ||
| 114 | @GetMapping("/export-excel") | 114 | @GetMapping("/export-excel") |
| 115 | @Operation(summary = "导出付款单 Excel") | 115 | @Operation(summary = "导出付款单 Excel") |
| 116 | @PreAuthorize("@ss.hasPermission('erp:finance-payment:export')") | 116 | @PreAuthorize("@ss.hasPermission('erp:finance-payment:export')") |
| 117 | - @OperateLog(type = EXPORT) | 117 | + @ApiAccessLog(operateType = EXPORT) |
| 118 | public void exportFinancePaymentExcel(@Valid ErpFinancePaymentPageReqVO pageReqVO, | 118 | public void exportFinancePaymentExcel(@Valid ErpFinancePaymentPageReqVO pageReqVO, |
| 119 | HttpServletResponse response) throws IOException { | 119 | HttpServletResponse response) throws IOException { |
| 120 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 120 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/finance/ErpFinanceReceiptController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.finance; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.finance; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| @@ -8,7 +9,6 @@ import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | @@ -8,7 +9,6 @@ import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | ||
| 8 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; | 9 | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; |
| 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 10 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 11 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 11 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.receipt.ErpFinanceReceiptPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.receipt.ErpFinanceReceiptPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.receipt.ErpFinanceReceiptRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.receipt.ErpFinanceReceiptRespVO; |
| 14 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.receipt.ErpFinanceReceiptSaveReqVO; | 14 | import cn.iocoder.yudao.module.erp.controller.admin.finance.vo.receipt.ErpFinanceReceiptSaveReqVO; |
| @@ -36,9 +36,9 @@ import java.util.List; | @@ -36,9 +36,9 @@ import java.util.List; | ||
| 36 | import java.util.Map; | 36 | import java.util.Map; |
| 37 | import java.util.stream.Stream; | 37 | import java.util.stream.Stream; |
| 38 | 38 | ||
| 39 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 39 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 40 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; | 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| 41 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 42 | 42 | ||
| 43 | @Tag(name = "管理后台 - ERP 收款单") | 43 | @Tag(name = "管理后台 - ERP 收款单") |
| 44 | @RestController | 44 | @RestController |
| @@ -114,7 +114,7 @@ public class ErpFinanceReceiptController { | @@ -114,7 +114,7 @@ public class ErpFinanceReceiptController { | ||
| 114 | @GetMapping("/export-excel") | 114 | @GetMapping("/export-excel") |
| 115 | @Operation(summary = "导出收款单 Excel") | 115 | @Operation(summary = "导出收款单 Excel") |
| 116 | @PreAuthorize("@ss.hasPermission('erp:finance-receipt:export')") | 116 | @PreAuthorize("@ss.hasPermission('erp:finance-receipt:export')") |
| 117 | - @OperateLog(type = EXPORT) | 117 | + @ApiAccessLog(operateType = EXPORT) |
| 118 | public void exportFinanceReceiptExcel(@Valid ErpFinanceReceiptPageReqVO pageReqVO, | 118 | public void exportFinanceReceiptExcel(@Valid ErpFinanceReceiptPageReqVO pageReqVO, |
| 119 | HttpServletResponse response) throws IOException { | 119 | HttpServletResponse response) throws IOException { |
| 120 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 120 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/product/ErpProductCategoryController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.product; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.product; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 6 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 7 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 8 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.category.ErpProductCategoryListReqVO; | 8 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.category.ErpProductCategoryListReqVO; |
| 9 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.category.ErpProductCategoryRespVO; | 9 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.category.ErpProductCategoryRespVO; |
| 10 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.category.ErpProductCategorySaveReqVO; | 10 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.category.ErpProductCategorySaveReqVO; |
| @@ -23,9 +23,9 @@ import org.springframework.web.bind.annotation.*; | @@ -23,9 +23,9 @@ import org.springframework.web.bind.annotation.*; | ||
| 23 | import java.io.IOException; | 23 | import java.io.IOException; |
| 24 | import java.util.List; | 24 | import java.util.List; |
| 25 | 25 | ||
| 26 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 26 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 27 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 28 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 28 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | 29 | ||
| 30 | @Tag(name = "管理后台 - ERP 产品分类") | 30 | @Tag(name = "管理后台 - ERP 产品分类") |
| 31 | @RestController | 31 | @RestController |
| @@ -89,7 +89,7 @@ public class ErpProductCategoryController { | @@ -89,7 +89,7 @@ public class ErpProductCategoryController { | ||
| 89 | @GetMapping("/export-excel") | 89 | @GetMapping("/export-excel") |
| 90 | @Operation(summary = "导出产品分类 Excel") | 90 | @Operation(summary = "导出产品分类 Excel") |
| 91 | @PreAuthorize("@ss.hasPermission('erp:product-category:export')") | 91 | @PreAuthorize("@ss.hasPermission('erp:product-category:export')") |
| 92 | - @OperateLog(type = EXPORT) | 92 | + @ApiAccessLog(operateType = EXPORT) |
| 93 | public void exportProductCategoryExcel(@Valid ErpProductCategoryListReqVO listReqVO, | 93 | public void exportProductCategoryExcel(@Valid ErpProductCategoryListReqVO listReqVO, |
| 94 | HttpServletResponse response) throws IOException { | 94 | HttpServletResponse response) throws IOException { |
| 95 | List<ErpProductCategoryDO> list = productCategoryService.getProductCategoryList(listReqVO); | 95 | List<ErpProductCategoryDO> list = productCategoryService.getProductCategoryList(listReqVO); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/product/ErpProductController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.product; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.product; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductPageReqVO; | 10 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductPageReqVO; |
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ProductSaveReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ProductSaveReqVO; |
| @@ -25,9 +25,9 @@ import org.springframework.web.bind.annotation.*; | @@ -25,9 +25,9 @@ import org.springframework.web.bind.annotation.*; | ||
| 25 | import java.io.IOException; | 25 | import java.io.IOException; |
| 26 | import java.util.List; | 26 | import java.util.List; |
| 27 | 27 | ||
| 28 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 30 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 30 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | 31 | ||
| 32 | @Tag(name = "管理后台 - ERP 产品") | 32 | @Tag(name = "管理后台 - ERP 产品") |
| 33 | @RestController | 33 | @RestController |
| @@ -92,7 +92,7 @@ public class ErpProductController { | @@ -92,7 +92,7 @@ public class ErpProductController { | ||
| 92 | @GetMapping("/export-excel") | 92 | @GetMapping("/export-excel") |
| 93 | @Operation(summary = "导出产品 Excel") | 93 | @Operation(summary = "导出产品 Excel") |
| 94 | @PreAuthorize("@ss.hasPermission('erp:product:export')") | 94 | @PreAuthorize("@ss.hasPermission('erp:product:export')") |
| 95 | - @OperateLog(type = EXPORT) | 95 | + @ApiAccessLog(operateType = EXPORT) |
| 96 | public void exportProductExcel(@Valid ErpProductPageReqVO pageReqVO, | 96 | public void exportProductExcel(@Valid ErpProductPageReqVO pageReqVO, |
| 97 | HttpServletResponse response) throws IOException { | 97 | HttpServletResponse response) throws IOException { |
| 98 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 98 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/product/ErpProductUnitController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.product; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.product; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.unit.ErpProductUnitPageReqVO; | 10 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.unit.ErpProductUnitPageReqVO; |
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.unit.ErpProductUnitRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.unit.ErpProductUnitRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.unit.ErpProductUnitSaveReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.unit.ErpProductUnitSaveReqVO; |
| @@ -25,9 +25,9 @@ import org.springframework.web.bind.annotation.*; | @@ -25,9 +25,9 @@ import org.springframework.web.bind.annotation.*; | ||
| 25 | import java.io.IOException; | 25 | import java.io.IOException; |
| 26 | import java.util.List; | 26 | import java.util.List; |
| 27 | 27 | ||
| 28 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 30 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 30 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | 31 | ||
| 32 | @Tag(name = "管理后台 - ERP 产品单位") | 32 | @Tag(name = "管理后台 - ERP 产品单位") |
| 33 | @RestController | 33 | @RestController |
| @@ -89,7 +89,7 @@ public class ErpProductUnitController { | @@ -89,7 +89,7 @@ public class ErpProductUnitController { | ||
| 89 | @GetMapping("/export-excel") | 89 | @GetMapping("/export-excel") |
| 90 | @Operation(summary = "导出产品单位 Excel") | 90 | @Operation(summary = "导出产品单位 Excel") |
| 91 | @PreAuthorize("@ss.hasPermission('erp:product-unit:export')") | 91 | @PreAuthorize("@ss.hasPermission('erp:product-unit:export')") |
| 92 | - @OperateLog(type = EXPORT) | 92 | + @ApiAccessLog(operateType = EXPORT) |
| 93 | public void exportProductUnitExcel(@Valid ErpProductUnitPageReqVO pageReqVO, | 93 | public void exportProductUnitExcel(@Valid ErpProductUnitPageReqVO pageReqVO, |
| 94 | HttpServletResponse response) throws IOException { | 94 | HttpServletResponse response) throws IOException { |
| 95 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 95 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/purchase/ErpPurchaseInController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.purchase; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.purchase; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.in.ErpPurchaseInPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.in.ErpPurchaseInPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.in.ErpPurchaseInRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.in.ErpPurchaseInRespVO; |
| @@ -37,10 +37,10 @@ import java.math.BigDecimal; | @@ -37,10 +37,10 @@ import java.math.BigDecimal; | ||
| 37 | import java.util.List; | 37 | import java.util.List; |
| 38 | import java.util.Map; | 38 | import java.util.Map; |
| 39 | 39 | ||
| 40 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 41 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 43 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 44 | 44 | ||
| 45 | @Tag(name = "管理后台 - ERP 采购入库") | 45 | @Tag(name = "管理后台 - ERP 采购入库") |
| 46 | @RestController | 46 | @RestController |
| @@ -125,7 +125,7 @@ public class ErpPurchaseInController { | @@ -125,7 +125,7 @@ public class ErpPurchaseInController { | ||
| 125 | @GetMapping("/export-excel") | 125 | @GetMapping("/export-excel") |
| 126 | @Operation(summary = "导出采购入库 Excel") | 126 | @Operation(summary = "导出采购入库 Excel") |
| 127 | @PreAuthorize("@ss.hasPermission('erp:purchase-in:export')") | 127 | @PreAuthorize("@ss.hasPermission('erp:purchase-in:export')") |
| 128 | - @OperateLog(type = EXPORT) | 128 | + @ApiAccessLog(operateType = EXPORT) |
| 129 | public void exportPurchaseInExcel(@Valid ErpPurchaseInPageReqVO pageReqVO, | 129 | public void exportPurchaseInExcel(@Valid ErpPurchaseInPageReqVO pageReqVO, |
| 130 | HttpServletResponse response) throws IOException { | 130 | HttpServletResponse response) throws IOException { |
| 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/purchase/ErpPurchaseOrderController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.purchase; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.purchase; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.order.ErpPurchaseOrderPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.order.ErpPurchaseOrderPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.order.ErpPurchaseOrderRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.order.ErpPurchaseOrderRespVO; |
| @@ -36,10 +36,10 @@ import java.math.BigDecimal; | @@ -36,10 +36,10 @@ import java.math.BigDecimal; | ||
| 36 | import java.util.List; | 36 | import java.util.List; |
| 37 | import java.util.Map; | 37 | import java.util.Map; |
| 38 | 38 | ||
| 39 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 39 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 40 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 42 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 43 | 43 | ||
| 44 | @Tag(name = "管理后台 - ERP 采购订单") | 44 | @Tag(name = "管理后台 - ERP 采购订单") |
| 45 | @RestController | 45 | @RestController |
| @@ -124,7 +124,7 @@ public class ErpPurchaseOrderController { | @@ -124,7 +124,7 @@ public class ErpPurchaseOrderController { | ||
| 124 | @GetMapping("/export-excel") | 124 | @GetMapping("/export-excel") |
| 125 | @Operation(summary = "导出采购订单 Excel") | 125 | @Operation(summary = "导出采购订单 Excel") |
| 126 | @PreAuthorize("@ss.hasPermission('erp:purchase-create:export')") | 126 | @PreAuthorize("@ss.hasPermission('erp:purchase-create:export')") |
| 127 | - @OperateLog(type = EXPORT) | 127 | + @ApiAccessLog(operateType = EXPORT) |
| 128 | public void exportPurchaseOrderExcel(@Valid ErpPurchaseOrderPageReqVO pageReqVO, | 128 | public void exportPurchaseOrderExcel(@Valid ErpPurchaseOrderPageReqVO pageReqVO, |
| 129 | HttpServletResponse response) throws IOException { | 129 | HttpServletResponse response) throws IOException { |
| 130 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 130 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/purchase/ErpPurchaseReturnController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.purchase; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.purchase; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.returns.ErpPurchaseReturnPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.returns.ErpPurchaseReturnPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.returns.ErpPurchaseReturnRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.returns.ErpPurchaseReturnRespVO; |
| @@ -37,10 +37,10 @@ import java.math.BigDecimal; | @@ -37,10 +37,10 @@ import java.math.BigDecimal; | ||
| 37 | import java.util.List; | 37 | import java.util.List; |
| 38 | import java.util.Map; | 38 | import java.util.Map; |
| 39 | 39 | ||
| 40 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 41 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 43 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 44 | 44 | ||
| 45 | @Tag(name = "管理后台 - ERP 采购退货") | 45 | @Tag(name = "管理后台 - ERP 采购退货") |
| 46 | @RestController | 46 | @RestController |
| @@ -125,7 +125,7 @@ public class ErpPurchaseReturnController { | @@ -125,7 +125,7 @@ public class ErpPurchaseReturnController { | ||
| 125 | @GetMapping("/export-excel") | 125 | @GetMapping("/export-excel") |
| 126 | @Operation(summary = "导出采购退货 Excel") | 126 | @Operation(summary = "导出采购退货 Excel") |
| 127 | @PreAuthorize("@ss.hasPermission('erp:purchase-return:export')") | 127 | @PreAuthorize("@ss.hasPermission('erp:purchase-return:export')") |
| 128 | - @OperateLog(type = EXPORT) | 128 | + @ApiAccessLog(operateType = EXPORT) |
| 129 | public void exportPurchaseReturnExcel(@Valid ErpPurchaseReturnPageReqVO pageReqVO, | 129 | public void exportPurchaseReturnExcel(@Valid ErpPurchaseReturnPageReqVO pageReqVO, |
| 130 | HttpServletResponse response) throws IOException { | 130 | HttpServletResponse response) throws IOException { |
| 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/purchase/ErpSupplierController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.purchase; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.purchase; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.supplier.ErpSupplierPageReqVO; | 10 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.supplier.ErpSupplierPageReqVO; |
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.supplier.ErpSupplierRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.supplier.ErpSupplierRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.supplier.ErpSupplierSaveReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.supplier.ErpSupplierSaveReqVO; |
| @@ -25,9 +25,9 @@ import org.springframework.web.bind.annotation.*; | @@ -25,9 +25,9 @@ import org.springframework.web.bind.annotation.*; | ||
| 25 | import java.io.IOException; | 25 | import java.io.IOException; |
| 26 | import java.util.List; | 26 | import java.util.List; |
| 27 | 27 | ||
| 28 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 30 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 30 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | 31 | ||
| 32 | @Tag(name = "管理后台 - ERP 供应商") | 32 | @Tag(name = "管理后台 - ERP 供应商") |
| 33 | @RestController | 33 | @RestController |
| @@ -89,7 +89,7 @@ public class ErpSupplierController { | @@ -89,7 +89,7 @@ public class ErpSupplierController { | ||
| 89 | @GetMapping("/export-excel") | 89 | @GetMapping("/export-excel") |
| 90 | @Operation(summary = "导出供应商 Excel") | 90 | @Operation(summary = "导出供应商 Excel") |
| 91 | @PreAuthorize("@ss.hasPermission('erp:supplier:export')") | 91 | @PreAuthorize("@ss.hasPermission('erp:supplier:export')") |
| 92 | - @OperateLog(type = EXPORT) | 92 | + @ApiAccessLog(operateType = EXPORT) |
| 93 | public void exportSupplierExcel(@Valid ErpSupplierPageReqVO pageReqVO, | 93 | public void exportSupplierExcel(@Valid ErpSupplierPageReqVO pageReqVO, |
| 94 | HttpServletResponse response) throws IOException { | 94 | HttpServletResponse response) throws IOException { |
| 95 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 95 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/sale/ErpCustomerController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.sale; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.sale; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.customer.ErpCustomerPageReqVO; | 10 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.customer.ErpCustomerPageReqVO; |
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.customer.ErpCustomerRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.customer.ErpCustomerRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.customer.ErpCustomerSaveReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.customer.ErpCustomerSaveReqVO; |
| @@ -25,9 +25,9 @@ import org.springframework.web.bind.annotation.*; | @@ -25,9 +25,9 @@ import org.springframework.web.bind.annotation.*; | ||
| 25 | import java.io.IOException; | 25 | import java.io.IOException; |
| 26 | import java.util.List; | 26 | import java.util.List; |
| 27 | 27 | ||
| 28 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 30 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 30 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | 31 | ||
| 32 | @Tag(name = "管理后台 - ERP 客户") | 32 | @Tag(name = "管理后台 - ERP 客户") |
| 33 | @RestController | 33 | @RestController |
| @@ -89,7 +89,7 @@ public class ErpCustomerController { | @@ -89,7 +89,7 @@ public class ErpCustomerController { | ||
| 89 | @GetMapping("/export-excel") | 89 | @GetMapping("/export-excel") |
| 90 | @Operation(summary = "导出客户 Excel") | 90 | @Operation(summary = "导出客户 Excel") |
| 91 | @PreAuthorize("@ss.hasPermission('erp:customer:export')") | 91 | @PreAuthorize("@ss.hasPermission('erp:customer:export')") |
| 92 | - @OperateLog(type = EXPORT) | 92 | + @ApiAccessLog(operateType = EXPORT) |
| 93 | public void exportCustomerExcel(@Valid ErpCustomerPageReqVO pageReqVO, | 93 | public void exportCustomerExcel(@Valid ErpCustomerPageReqVO pageReqVO, |
| 94 | HttpServletResponse response) throws IOException { | 94 | HttpServletResponse response) throws IOException { |
| 95 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 95 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/sale/ErpSaleOrderController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.sale; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.sale; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.order.ErpSaleOrderPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.order.ErpSaleOrderPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.order.ErpSaleOrderRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.order.ErpSaleOrderRespVO; |
| @@ -36,11 +36,10 @@ import java.math.BigDecimal; | @@ -36,11 +36,10 @@ import java.math.BigDecimal; | ||
| 36 | import java.util.List; | 36 | import java.util.List; |
| 37 | import java.util.Map; | 37 | import java.util.Map; |
| 38 | 38 | ||
| 39 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 39 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 40 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 42 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 43 | - | ||
| 44 | 43 | ||
| 45 | @Tag(name = "管理后台 - ERP 销售订单") | 44 | @Tag(name = "管理后台 - ERP 销售订单") |
| 46 | @RestController | 45 | @RestController |
| @@ -125,7 +124,7 @@ public class ErpSaleOrderController { | @@ -125,7 +124,7 @@ public class ErpSaleOrderController { | ||
| 125 | @GetMapping("/export-excel") | 124 | @GetMapping("/export-excel") |
| 126 | @Operation(summary = "导出销售订单 Excel") | 125 | @Operation(summary = "导出销售订单 Excel") |
| 127 | @PreAuthorize("@ss.hasPermission('erp:sale-out:export')") | 126 | @PreAuthorize("@ss.hasPermission('erp:sale-out:export')") |
| 128 | - @OperateLog(type = EXPORT) | 127 | + @ApiAccessLog(operateType = EXPORT) |
| 129 | public void exportSaleOrderExcel(@Valid ErpSaleOrderPageReqVO pageReqVO, | 128 | public void exportSaleOrderExcel(@Valid ErpSaleOrderPageReqVO pageReqVO, |
| 130 | HttpServletResponse response) throws IOException { | 129 | HttpServletResponse response) throws IOException { |
| 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 130 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/sale/ErpSaleOutController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.sale; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.sale; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.out.ErpSaleOutPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.out.ErpSaleOutPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.out.ErpSaleOutRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.out.ErpSaleOutRespVO; |
| @@ -37,10 +37,10 @@ import java.math.BigDecimal; | @@ -37,10 +37,10 @@ import java.math.BigDecimal; | ||
| 37 | import java.util.List; | 37 | import java.util.List; |
| 38 | import java.util.Map; | 38 | import java.util.Map; |
| 39 | 39 | ||
| 40 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 41 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 43 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 44 | 44 | ||
| 45 | @Tag(name = "管理后台 - ERP 销售出库") | 45 | @Tag(name = "管理后台 - ERP 销售出库") |
| 46 | @RestController | 46 | @RestController |
| @@ -125,7 +125,7 @@ public class ErpSaleOutController { | @@ -125,7 +125,7 @@ public class ErpSaleOutController { | ||
| 125 | @GetMapping("/export-excel") | 125 | @GetMapping("/export-excel") |
| 126 | @Operation(summary = "导出销售出库 Excel") | 126 | @Operation(summary = "导出销售出库 Excel") |
| 127 | @PreAuthorize("@ss.hasPermission('erp:sale-out:export')") | 127 | @PreAuthorize("@ss.hasPermission('erp:sale-out:export')") |
| 128 | - @OperateLog(type = EXPORT) | 128 | + @ApiAccessLog(operateType = EXPORT) |
| 129 | public void exportSaleOutExcel(@Valid ErpSaleOutPageReqVO pageReqVO, | 129 | public void exportSaleOutExcel(@Valid ErpSaleOutPageReqVO pageReqVO, |
| 130 | HttpServletResponse response) throws IOException { | 130 | HttpServletResponse response) throws IOException { |
| 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/sale/ErpSaleReturnController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.sale; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.sale; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.returns.ErpSaleReturnPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.returns.ErpSaleReturnPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.returns.ErpSaleReturnRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.returns.ErpSaleReturnRespVO; |
| @@ -37,10 +37,10 @@ import java.math.BigDecimal; | @@ -37,10 +37,10 @@ import java.math.BigDecimal; | ||
| 37 | import java.util.List; | 37 | import java.util.List; |
| 38 | import java.util.Map; | 38 | import java.util.Map; |
| 39 | 39 | ||
| 40 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 41 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 43 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 44 | 44 | ||
| 45 | @Tag(name = "管理后台 - ERP 销售退货") | 45 | @Tag(name = "管理后台 - ERP 销售退货") |
| 46 | @RestController | 46 | @RestController |
| @@ -125,7 +125,7 @@ public class ErpSaleReturnController { | @@ -125,7 +125,7 @@ public class ErpSaleReturnController { | ||
| 125 | @GetMapping("/export-excel") | 125 | @GetMapping("/export-excel") |
| 126 | @Operation(summary = "导出销售退货 Excel") | 126 | @Operation(summary = "导出销售退货 Excel") |
| 127 | @PreAuthorize("@ss.hasPermission('erp:sale-return:export')") | 127 | @PreAuthorize("@ss.hasPermission('erp:sale-return:export')") |
| 128 | - @OperateLog(type = EXPORT) | 128 | + @ApiAccessLog(operateType = EXPORT) |
| 129 | public void exportSaleReturnExcel(@Valid ErpSaleReturnPageReqVO pageReqVO, | 129 | public void exportSaleReturnExcel(@Valid ErpSaleReturnPageReqVO pageReqVO, |
| 130 | HttpServletResponse response) throws IOException { | 130 | HttpServletResponse response) throws IOException { |
| 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/stock/ErpStockCheckController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.check.ErpStockCheckPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.check.ErpStockCheckPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.check.ErpStockCheckRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.check.ErpStockCheckRespVO; |
| @@ -32,10 +32,10 @@ import java.io.IOException; | @@ -32,10 +32,10 @@ import java.io.IOException; | ||
| 32 | import java.util.List; | 32 | import java.util.List; |
| 33 | import java.util.Map; | 33 | import java.util.Map; |
| 34 | 34 | ||
| 35 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 35 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 36 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 36 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 37 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 37 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 38 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 38 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 39 | 39 | ||
| 40 | @Tag(name = "管理后台 - ERP 库存调拨单") | 40 | @Tag(name = "管理后台 - ERP 库存调拨单") |
| 41 | @RestController | 41 | @RestController |
| @@ -113,7 +113,7 @@ public class ErpStockCheckController { | @@ -113,7 +113,7 @@ public class ErpStockCheckController { | ||
| 113 | @GetMapping("/export-excel") | 113 | @GetMapping("/export-excel") |
| 114 | @Operation(summary = "导出库存调拨单 Excel") | 114 | @Operation(summary = "导出库存调拨单 Excel") |
| 115 | @PreAuthorize("@ss.hasPermission('erp:stock-check:export')") | 115 | @PreAuthorize("@ss.hasPermission('erp:stock-check:export')") |
| 116 | - @OperateLog(type = EXPORT) | 116 | + @ApiAccessLog(operateType = EXPORT) |
| 117 | public void exportStockCheckExcel(@Valid ErpStockCheckPageReqVO pageReqVO, | 117 | public void exportStockCheckExcel(@Valid ErpStockCheckPageReqVO pageReqVO, |
| 118 | HttpServletResponse response) throws IOException { | 118 | HttpServletResponse response) throws IOException { |
| 119 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 119 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/stock/ErpStockController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.stock.ErpStockPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.stock.ErpStockPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.stock.ErpStockRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.stock.ErpStockRespVO; |
| @@ -35,9 +35,9 @@ import java.math.BigDecimal; | @@ -35,9 +35,9 @@ import java.math.BigDecimal; | ||
| 35 | import java.util.List; | 35 | import java.util.List; |
| 36 | import java.util.Map; | 36 | import java.util.Map; |
| 37 | 37 | ||
| 38 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 38 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 39 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 39 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 40 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 40 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 41 | 41 | ||
| 42 | @Tag(name = "管理后台 - ERP 产品库存") | 42 | @Tag(name = "管理后台 - ERP 产品库存") |
| 43 | @RestController | 43 | @RestController |
| @@ -85,7 +85,7 @@ public class ErpStockController { | @@ -85,7 +85,7 @@ public class ErpStockController { | ||
| 85 | @GetMapping("/export-excel") | 85 | @GetMapping("/export-excel") |
| 86 | @Operation(summary = "导出产品库存 Excel") | 86 | @Operation(summary = "导出产品库存 Excel") |
| 87 | @PreAuthorize("@ss.hasPermission('erp:stock:export')") | 87 | @PreAuthorize("@ss.hasPermission('erp:stock:export')") |
| 88 | - @OperateLog(type = EXPORT) | 88 | + @ApiAccessLog(operateType = EXPORT) |
| 89 | public void exportStockExcel(@Valid ErpStockPageReqVO pageReqVO, | 89 | public void exportStockExcel(@Valid ErpStockPageReqVO pageReqVO, |
| 90 | HttpServletResponse response) throws IOException { | 90 | HttpServletResponse response) throws IOException { |
| 91 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 91 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/stock/ErpStockInController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.in.ErpStockInPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.in.ErpStockInPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.in.ErpStockInRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.in.ErpStockInRespVO; |
| 14 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.in.ErpStockInSaveReqVO; | 14 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.in.ErpStockInSaveReqVO; |
| 15 | +import cn.iocoder.yudao.module.erp.dal.dataobject.purchase.ErpSupplierDO; | ||
| 15 | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpStockDO; | 16 | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpStockDO; |
| 16 | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpStockInDO; | 17 | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpStockInDO; |
| 17 | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpStockInItemDO; | 18 | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpStockInItemDO; |
| 18 | -import cn.iocoder.yudao.module.erp.dal.dataobject.purchase.ErpSupplierDO; | ||
| 19 | import cn.iocoder.yudao.module.erp.service.product.ErpProductService; | 19 | import cn.iocoder.yudao.module.erp.service.product.ErpProductService; |
| 20 | import cn.iocoder.yudao.module.erp.service.purchase.ErpSupplierService; | 20 | import cn.iocoder.yudao.module.erp.service.purchase.ErpSupplierService; |
| 21 | import cn.iocoder.yudao.module.erp.service.stock.ErpStockInService; | 21 | import cn.iocoder.yudao.module.erp.service.stock.ErpStockInService; |
| @@ -37,10 +37,10 @@ import java.math.BigDecimal; | @@ -37,10 +37,10 @@ import java.math.BigDecimal; | ||
| 37 | import java.util.List; | 37 | import java.util.List; |
| 38 | import java.util.Map; | 38 | import java.util.Map; |
| 39 | 39 | ||
| 40 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 41 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 43 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 44 | 44 | ||
| 45 | @Tag(name = "管理后台 - ERP 其它入库单") | 45 | @Tag(name = "管理后台 - ERP 其它入库单") |
| 46 | @RestController | 46 | @RestController |
| @@ -125,7 +125,7 @@ public class ErpStockInController { | @@ -125,7 +125,7 @@ public class ErpStockInController { | ||
| 125 | @GetMapping("/export-excel") | 125 | @GetMapping("/export-excel") |
| 126 | @Operation(summary = "导出其它入库单 Excel") | 126 | @Operation(summary = "导出其它入库单 Excel") |
| 127 | @PreAuthorize("@ss.hasPermission('erp:stock-in:export')") | 127 | @PreAuthorize("@ss.hasPermission('erp:stock-in:export')") |
| 128 | - @OperateLog(type = EXPORT) | 128 | + @ApiAccessLog(operateType = EXPORT) |
| 129 | public void exportStockInExcel(@Valid ErpStockInPageReqVO pageReqVO, | 129 | public void exportStockInExcel(@Valid ErpStockInPageReqVO pageReqVO, |
| 130 | HttpServletResponse response) throws IOException { | 130 | HttpServletResponse response) throws IOException { |
| 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/stock/ErpStockMoveController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.move.ErpStockMovePageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.move.ErpStockMovePageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.move.ErpStockMoveRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.move.ErpStockMoveRespVO; |
| @@ -35,10 +35,10 @@ import java.math.BigDecimal; | @@ -35,10 +35,10 @@ import java.math.BigDecimal; | ||
| 35 | import java.util.List; | 35 | import java.util.List; |
| 36 | import java.util.Map; | 36 | import java.util.Map; |
| 37 | 37 | ||
| 38 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 38 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 39 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 39 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 40 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 40 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 41 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 42 | 42 | ||
| 43 | @Tag(name = "管理后台 - ERP 库存调拨单") | 43 | @Tag(name = "管理后台 - ERP 库存调拨单") |
| 44 | @RestController | 44 | @RestController |
| @@ -121,7 +121,7 @@ public class ErpStockMoveController { | @@ -121,7 +121,7 @@ public class ErpStockMoveController { | ||
| 121 | @GetMapping("/export-excel") | 121 | @GetMapping("/export-excel") |
| 122 | @Operation(summary = "导出库存调拨单 Excel") | 122 | @Operation(summary = "导出库存调拨单 Excel") |
| 123 | @PreAuthorize("@ss.hasPermission('erp:stock-move:export')") | 123 | @PreAuthorize("@ss.hasPermission('erp:stock-move:export')") |
| 124 | - @OperateLog(type = EXPORT) | 124 | + @ApiAccessLog(operateType = EXPORT) |
| 125 | public void exportStockMoveExcel(@Valid ErpStockMovePageReqVO pageReqVO, | 125 | public void exportStockMoveExcel(@Valid ErpStockMovePageReqVO pageReqVO, |
| 126 | HttpServletResponse response) throws IOException { | 126 | HttpServletResponse response) throws IOException { |
| 127 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 127 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/stock/ErpStockOutController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.out.ErpStockOutPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.out.ErpStockOutPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.out.ErpStockOutRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.out.ErpStockOutRespVO; |
| @@ -37,10 +37,10 @@ import java.math.BigDecimal; | @@ -37,10 +37,10 @@ import java.math.BigDecimal; | ||
| 37 | import java.util.List; | 37 | import java.util.List; |
| 38 | import java.util.Map; | 38 | import java.util.Map; |
| 39 | 39 | ||
| 40 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 40 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 41 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 41 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; | 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| 42 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 43 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 43 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 44 | 44 | ||
| 45 | @Tag(name = "管理后台 - ERP 其它出库单") | 45 | @Tag(name = "管理后台 - ERP 其它出库单") |
| 46 | @RestController | 46 | @RestController |
| @@ -125,7 +125,7 @@ public class ErpStockOutController { | @@ -125,7 +125,7 @@ public class ErpStockOutController { | ||
| 125 | @GetMapping("/export-excel") | 125 | @GetMapping("/export-excel") |
| 126 | @Operation(summary = "导出其它出库单 Excel") | 126 | @Operation(summary = "导出其它出库单 Excel") |
| 127 | @PreAuthorize("@ss.hasPermission('erp:stock-out:export')") | 127 | @PreAuthorize("@ss.hasPermission('erp:stock-out:export')") |
| 128 | - @OperateLog(type = EXPORT) | 128 | + @ApiAccessLog(operateType = EXPORT) |
| 129 | public void exportStockOutExcel(@Valid ErpStockOutPageReqVO pageReqVO, | 129 | public void exportStockOutExcel(@Valid ErpStockOutPageReqVO pageReqVO, |
| 130 | HttpServletResponse response) throws IOException { | 130 | HttpServletResponse response) throws IOException { |
| 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 131 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/stock/ErpStockRecordController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; | 8 | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 9 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 10 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.record.ErpStockRecordPageReqVO; | 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.record.ErpStockRecordPageReqVO; |
| 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.record.ErpStockRecordRespVO; | 13 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.record.ErpStockRecordRespVO; |
| @@ -35,9 +35,9 @@ import java.io.IOException; | @@ -35,9 +35,9 @@ import java.io.IOException; | ||
| 35 | import java.util.List; | 35 | import java.util.List; |
| 36 | import java.util.Map; | 36 | import java.util.Map; |
| 37 | 37 | ||
| 38 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 38 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 39 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 39 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; | 40 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| 40 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 41 | 41 | ||
| 42 | @Tag(name = "管理后台 - ERP 产品库存明细") | 42 | @Tag(name = "管理后台 - ERP 产品库存明细") |
| 43 | @RestController | 43 | @RestController |
| @@ -75,7 +75,7 @@ public class ErpStockRecordController { | @@ -75,7 +75,7 @@ public class ErpStockRecordController { | ||
| 75 | @GetMapping("/export-excel") | 75 | @GetMapping("/export-excel") |
| 76 | @Operation(summary = "导出产品库存明细 Excel") | 76 | @Operation(summary = "导出产品库存明细 Excel") |
| 77 | @PreAuthorize("@ss.hasPermission('erp:stock-record:export')") | 77 | @PreAuthorize("@ss.hasPermission('erp:stock-record:export')") |
| 78 | - @OperateLog(type = EXPORT) | 78 | + @ApiAccessLog(operateType = EXPORT) |
| 79 | public void exportStockRecordExcel(@Valid ErpStockRecordPageReqVO pageReqVO, | 79 | public void exportStockRecordExcel(@Valid ErpStockRecordPageReqVO pageReqVO, |
| 80 | HttpServletResponse response) throws IOException { | 80 | HttpServletResponse response) throws IOException { |
| 81 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 81 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-erp/yudao-module-erp-biz/src/main/java/cn/iocoder/yudao/module/erp/controller/admin/stock/ErpWarehouseController.java
| 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; | 1 | package cn.iocoder.yudao.module.erp.controller.admin.stock; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | -import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.warehouse.ErpWarehouseSaveReqVO; | ||
| 11 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.warehouse.ErpWarehousePageReqVO; | 10 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.warehouse.ErpWarehousePageReqVO; |
| 12 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.warehouse.ErpWarehouseRespVO; | 11 | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.warehouse.ErpWarehouseRespVO; |
| 12 | +import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.warehouse.ErpWarehouseSaveReqVO; | ||
| 13 | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpWarehouseDO; | 13 | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpWarehouseDO; |
| 14 | import cn.iocoder.yudao.module.erp.service.stock.ErpWarehouseService; | 14 | import cn.iocoder.yudao.module.erp.service.stock.ErpWarehouseService; |
| 15 | import io.swagger.v3.oas.annotations.Operation; | 15 | import io.swagger.v3.oas.annotations.Operation; |
| @@ -26,9 +26,9 @@ import org.springframework.web.bind.annotation.*; | @@ -26,9 +26,9 @@ import org.springframework.web.bind.annotation.*; | ||
| 26 | import java.io.IOException; | 26 | import java.io.IOException; |
| 27 | import java.util.List; | 27 | import java.util.List; |
| 28 | 28 | ||
| 29 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 30 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 30 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 31 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 31 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 32 | 32 | ||
| 33 | @Tag(name = "管理后台 - ERP 仓库") | 33 | @Tag(name = "管理后台 - ERP 仓库") |
| 34 | @RestController | 34 | @RestController |
| @@ -103,7 +103,7 @@ public class ErpWarehouseController { | @@ -103,7 +103,7 @@ public class ErpWarehouseController { | ||
| 103 | @GetMapping("/export-excel") | 103 | @GetMapping("/export-excel") |
| 104 | @Operation(summary = "导出仓库 Excel") | 104 | @Operation(summary = "导出仓库 Excel") |
| 105 | @PreAuthorize("@ss.hasPermission('erp:warehouse:export')") | 105 | @PreAuthorize("@ss.hasPermission('erp:warehouse:export')") |
| 106 | - @OperateLog(type = EXPORT) | 106 | + @ApiAccessLog(operateType = EXPORT) |
| 107 | public void exportWarehouseExcel(@Valid ErpWarehousePageReqVO pageReqVO, | 107 | public void exportWarehouseExcel(@Valid ErpWarehousePageReqVO pageReqVO, |
| 108 | HttpServletResponse response) throws IOException { | 108 | HttpServletResponse response) throws IOException { |
| 109 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 109 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-infra/yudao-module-infra-biz/pom.xml
| @@ -33,10 +33,6 @@ | @@ -33,10 +33,6 @@ | ||
| 33 | <!-- 业务组件 --> | 33 | <!-- 业务组件 --> |
| 34 | <dependency> | 34 | <dependency> |
| 35 | <groupId>cn.iocoder.boot</groupId> | 35 | <groupId>cn.iocoder.boot</groupId> |
| 36 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 37 | - </dependency> | ||
| 38 | - <dependency> | ||
| 39 | - <groupId>cn.iocoder.boot</groupId> | ||
| 40 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> | 36 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> |
| 41 | </dependency> | 37 | </dependency> |
| 42 | 38 |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/ConfigController.java
| 1 | package cn.iocoder.yudao.module.infra.controller.admin.config; | 1 | package cn.iocoder.yudao.module.infra.controller.admin.config; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 7 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 8 | import cn.iocoder.yudao.module.infra.controller.admin.config.vo.*; | 8 | import cn.iocoder.yudao.module.infra.controller.admin.config.vo.*; |
| 9 | import cn.iocoder.yudao.module.infra.convert.config.ConfigConvert; | 9 | import cn.iocoder.yudao.module.infra.convert.config.ConfigConvert; |
| 10 | import cn.iocoder.yudao.module.infra.dal.dataobject.config.ConfigDO; | 10 | import cn.iocoder.yudao.module.infra.dal.dataobject.config.ConfigDO; |
| @@ -23,9 +23,9 @@ import jakarta.validation.Valid; | @@ -23,9 +23,9 @@ import jakarta.validation.Valid; | ||
| 23 | import java.io.IOException; | 23 | import java.io.IOException; |
| 24 | import java.util.List; | 24 | import java.util.List; |
| 25 | 25 | ||
| 26 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 26 | import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; | 27 | import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; |
| 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 28 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | 29 | ||
| 30 | @Tag(name = "管理后台 - 参数配置") | 30 | @Tag(name = "管理后台 - 参数配置") |
| 31 | @RestController | 31 | @RestController |
| @@ -93,7 +93,7 @@ public class ConfigController { | @@ -93,7 +93,7 @@ public class ConfigController { | ||
| 93 | @GetMapping("/export") | 93 | @GetMapping("/export") |
| 94 | @Operation(summary = "导出参数配置") | 94 | @Operation(summary = "导出参数配置") |
| 95 | @PreAuthorize("@ss.hasPermission('infra:config:export')") | 95 | @PreAuthorize("@ss.hasPermission('infra:config:export')") |
| 96 | - @OperateLog(type = EXPORT) | 96 | + @ApiAccessLog(operateType = EXPORT) |
| 97 | public void exportConfig(@Valid ConfigPageReqVO exportReqVO, | 97 | public void exportConfig(@Valid ConfigPageReqVO exportReqVO, |
| 98 | HttpServletResponse response) throws IOException { | 98 | HttpServletResponse response) throws IOException { |
| 99 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 99 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/demo/demo01/Demo01ContactController.java
| 1 | package cn.iocoder.yudao.module.infra.controller.admin.demo.demo01; | 1 | package cn.iocoder.yudao.module.infra.controller.admin.demo.demo01; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo01.vo.Demo01ContactPageReqVO; | 9 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo01.vo.Demo01ContactPageReqVO; |
| 10 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo01.vo.Demo01ContactRespVO; | 10 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo01.vo.Demo01ContactRespVO; |
| 11 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo01.vo.Demo01ContactSaveReqVO; | 11 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo01.vo.Demo01ContactSaveReqVO; |
| @@ -14,18 +14,18 @@ import cn.iocoder.yudao.module.infra.service.demo.demo01.Demo01ContactService; | @@ -14,18 +14,18 @@ import cn.iocoder.yudao.module.infra.service.demo.demo01.Demo01ContactService; | ||
| 14 | import io.swagger.v3.oas.annotations.Operation; | 14 | import io.swagger.v3.oas.annotations.Operation; |
| 15 | import io.swagger.v3.oas.annotations.Parameter; | 15 | import io.swagger.v3.oas.annotations.Parameter; |
| 16 | import io.swagger.v3.oas.annotations.tags.Tag; | 16 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 17 | +import jakarta.annotation.Resource; | ||
| 18 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 19 | +import jakarta.validation.Valid; | ||
| 17 | import org.springframework.security.access.prepost.PreAuthorize; | 20 | import org.springframework.security.access.prepost.PreAuthorize; |
| 18 | import org.springframework.validation.annotation.Validated; | 21 | import org.springframework.validation.annotation.Validated; |
| 19 | import org.springframework.web.bind.annotation.*; | 22 | import org.springframework.web.bind.annotation.*; |
| 20 | 23 | ||
| 21 | -import jakarta.annotation.Resource; | ||
| 22 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 23 | -import jakarta.validation.Valid; | ||
| 24 | import java.io.IOException; | 24 | import java.io.IOException; |
| 25 | import java.util.List; | 25 | import java.util.List; |
| 26 | 26 | ||
| 27 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 28 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | 29 | ||
| 30 | @Tag(name = "管理后台 - 示例联系人") | 30 | @Tag(name = "管理后台 - 示例联系人") |
| 31 | @RestController | 31 | @RestController |
| @@ -80,7 +80,7 @@ public class Demo01ContactController { | @@ -80,7 +80,7 @@ public class Demo01ContactController { | ||
| 80 | @GetMapping("/export-excel") | 80 | @GetMapping("/export-excel") |
| 81 | @Operation(summary = "导出示例联系人 Excel") | 81 | @Operation(summary = "导出示例联系人 Excel") |
| 82 | @PreAuthorize("@ss.hasPermission('infra:demo01-contact:export')") | 82 | @PreAuthorize("@ss.hasPermission('infra:demo01-contact:export')") |
| 83 | - @OperateLog(type = EXPORT) | 83 | + @ApiAccessLog(operateType = EXPORT) |
| 84 | public void exportDemo01ContactExcel(@Valid Demo01ContactPageReqVO pageReqVO, | 84 | public void exportDemo01ContactExcel(@Valid Demo01ContactPageReqVO pageReqVO, |
| 85 | HttpServletResponse response) throws IOException { | 85 | HttpServletResponse response) throws IOException { |
| 86 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 86 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/demo/demo02/Demo02CategoryController.java
| 1 | package cn.iocoder.yudao.module.infra.controller.admin.demo.demo02; | 1 | package cn.iocoder.yudao.module.infra.controller.admin.demo.demo02; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 5 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 5 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 6 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 6 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 7 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo02.vo.Demo02CategoryListReqVO; | 7 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo02.vo.Demo02CategoryListReqVO; |
| 8 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo02.vo.Demo02CategoryRespVO; | 8 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo02.vo.Demo02CategoryRespVO; |
| 9 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo02.vo.Demo02CategorySaveReqVO; | 9 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo02.vo.Demo02CategorySaveReqVO; |
| @@ -12,18 +12,18 @@ import cn.iocoder.yudao.module.infra.service.demo.demo02.Demo02CategoryService; | @@ -12,18 +12,18 @@ import cn.iocoder.yudao.module.infra.service.demo.demo02.Demo02CategoryService; | ||
| 12 | import io.swagger.v3.oas.annotations.Operation; | 12 | import io.swagger.v3.oas.annotations.Operation; |
| 13 | import io.swagger.v3.oas.annotations.Parameter; | 13 | import io.swagger.v3.oas.annotations.Parameter; |
| 14 | import io.swagger.v3.oas.annotations.tags.Tag; | 14 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 15 | +import jakarta.annotation.Resource; | ||
| 16 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 17 | +import jakarta.validation.Valid; | ||
| 15 | import org.springframework.security.access.prepost.PreAuthorize; | 18 | import org.springframework.security.access.prepost.PreAuthorize; |
| 16 | import org.springframework.validation.annotation.Validated; | 19 | import org.springframework.validation.annotation.Validated; |
| 17 | import org.springframework.web.bind.annotation.*; | 20 | import org.springframework.web.bind.annotation.*; |
| 18 | 21 | ||
| 19 | -import jakarta.annotation.Resource; | ||
| 20 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 21 | -import jakarta.validation.Valid; | ||
| 22 | import java.io.IOException; | 22 | import java.io.IOException; |
| 23 | import java.util.List; | 23 | import java.util.List; |
| 24 | 24 | ||
| 25 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 25 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 26 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 26 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | 27 | ||
| 28 | @Tag(name = "管理后台 - 示例分类") | 28 | @Tag(name = "管理后台 - 示例分类") |
| 29 | @RestController | 29 | @RestController |
| @@ -78,7 +78,7 @@ public class Demo02CategoryController { | @@ -78,7 +78,7 @@ public class Demo02CategoryController { | ||
| 78 | @GetMapping("/export-excel") | 78 | @GetMapping("/export-excel") |
| 79 | @Operation(summary = "导出示例分类 Excel") | 79 | @Operation(summary = "导出示例分类 Excel") |
| 80 | @PreAuthorize("@ss.hasPermission('infra:demo02-category:export')") | 80 | @PreAuthorize("@ss.hasPermission('infra:demo02-category:export')") |
| 81 | - @OperateLog(type = EXPORT) | 81 | + @ApiAccessLog(operateType = EXPORT) |
| 82 | public void exportDemo02CategoryExcel(@Valid Demo02CategoryListReqVO listReqVO, | 82 | public void exportDemo02CategoryExcel(@Valid Demo02CategoryListReqVO listReqVO, |
| 83 | HttpServletResponse response) throws IOException { | 83 | HttpServletResponse response) throws IOException { |
| 84 | List<Demo02CategoryDO> list = demo02CategoryService.getDemo02CategoryList(listReqVO); | 84 | List<Demo02CategoryDO> list = demo02CategoryService.getDemo02CategoryList(listReqVO); |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/demo/demo03/Demo03StudentController.java
| 1 | package cn.iocoder.yudao.module.infra.controller.admin.demo.demo03; | 1 | package cn.iocoder.yudao.module.infra.controller.admin.demo.demo03; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo03.vo.Demo03StudentPageReqVO; | 9 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo03.vo.Demo03StudentPageReqVO; |
| 10 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo03.vo.Demo03StudentRespVO; | 10 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo03.vo.Demo03StudentRespVO; |
| 11 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo03.vo.Demo03StudentSaveReqVO; | 11 | import cn.iocoder.yudao.module.infra.controller.admin.demo.demo03.vo.Demo03StudentSaveReqVO; |
| @@ -16,18 +16,18 @@ import cn.iocoder.yudao.module.infra.service.demo.demo03.Demo03StudentService; | @@ -16,18 +16,18 @@ import cn.iocoder.yudao.module.infra.service.demo.demo03.Demo03StudentService; | ||
| 16 | import io.swagger.v3.oas.annotations.Operation; | 16 | import io.swagger.v3.oas.annotations.Operation; |
| 17 | import io.swagger.v3.oas.annotations.Parameter; | 17 | import io.swagger.v3.oas.annotations.Parameter; |
| 18 | import io.swagger.v3.oas.annotations.tags.Tag; | 18 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 19 | +import jakarta.annotation.Resource; | ||
| 20 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 21 | +import jakarta.validation.Valid; | ||
| 19 | import org.springframework.security.access.prepost.PreAuthorize; | 22 | import org.springframework.security.access.prepost.PreAuthorize; |
| 20 | import org.springframework.validation.annotation.Validated; | 23 | import org.springframework.validation.annotation.Validated; |
| 21 | import org.springframework.web.bind.annotation.*; | 24 | import org.springframework.web.bind.annotation.*; |
| 22 | 25 | ||
| 23 | -import jakarta.annotation.Resource; | ||
| 24 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 25 | -import jakarta.validation.Valid; | ||
| 26 | import java.io.IOException; | 26 | import java.io.IOException; |
| 27 | import java.util.List; | 27 | import java.util.List; |
| 28 | 28 | ||
| 29 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 30 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 30 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | 31 | ||
| 32 | @Tag(name = "管理后台 - 学生") | 32 | @Tag(name = "管理后台 - 学生") |
| 33 | @RestController | 33 | @RestController |
| @@ -82,7 +82,7 @@ public class Demo03StudentController { | @@ -82,7 +82,7 @@ public class Demo03StudentController { | ||
| 82 | @GetMapping("/export-excel") | 82 | @GetMapping("/export-excel") |
| 83 | @Operation(summary = "导出学生 Excel") | 83 | @Operation(summary = "导出学生 Excel") |
| 84 | @PreAuthorize("@ss.hasPermission('infra:demo03-student:export')") | 84 | @PreAuthorize("@ss.hasPermission('infra:demo03-student:export')") |
| 85 | - @OperateLog(type = EXPORT) | 85 | + @ApiAccessLog(operateType = EXPORT) |
| 86 | public void exportDemo03StudentExcel(@Valid Demo03StudentPageReqVO pageReqVO, | 86 | public void exportDemo03StudentExcel(@Valid Demo03StudentPageReqVO pageReqVO, |
| 87 | HttpServletResponse response) throws IOException { | 87 | HttpServletResponse response) throws IOException { |
| 88 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 88 | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/FileController.java
| @@ -7,7 +7,6 @@ import cn.iocoder.yudao.framework.common.pojo.CommonResult; | @@ -7,7 +7,6 @@ import cn.iocoder.yudao.framework.common.pojo.CommonResult; | ||
| 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 9 | import cn.iocoder.yudao.framework.common.util.servlet.ServletUtils; | 9 | import cn.iocoder.yudao.framework.common.util.servlet.ServletUtils; |
| 10 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 11 | import cn.iocoder.yudao.module.infra.controller.admin.file.vo.file.*; | 10 | import cn.iocoder.yudao.module.infra.controller.admin.file.vo.file.*; |
| 12 | import cn.iocoder.yudao.module.infra.dal.dataobject.file.FileDO; | 11 | import cn.iocoder.yudao.module.infra.dal.dataobject.file.FileDO; |
| 13 | import cn.iocoder.yudao.module.infra.service.file.FileService; | 12 | import cn.iocoder.yudao.module.infra.service.file.FileService; |
| @@ -40,7 +39,6 @@ public class FileController { | @@ -40,7 +39,6 @@ public class FileController { | ||
| 40 | 39 | ||
| 41 | @PostMapping("/upload") | 40 | @PostMapping("/upload") |
| 42 | @Operation(summary = "上传文件", description = "模式一:后端上传文件") | 41 | @Operation(summary = "上传文件", description = "模式一:后端上传文件") |
| 43 | - @OperateLog(logArgs = false) // 上传文件,没有记录操作日志的必要 | ||
| 44 | public CommonResult<String> uploadFile(FileUploadReqVO uploadReqVO) throws Exception { | 42 | public CommonResult<String> uploadFile(FileUploadReqVO uploadReqVO) throws Exception { |
| 45 | MultipartFile file = uploadReqVO.getFile(); | 43 | MultipartFile file = uploadReqVO.getFile(); |
| 46 | String path = uploadReqVO.getPath(); | 44 | String path = uploadReqVO.getPath(); |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/job/JobController.java
| 1 | package cn.iocoder.yudao.module.infra.controller.admin.job; | 1 | package cn.iocoder.yudao.module.infra.controller.admin.job; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.framework.quartz.core.util.CronUtils; | 9 | import cn.iocoder.yudao.framework.quartz.core.util.CronUtils; |
| 10 | import cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobPageReqVO; | 10 | import cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobPageReqVO; |
| 11 | import cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobRespVO; | 11 | import cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobRespVO; |
| @@ -16,21 +16,21 @@ import io.swagger.v3.oas.annotations.Operation; | @@ -16,21 +16,21 @@ import io.swagger.v3.oas.annotations.Operation; | ||
| 16 | import io.swagger.v3.oas.annotations.Parameter; | 16 | import io.swagger.v3.oas.annotations.Parameter; |
| 17 | import io.swagger.v3.oas.annotations.Parameters; | 17 | import io.swagger.v3.oas.annotations.Parameters; |
| 18 | import io.swagger.v3.oas.annotations.tags.Tag; | 18 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 19 | +import jakarta.annotation.Resource; | ||
| 20 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 21 | +import jakarta.validation.Valid; | ||
| 19 | import org.quartz.SchedulerException; | 22 | import org.quartz.SchedulerException; |
| 20 | import org.springframework.security.access.prepost.PreAuthorize; | 23 | import org.springframework.security.access.prepost.PreAuthorize; |
| 21 | import org.springframework.validation.annotation.Validated; | 24 | import org.springframework.validation.annotation.Validated; |
| 22 | import org.springframework.web.bind.annotation.*; | 25 | import org.springframework.web.bind.annotation.*; |
| 23 | 26 | ||
| 24 | -import jakarta.annotation.Resource; | ||
| 25 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 26 | -import jakarta.validation.Valid; | ||
| 27 | import java.io.IOException; | 27 | import java.io.IOException; |
| 28 | import java.time.LocalDateTime; | 28 | import java.time.LocalDateTime; |
| 29 | import java.util.Collections; | 29 | import java.util.Collections; |
| 30 | import java.util.List; | 30 | import java.util.List; |
| 31 | 31 | ||
| 32 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 32 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 33 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 33 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 34 | 34 | ||
| 35 | @Tag(name = "管理后台 - 定时任务") | 35 | @Tag(name = "管理后台 - 定时任务") |
| 36 | @RestController | 36 | @RestController |
| @@ -110,7 +110,7 @@ public class JobController { | @@ -110,7 +110,7 @@ public class JobController { | ||
| 110 | @GetMapping("/export-excel") | 110 | @GetMapping("/export-excel") |
| 111 | @Operation(summary = "导出定时任务 Excel") | 111 | @Operation(summary = "导出定时任务 Excel") |
| 112 | @PreAuthorize("@ss.hasPermission('infra:job:export')") | 112 | @PreAuthorize("@ss.hasPermission('infra:job:export')") |
| 113 | - @OperateLog(type = EXPORT) | 113 | + @ApiAccessLog(operateType = EXPORT) |
| 114 | public void exportJobExcel(@Valid JobPageReqVO exportReqVO, | 114 | public void exportJobExcel(@Valid JobPageReqVO exportReqVO, |
| 115 | HttpServletResponse response) throws IOException { | 115 | HttpServletResponse response) throws IOException { |
| 116 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 116 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/job/JobLogController.java
| 1 | package cn.iocoder.yudao.module.infra.controller.admin.job; | 1 | package cn.iocoder.yudao.module.infra.controller.admin.job; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.infra.controller.admin.job.vo.log.JobLogPageReqVO; | 9 | import cn.iocoder.yudao.module.infra.controller.admin.job.vo.log.JobLogPageReqVO; |
| 10 | import cn.iocoder.yudao.module.infra.controller.admin.job.vo.log.JobLogRespVO; | 10 | import cn.iocoder.yudao.module.infra.controller.admin.job.vo.log.JobLogRespVO; |
| 11 | import cn.iocoder.yudao.module.infra.dal.dataobject.job.JobLogDO; | 11 | import cn.iocoder.yudao.module.infra.dal.dataobject.job.JobLogDO; |
| @@ -13,6 +13,9 @@ import cn.iocoder.yudao.module.infra.service.job.JobLogService; | @@ -13,6 +13,9 @@ import cn.iocoder.yudao.module.infra.service.job.JobLogService; | ||
| 13 | import io.swagger.v3.oas.annotations.Operation; | 13 | import io.swagger.v3.oas.annotations.Operation; |
| 14 | import io.swagger.v3.oas.annotations.Parameter; | 14 | import io.swagger.v3.oas.annotations.Parameter; |
| 15 | import io.swagger.v3.oas.annotations.tags.Tag; | 15 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 16 | +import jakarta.annotation.Resource; | ||
| 17 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 18 | +import jakarta.validation.Valid; | ||
| 16 | import org.springframework.security.access.prepost.PreAuthorize; | 19 | import org.springframework.security.access.prepost.PreAuthorize; |
| 17 | import org.springframework.validation.annotation.Validated; | 20 | import org.springframework.validation.annotation.Validated; |
| 18 | import org.springframework.web.bind.annotation.GetMapping; | 21 | import org.springframework.web.bind.annotation.GetMapping; |
| @@ -20,14 +23,11 @@ import org.springframework.web.bind.annotation.RequestMapping; | @@ -20,14 +23,11 @@ import org.springframework.web.bind.annotation.RequestMapping; | ||
| 20 | import org.springframework.web.bind.annotation.RequestParam; | 23 | import org.springframework.web.bind.annotation.RequestParam; |
| 21 | import org.springframework.web.bind.annotation.RestController; | 24 | import org.springframework.web.bind.annotation.RestController; |
| 22 | 25 | ||
| 23 | -import jakarta.annotation.Resource; | ||
| 24 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 25 | -import jakarta.validation.Valid; | ||
| 26 | import java.io.IOException; | 26 | import java.io.IOException; |
| 27 | import java.util.List; | 27 | import java.util.List; |
| 28 | 28 | ||
| 29 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 30 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 30 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | 31 | ||
| 32 | @Tag(name = "管理后台 - 定时任务日志") | 32 | @Tag(name = "管理后台 - 定时任务日志") |
| 33 | @RestController | 33 | @RestController |
| @@ -58,7 +58,7 @@ public class JobLogController { | @@ -58,7 +58,7 @@ public class JobLogController { | ||
| 58 | @GetMapping("/export-excel") | 58 | @GetMapping("/export-excel") |
| 59 | @Operation(summary = "导出定时任务日志 Excel") | 59 | @Operation(summary = "导出定时任务日志 Excel") |
| 60 | @PreAuthorize("@ss.hasPermission('infra:job:export')") | 60 | @PreAuthorize("@ss.hasPermission('infra:job:export')") |
| 61 | - @OperateLog(type = EXPORT) | 61 | + @ApiAccessLog(operateType = EXPORT) |
| 62 | public void exportJobLogExcel(@Valid JobLogPageReqVO exportReqVO, | 62 | public void exportJobLogExcel(@Valid JobLogPageReqVO exportReqVO, |
| 63 | HttpServletResponse response) throws IOException { | 63 | HttpServletResponse response) throws IOException { |
| 64 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 64 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/logger/ApiAccessLogController.java
| 1 | package cn.iocoder.yudao.module.infra.controller.admin.logger; | 1 | package cn.iocoder.yudao.module.infra.controller.admin.logger; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apiaccesslog.ApiAccessLogPageReqVO; | 9 | import cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apiaccesslog.ApiAccessLogPageReqVO; |
| 10 | import cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apiaccesslog.ApiAccessLogRespVO; | 10 | import cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apiaccesslog.ApiAccessLogRespVO; |
| 11 | import cn.iocoder.yudao.module.infra.dal.dataobject.logger.ApiAccessLogDO; | 11 | import cn.iocoder.yudao.module.infra.dal.dataobject.logger.ApiAccessLogDO; |
| @@ -24,8 +24,8 @@ import jakarta.validation.Valid; | @@ -24,8 +24,8 @@ import jakarta.validation.Valid; | ||
| 24 | import java.io.IOException; | 24 | import java.io.IOException; |
| 25 | import java.util.List; | 25 | import java.util.List; |
| 26 | 26 | ||
| 27 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 28 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | 29 | ||
| 30 | @Tag(name = "管理后台 - API 访问日志") | 30 | @Tag(name = "管理后台 - API 访问日志") |
| 31 | @RestController | 31 | @RestController |
| @@ -47,7 +47,7 @@ public class ApiAccessLogController { | @@ -47,7 +47,7 @@ public class ApiAccessLogController { | ||
| 47 | @GetMapping("/export-excel") | 47 | @GetMapping("/export-excel") |
| 48 | @Operation(summary = "导出API 访问日志 Excel") | 48 | @Operation(summary = "导出API 访问日志 Excel") |
| 49 | @PreAuthorize("@ss.hasPermission('infra:api-access-log:export')") | 49 | @PreAuthorize("@ss.hasPermission('infra:api-access-log:export')") |
| 50 | - @OperateLog(type = EXPORT) | 50 | + @ApiAccessLog(operateType = EXPORT) |
| 51 | public void exportApiAccessLogExcel(@Valid ApiAccessLogPageReqVO exportReqVO, | 51 | public void exportApiAccessLogExcel(@Valid ApiAccessLogPageReqVO exportReqVO, |
| 52 | HttpServletResponse response) throws IOException { | 52 | HttpServletResponse response) throws IOException { |
| 53 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 53 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/logger/ApiErrorLogController.java
| 1 | package cn.iocoder.yudao.module.infra.controller.admin.logger; | 1 | package cn.iocoder.yudao.module.infra.controller.admin.logger; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apierrorlog.ApiErrorLogPageReqVO; | 9 | import cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apierrorlog.ApiErrorLogPageReqVO; |
| 10 | import cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apierrorlog.ApiErrorLogRespVO; | 10 | import cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apierrorlog.ApiErrorLogRespVO; |
| 11 | import cn.iocoder.yudao.module.infra.dal.dataobject.logger.ApiErrorLogDO; | 11 | import cn.iocoder.yudao.module.infra.dal.dataobject.logger.ApiErrorLogDO; |
| @@ -24,8 +24,8 @@ import jakarta.validation.Valid; | @@ -24,8 +24,8 @@ import jakarta.validation.Valid; | ||
| 24 | import java.io.IOException; | 24 | import java.io.IOException; |
| 25 | import java.util.List; | 25 | import java.util.List; |
| 26 | 26 | ||
| 27 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 28 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; | 29 | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| 30 | 30 | ||
| 31 | @Tag(name = "管理后台 - API 错误日志") | 31 | @Tag(name = "管理后台 - API 错误日志") |
| @@ -61,7 +61,7 @@ public class ApiErrorLogController { | @@ -61,7 +61,7 @@ public class ApiErrorLogController { | ||
| 61 | @GetMapping("/export-excel") | 61 | @GetMapping("/export-excel") |
| 62 | @Operation(summary = "导出 API 错误日志 Excel") | 62 | @Operation(summary = "导出 API 错误日志 Excel") |
| 63 | @PreAuthorize("@ss.hasPermission('infra:api-error-log:export')") | 63 | @PreAuthorize("@ss.hasPermission('infra:api-error-log:export')") |
| 64 | - @OperateLog(type = EXPORT) | 64 | + @ApiAccessLog(operateType = EXPORT) |
| 65 | public void exportApiErrorLogExcel(@Valid ApiErrorLogPageReqVO exportReqVO, | 65 | public void exportApiErrorLogExcel(@Valid ApiErrorLogPageReqVO exportReqVO, |
| 66 | HttpServletResponse response) throws IOException { | 66 | HttpServletResponse response) throws IOException { |
| 67 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 67 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-mall/yudao-module-product-biz/pom.xml
| @@ -30,10 +30,6 @@ | @@ -30,10 +30,6 @@ | ||
| 30 | </dependency> | 30 | </dependency> |
| 31 | 31 | ||
| 32 | <!-- 业务组件 --> | 32 | <!-- 业务组件 --> |
| 33 | - <dependency> | ||
| 34 | - <groupId>cn.iocoder.boot</groupId> | ||
| 35 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 36 | - </dependency> | ||
| 37 | 33 | ||
| 38 | <!-- Web 相关 --> | 34 | <!-- Web 相关 --> |
| 39 | <dependency> | 35 | <dependency> |
yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/controller/admin/spu/ProductSpuController.java
| 1 | package cn.iocoder.yudao.module.product.controller.admin.spu; | 1 | package cn.iocoder.yudao.module.product.controller.admin.spu; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 5 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 6 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 7 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 8 | import cn.iocoder.yudao.module.product.controller.admin.spu.vo.*; | 8 | import cn.iocoder.yudao.module.product.controller.admin.spu.vo.*; |
| 9 | import cn.iocoder.yudao.module.product.convert.spu.ProductSpuConvert; | 9 | import cn.iocoder.yudao.module.product.convert.spu.ProductSpuConvert; |
| 10 | import cn.iocoder.yudao.module.product.dal.dataobject.sku.ProductSkuDO; | 10 | import cn.iocoder.yudao.module.product.dal.dataobject.sku.ProductSkuDO; |
| @@ -28,9 +28,9 @@ import java.util.Comparator; | @@ -28,9 +28,9 @@ import java.util.Comparator; | ||
| 28 | import java.util.List; | 28 | import java.util.List; |
| 29 | import java.util.Map; | 29 | import java.util.Map; |
| 30 | 30 | ||
| 31 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 32 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 32 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; | 33 | import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE; |
| 33 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 34 | 34 | ||
| 35 | @Tag(name = "管理后台 - 商品 SPU") | 35 | @Tag(name = "管理后台 - 商品 SPU") |
| 36 | @RestController | 36 | @RestController |
| @@ -127,7 +127,7 @@ public class ProductSpuController { | @@ -127,7 +127,7 @@ public class ProductSpuController { | ||
| 127 | @GetMapping("/export") | 127 | @GetMapping("/export") |
| 128 | @Operation(summary = "导出商品") | 128 | @Operation(summary = "导出商品") |
| 129 | @PreAuthorize("@ss.hasPermission('product:spu:export')") | 129 | @PreAuthorize("@ss.hasPermission('product:spu:export')") |
| 130 | - @OperateLog(type = EXPORT) | 130 | + @ApiAccessLog(operateType = EXPORT) |
| 131 | public void exportSpuList(@Validated ProductSpuPageReqVO reqVO, | 131 | public void exportSpuList(@Validated ProductSpuPageReqVO reqVO, |
| 132 | HttpServletResponse response) throws IOException { | 132 | HttpServletResponse response) throws IOException { |
| 133 | reqVO.setPageSize(PAGE_SIZE_NONE); | 133 | reqVO.setPageSize(PAGE_SIZE_NONE); |
yudao-module-mall/yudao-module-promotion-biz/pom.xml
| @@ -43,10 +43,6 @@ | @@ -43,10 +43,6 @@ | ||
| 43 | <!-- 业务组件 --> | 43 | <!-- 业务组件 --> |
| 44 | <dependency> | 44 | <dependency> |
| 45 | <groupId>cn.iocoder.boot</groupId> | 45 | <groupId>cn.iocoder.boot</groupId> |
| 46 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 47 | - </dependency> | ||
| 48 | - <dependency> | ||
| 49 | - <groupId>cn.iocoder.boot</groupId> | ||
| 50 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> | 46 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> |
| 51 | </dependency> | 47 | </dependency> |
| 52 | 48 |
yudao-module-mall/yudao-module-statistics-biz/pom.xml
| @@ -52,10 +52,6 @@ | @@ -52,10 +52,6 @@ | ||
| 52 | <!-- 业务组件 --> | 52 | <!-- 业务组件 --> |
| 53 | <dependency> | 53 | <dependency> |
| 54 | <groupId>cn.iocoder.boot</groupId> | 54 | <groupId>cn.iocoder.boot</groupId> |
| 55 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 56 | - </dependency> | ||
| 57 | - <dependency> | ||
| 58 | - <groupId>cn.iocoder.boot</groupId> | ||
| 59 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> | 55 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> |
| 60 | </dependency> | 56 | </dependency> |
| 61 | <dependency> | 57 | <dependency> |
yudao-module-mall/yudao-module-trade-biz/pom.xml
| @@ -52,10 +52,6 @@ | @@ -52,10 +52,6 @@ | ||
| 52 | <!-- 业务组件 --> | 52 | <!-- 业务组件 --> |
| 53 | <dependency> | 53 | <dependency> |
| 54 | <groupId>cn.iocoder.boot</groupId> | 54 | <groupId>cn.iocoder.boot</groupId> |
| 55 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 56 | - </dependency> | ||
| 57 | - <dependency> | ||
| 58 | - <groupId>cn.iocoder.boot</groupId> | ||
| 59 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> | 55 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> |
| 60 | </dependency> | 56 | </dependency> |
| 61 | <dependency> | 57 | <dependency> |
yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/controller/admin/aftersale/AfterSaleController.java
| @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.trade.controller.admin.aftersale; | @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.trade.controller.admin.aftersale; | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 7 | import cn.iocoder.yudao.module.member.api.user.MemberUserApi; | 6 | import cn.iocoder.yudao.module.member.api.user.MemberUserApi; |
| 8 | import cn.iocoder.yudao.module.member.api.user.dto.MemberUserRespDTO; | 7 | import cn.iocoder.yudao.module.member.api.user.dto.MemberUserRespDTO; |
| 9 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayRefundNotifyReqDTO; | 8 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayRefundNotifyReqDTO; |
| @@ -135,7 +134,6 @@ public class AfterSaleController { | @@ -135,7 +134,6 @@ public class AfterSaleController { | ||
| 135 | @PostMapping("/update-refunded") | 134 | @PostMapping("/update-refunded") |
| 136 | @Operation(summary = "更新售后订单为已退款") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob | 135 | @Operation(summary = "更新售后订单为已退款") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob |
| 137 | @PermitAll // 无需登录,安全由 PayDemoOrderService 内部校验实现 | 136 | @PermitAll // 无需登录,安全由 PayDemoOrderService 内部校验实现 |
| 138 | - @OperateLog(enable = false) // 禁用操作日志,因为没有操作人 | ||
| 139 | public CommonResult<Boolean> updateAfterRefund(@RequestBody PayRefundNotifyReqDTO notifyReqDTO) { | 137 | public CommonResult<Boolean> updateAfterRefund(@RequestBody PayRefundNotifyReqDTO notifyReqDTO) { |
| 140 | // 目前业务逻辑,不需要做任何事情 | 138 | // 目前业务逻辑,不需要做任何事情 |
| 141 | // 当然,退款会有小概率会失败的情况,可以监控失败状态,进行告警 | 139 | // 当然,退款会有小概率会失败的情况,可以监控失败状态,进行告警 |
yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/controller/admin/delivery/DeliveryExpressController.java
| 1 | package cn.iocoder.yudao.module.trade.controller.admin.delivery; | 1 | package cn.iocoder.yudao.module.trade.controller.admin.delivery; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 7 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 8 | import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.*; | 8 | import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.*; |
| 9 | import cn.iocoder.yudao.module.trade.convert.delivery.DeliveryExpressConvert; | 9 | import cn.iocoder.yudao.module.trade.convert.delivery.DeliveryExpressConvert; |
| 10 | import cn.iocoder.yudao.module.trade.dal.dataobject.delivery.DeliveryExpressDO; | 10 | import cn.iocoder.yudao.module.trade.dal.dataobject.delivery.DeliveryExpressDO; |
| @@ -12,18 +12,18 @@ import cn.iocoder.yudao.module.trade.service.delivery.DeliveryExpressService; | @@ -12,18 +12,18 @@ import cn.iocoder.yudao.module.trade.service.delivery.DeliveryExpressService; | ||
| 12 | import io.swagger.v3.oas.annotations.Operation; | 12 | import io.swagger.v3.oas.annotations.Operation; |
| 13 | import io.swagger.v3.oas.annotations.Parameter; | 13 | import io.swagger.v3.oas.annotations.Parameter; |
| 14 | import io.swagger.v3.oas.annotations.tags.Tag; | 14 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 15 | +import jakarta.annotation.Resource; | ||
| 16 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 17 | +import jakarta.validation.Valid; | ||
| 15 | import org.springframework.security.access.prepost.PreAuthorize; | 18 | import org.springframework.security.access.prepost.PreAuthorize; |
| 16 | import org.springframework.validation.annotation.Validated; | 19 | import org.springframework.validation.annotation.Validated; |
| 17 | import org.springframework.web.bind.annotation.*; | 20 | import org.springframework.web.bind.annotation.*; |
| 18 | 21 | ||
| 19 | -import jakarta.annotation.Resource; | ||
| 20 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 21 | -import jakarta.validation.Valid; | ||
| 22 | import java.io.IOException; | 22 | import java.io.IOException; |
| 23 | import java.util.List; | 23 | import java.util.List; |
| 24 | 24 | ||
| 25 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 25 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 26 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 26 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | 27 | ||
| 28 | @Tag(name = "管理后台 - 快递公司") | 28 | @Tag(name = "管理后台 - 快递公司") |
| 29 | @RestController | 29 | @RestController |
| @@ -85,7 +85,7 @@ public class DeliveryExpressController { | @@ -85,7 +85,7 @@ public class DeliveryExpressController { | ||
| 85 | @GetMapping("/export-excel") | 85 | @GetMapping("/export-excel") |
| 86 | @Operation(summary = "导出快递公司 Excel") | 86 | @Operation(summary = "导出快递公司 Excel") |
| 87 | @PreAuthorize("@ss.hasPermission('trade:delivery:express:export')") | 87 | @PreAuthorize("@ss.hasPermission('trade:delivery:express:export')") |
| 88 | - @OperateLog(type = EXPORT) | 88 | + @ApiAccessLog(operateType = EXPORT) |
| 89 | public void exportDeliveryExpressExcel(@Valid DeliveryExpressExportReqVO exportReqVO, | 89 | public void exportDeliveryExpressExcel(@Valid DeliveryExpressExportReqVO exportReqVO, |
| 90 | HttpServletResponse response) throws IOException { | 90 | HttpServletResponse response) throws IOException { |
| 91 | List<DeliveryExpressDO> list = deliveryExpressService.getDeliveryExpressList(exportReqVO); | 91 | List<DeliveryExpressDO> list = deliveryExpressService.getDeliveryExpressList(exportReqVO); |
yudao-module-member/yudao-module-member-biz/pom.xml
| @@ -37,10 +37,6 @@ | @@ -37,10 +37,6 @@ | ||
| 37 | <!-- 业务组件 --> | 37 | <!-- 业务组件 --> |
| 38 | <dependency> | 38 | <dependency> |
| 39 | <groupId>cn.iocoder.boot</groupId> | 39 | <groupId>cn.iocoder.boot</groupId> |
| 40 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 41 | - </dependency> | ||
| 42 | - <dependency> | ||
| 43 | - <groupId>cn.iocoder.boot</groupId> | ||
| 44 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> | 40 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> |
| 45 | </dependency> | 41 | </dependency> |
| 46 | 42 |
yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/app/auth/AppAuthController.java
| @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.member.controller.app.auth; | @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.member.controller.app.auth; | ||
| 3 | import cn.hutool.core.util.StrUtil; | 3 | import cn.hutool.core.util.StrUtil; |
| 4 | import cn.iocoder.yudao.framework.common.enums.UserTypeEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.UserTypeEnum; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 6 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 7 | import cn.iocoder.yudao.framework.security.config.SecurityProperties; | 6 | import cn.iocoder.yudao.framework.security.config.SecurityProperties; |
| 8 | import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils; | 7 | import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils; |
| 9 | import cn.iocoder.yudao.module.member.controller.app.auth.vo.*; | 8 | import cn.iocoder.yudao.module.member.controller.app.auth.vo.*; |
| @@ -64,7 +63,6 @@ public class AppAuthController { | @@ -64,7 +63,6 @@ public class AppAuthController { | ||
| 64 | @PostMapping("/refresh-token") | 63 | @PostMapping("/refresh-token") |
| 65 | @Operation(summary = "刷新令牌") | 64 | @Operation(summary = "刷新令牌") |
| 66 | @Parameter(name = "refreshToken", description = "刷新令牌", required = true) | 65 | @Parameter(name = "refreshToken", description = "刷新令牌", required = true) |
| 67 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 68 | public CommonResult<AppAuthLoginRespVO> refreshToken(@RequestParam("refreshToken") String refreshToken) { | 66 | public CommonResult<AppAuthLoginRespVO> refreshToken(@RequestParam("refreshToken") String refreshToken) { |
| 69 | return success(authService.refreshToken(refreshToken)); | 67 | return success(authService.refreshToken(refreshToken)); |
| 70 | } | 68 | } |
yudao-module-mp/yudao-module-mp-biz/pom.xml
| @@ -37,10 +37,6 @@ | @@ -37,10 +37,6 @@ | ||
| 37 | <!-- 业务组件 --> | 37 | <!-- 业务组件 --> |
| 38 | <dependency> | 38 | <dependency> |
| 39 | <groupId>cn.iocoder.boot</groupId> | 39 | <groupId>cn.iocoder.boot</groupId> |
| 40 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 41 | - </dependency> | ||
| 42 | - <dependency> | ||
| 43 | - <groupId>cn.iocoder.boot</groupId> | ||
| 44 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> | 40 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> |
| 45 | </dependency> | 41 | </dependency> |
| 46 | 42 |
yudao-module-mp/yudao-module-mp-biz/src/main/java/cn/iocoder/yudao/module/mp/controller/admin/open/MpOpenController.java
| @@ -2,7 +2,6 @@ package cn.iocoder.yudao.module.mp.controller.admin.open; | @@ -2,7 +2,6 @@ package cn.iocoder.yudao.module.mp.controller.admin.open; | ||
| 2 | 2 | ||
| 3 | import cn.hutool.core.lang.Assert; | 3 | import cn.hutool.core.lang.Assert; |
| 4 | import cn.hutool.core.util.StrUtil; | 4 | import cn.hutool.core.util.StrUtil; |
| 5 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 6 | import cn.iocoder.yudao.framework.tenant.core.util.TenantUtils; | 5 | import cn.iocoder.yudao.framework.tenant.core.util.TenantUtils; |
| 7 | import cn.iocoder.yudao.module.mp.controller.admin.open.vo.MpOpenCheckSignatureReqVO; | 6 | import cn.iocoder.yudao.module.mp.controller.admin.open.vo.MpOpenCheckSignatureReqVO; |
| 8 | import cn.iocoder.yudao.module.mp.controller.admin.open.vo.MpOpenHandleMessageReqVO; | 7 | import cn.iocoder.yudao.module.mp.controller.admin.open.vo.MpOpenHandleMessageReqVO; |
| @@ -63,7 +62,6 @@ public class MpOpenController { | @@ -63,7 +62,6 @@ public class MpOpenController { | ||
| 63 | */ | 62 | */ |
| 64 | @Operation(summary = "处理消息") | 63 | @Operation(summary = "处理消息") |
| 65 | @PostMapping(value = "/{appId}", produces = "application/xml; charset=UTF-8") | 64 | @PostMapping(value = "/{appId}", produces = "application/xml; charset=UTF-8") |
| 66 | - @OperateLog(enable = false) // 回调地址,无需记录操作日志 | ||
| 67 | public String handleMessage(@PathVariable("appId") String appId, | 65 | public String handleMessage(@PathVariable("appId") String appId, |
| 68 | @RequestBody String content, | 66 | @RequestBody String content, |
| 69 | MpOpenHandleMessageReqVO reqVO) { | 67 | MpOpenHandleMessageReqVO reqVO) { |
yudao-module-pay/yudao-module-pay-biz/pom.xml
| @@ -32,10 +32,6 @@ | @@ -32,10 +32,6 @@ | ||
| 32 | <!-- 业务组件 --> | 32 | <!-- 业务组件 --> |
| 33 | <dependency> | 33 | <dependency> |
| 34 | <groupId>cn.iocoder.boot</groupId> | 34 | <groupId>cn.iocoder.boot</groupId> |
| 35 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 36 | - </dependency> | ||
| 37 | - <dependency> | ||
| 38 | - <groupId>cn.iocoder.boot</groupId> | ||
| 39 | <artifactId>yudao-spring-boot-starter-biz-pay</artifactId> | 35 | <artifactId>yudao-spring-boot-starter-biz-pay</artifactId> |
| 40 | <version>${revision}</version> | 36 | <version>${revision}</version> |
| 41 | </dependency> | 37 | </dependency> |
yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/controller/admin/demo/PayDemoOrderController.java
| @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.pay.controller.admin.demo; | @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.pay.controller.admin.demo; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 7 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayOrderNotifyReqDTO; | 6 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayOrderNotifyReqDTO; |
| 8 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayRefundNotifyReqDTO; | 7 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayRefundNotifyReqDTO; |
| 9 | import cn.iocoder.yudao.module.pay.controller.admin.demo.vo.order.PayDemoOrderCreateReqVO; | 8 | import cn.iocoder.yudao.module.pay.controller.admin.demo.vo.order.PayDemoOrderCreateReqVO; |
| @@ -50,7 +49,6 @@ public class PayDemoOrderController { | @@ -50,7 +49,6 @@ public class PayDemoOrderController { | ||
| 50 | @PostMapping("/update-paid") | 49 | @PostMapping("/update-paid") |
| 51 | @Operation(summary = "更新示例订单为已支付") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob | 50 | @Operation(summary = "更新示例订单为已支付") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob |
| 52 | @PermitAll // 无需登录,安全由 PayDemoOrderService 内部校验实现 | 51 | @PermitAll // 无需登录,安全由 PayDemoOrderService 内部校验实现 |
| 53 | - @OperateLog(enable = false) // 禁用操作日志,因为没有操作人 | ||
| 54 | public CommonResult<Boolean> updateDemoOrderPaid(@RequestBody PayOrderNotifyReqDTO notifyReqDTO) { | 52 | public CommonResult<Boolean> updateDemoOrderPaid(@RequestBody PayOrderNotifyReqDTO notifyReqDTO) { |
| 55 | payDemoOrderService.updateDemoOrderPaid(Long.valueOf(notifyReqDTO.getMerchantOrderId()), | 53 | payDemoOrderService.updateDemoOrderPaid(Long.valueOf(notifyReqDTO.getMerchantOrderId()), |
| 56 | notifyReqDTO.getPayOrderId()); | 54 | notifyReqDTO.getPayOrderId()); |
| @@ -68,7 +66,6 @@ public class PayDemoOrderController { | @@ -68,7 +66,6 @@ public class PayDemoOrderController { | ||
| 68 | @PostMapping("/update-refunded") | 66 | @PostMapping("/update-refunded") |
| 69 | @Operation(summary = "更新示例订单为已退款") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob | 67 | @Operation(summary = "更新示例订单为已退款") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob |
| 70 | @PermitAll // 无需登录,安全由 PayDemoOrderService 内部校验实现 | 68 | @PermitAll // 无需登录,安全由 PayDemoOrderService 内部校验实现 |
| 71 | - @OperateLog(enable = false) // 禁用操作日志,因为没有操作人 | ||
| 72 | public CommonResult<Boolean> updateDemoOrderRefunded(@RequestBody PayRefundNotifyReqDTO notifyReqDTO) { | 69 | public CommonResult<Boolean> updateDemoOrderRefunded(@RequestBody PayRefundNotifyReqDTO notifyReqDTO) { |
| 73 | payDemoOrderService.updateDemoOrderRefunded(Long.valueOf(notifyReqDTO.getMerchantOrderId()), | 70 | payDemoOrderService.updateDemoOrderRefunded(Long.valueOf(notifyReqDTO.getMerchantOrderId()), |
| 74 | notifyReqDTO.getPayRefundId()); | 71 | notifyReqDTO.getPayRefundId()); |
yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/controller/admin/demo/PayDemoTransferController.java
| @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.pay.controller.admin.demo; | @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.pay.controller.admin.demo; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 7 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayTransferNotifyReqDTO; | 6 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayTransferNotifyReqDTO; |
| 8 | import cn.iocoder.yudao.module.pay.controller.admin.demo.vo.transfer.PayDemoTransferCreateReqVO; | 7 | import cn.iocoder.yudao.module.pay.controller.admin.demo.vo.transfer.PayDemoTransferCreateReqVO; |
| 9 | import cn.iocoder.yudao.module.pay.controller.admin.demo.vo.transfer.PayDemoTransferRespVO; | 8 | import cn.iocoder.yudao.module.pay.controller.admin.demo.vo.transfer.PayDemoTransferRespVO; |
| @@ -45,7 +44,6 @@ public class PayDemoTransferController { | @@ -45,7 +44,6 @@ public class PayDemoTransferController { | ||
| 45 | @PostMapping("/update-status") | 44 | @PostMapping("/update-status") |
| 46 | @Operation(summary = "更新示例转账订单的转账状态") // 由 pay-module 转账服务,进行回调 | 45 | @Operation(summary = "更新示例转账订单的转账状态") // 由 pay-module 转账服务,进行回调 |
| 47 | @PermitAll // 无需登录,安全由 PayDemoTransferService 内部校验实现 | 46 | @PermitAll // 无需登录,安全由 PayDemoTransferService 内部校验实现 |
| 48 | - @OperateLog(enable = false) // 禁用操作日志,因为没有操作人 | ||
| 49 | public CommonResult<Boolean> updateDemoTransferStatus(@RequestBody PayTransferNotifyReqDTO notifyReqDTO) { | 47 | public CommonResult<Boolean> updateDemoTransferStatus(@RequestBody PayTransferNotifyReqDTO notifyReqDTO) { |
| 50 | demoTransferService.updateDemoTransferStatus(Long.valueOf(notifyReqDTO.getMerchantTransferId()), | 48 | demoTransferService.updateDemoTransferStatus(Long.valueOf(notifyReqDTO.getMerchantTransferId()), |
| 51 | notifyReqDTO.getPayTransferId()); | 49 | notifyReqDTO.getPayTransferId()); |
yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/controller/admin/notify/PayNotifyController.java
| @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.pay.controller.admin.notify; | @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.pay.controller.admin.notify; | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 7 | import cn.iocoder.yudao.framework.pay.core.client.PayClient; | 6 | import cn.iocoder.yudao.framework.pay.core.client.PayClient; |
| 8 | import cn.iocoder.yudao.framework.pay.core.client.dto.order.PayOrderRespDTO; | 7 | import cn.iocoder.yudao.framework.pay.core.client.dto.order.PayOrderRespDTO; |
| 9 | import cn.iocoder.yudao.framework.pay.core.client.dto.refund.PayRefundRespDTO; | 8 | import cn.iocoder.yudao.framework.pay.core.client.dto.refund.PayRefundRespDTO; |
| @@ -59,7 +58,6 @@ public class PayNotifyController { | @@ -59,7 +58,6 @@ public class PayNotifyController { | ||
| 59 | @PostMapping(value = "/order/{channelId}") | 58 | @PostMapping(value = "/order/{channelId}") |
| 60 | @Operation(summary = "支付渠道的统一【支付】回调") | 59 | @Operation(summary = "支付渠道的统一【支付】回调") |
| 61 | @PermitAll | 60 | @PermitAll |
| 62 | - @OperateLog(enable = false) // 回调地址,无需记录操作日志 | ||
| 63 | public String notifyOrder(@PathVariable("channelId") Long channelId, | 61 | public String notifyOrder(@PathVariable("channelId") Long channelId, |
| 64 | @RequestParam(required = false) Map<String, String> params, | 62 | @RequestParam(required = false) Map<String, String> params, |
| 65 | @RequestBody(required = false) String body) { | 63 | @RequestBody(required = false) String body) { |
| @@ -80,7 +78,6 @@ public class PayNotifyController { | @@ -80,7 +78,6 @@ public class PayNotifyController { | ||
| 80 | @PostMapping(value = "/refund/{channelId}") | 78 | @PostMapping(value = "/refund/{channelId}") |
| 81 | @Operation(summary = "支付渠道的统一【退款】回调") | 79 | @Operation(summary = "支付渠道的统一【退款】回调") |
| 82 | @PermitAll | 80 | @PermitAll |
| 83 | - @OperateLog(enable = false) // 回调地址,无需记录操作日志 | ||
| 84 | public String notifyRefund(@PathVariable("channelId") Long channelId, | 81 | public String notifyRefund(@PathVariable("channelId") Long channelId, |
| 85 | @RequestParam(required = false) Map<String, String> params, | 82 | @RequestParam(required = false) Map<String, String> params, |
| 86 | @RequestBody(required = false) String body) { | 83 | @RequestBody(required = false) String body) { |
yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/controller/admin/order/PayOrderController.java
| 1 | package cn.iocoder.yudao.module.pay.controller.admin.order; | 1 | package cn.iocoder.yudao.module.pay.controller.admin.order; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollectionUtil; | 3 | import cn.hutool.core.collection.CollectionUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 7 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 8 | import cn.iocoder.yudao.framework.pay.core.enums.channel.PayChannelEnum; | 8 | import cn.iocoder.yudao.framework.pay.core.enums.channel.PayChannelEnum; |
| 9 | import cn.iocoder.yudao.module.pay.controller.admin.order.vo.*; | 9 | import cn.iocoder.yudao.module.pay.controller.admin.order.vo.*; |
| 10 | import cn.iocoder.yudao.module.pay.convert.order.PayOrderConvert; | 10 | import cn.iocoder.yudao.module.pay.convert.order.PayOrderConvert; |
| @@ -18,23 +18,23 @@ import com.google.common.collect.Maps; | @@ -18,23 +18,23 @@ import com.google.common.collect.Maps; | ||
| 18 | import io.swagger.v3.oas.annotations.Operation; | 18 | import io.swagger.v3.oas.annotations.Operation; |
| 19 | import io.swagger.v3.oas.annotations.Parameter; | 19 | import io.swagger.v3.oas.annotations.Parameter; |
| 20 | import io.swagger.v3.oas.annotations.tags.Tag; | 20 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 21 | +import jakarta.annotation.Resource; | ||
| 22 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 23 | +import jakarta.validation.Valid; | ||
| 21 | import org.springframework.security.access.prepost.PreAuthorize; | 24 | import org.springframework.security.access.prepost.PreAuthorize; |
| 22 | import org.springframework.validation.annotation.Validated; | 25 | import org.springframework.validation.annotation.Validated; |
| 23 | import org.springframework.web.bind.annotation.*; | 26 | import org.springframework.web.bind.annotation.*; |
| 24 | 27 | ||
| 25 | -import jakarta.annotation.Resource; | ||
| 26 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 27 | -import jakarta.validation.Valid; | ||
| 28 | import java.io.IOException; | 28 | import java.io.IOException; |
| 29 | import java.util.ArrayList; | 29 | import java.util.ArrayList; |
| 30 | import java.util.List; | 30 | import java.util.List; |
| 31 | import java.util.Map; | 31 | import java.util.Map; |
| 32 | import java.util.Objects; | 32 | import java.util.Objects; |
| 33 | 33 | ||
| 34 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 34 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 35 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 35 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 36 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 36 | import static cn.iocoder.yudao.framework.common.util.servlet.ServletUtils.getClientIP; | 37 | import static cn.iocoder.yudao.framework.common.util.servlet.ServletUtils.getClientIP; |
| 37 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 38 | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; | 38 | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| 39 | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserType; | 39 | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserType; |
| 40 | 40 | ||
| @@ -107,7 +107,7 @@ public class PayOrderController { | @@ -107,7 +107,7 @@ public class PayOrderController { | ||
| 107 | @GetMapping("/export-excel") | 107 | @GetMapping("/export-excel") |
| 108 | @Operation(summary = "导出支付订单 Excel") | 108 | @Operation(summary = "导出支付订单 Excel") |
| 109 | @PreAuthorize("@ss.hasPermission('pay:order:export')") | 109 | @PreAuthorize("@ss.hasPermission('pay:order:export')") |
| 110 | - @OperateLog(type = EXPORT) | 110 | + @ApiAccessLog(operateType = EXPORT) |
| 111 | public void exportOrderExcel(@Valid PayOrderExportReqVO exportReqVO, | 111 | public void exportOrderExcel(@Valid PayOrderExportReqVO exportReqVO, |
| 112 | HttpServletResponse response) throws IOException { | 112 | HttpServletResponse response) throws IOException { |
| 113 | List<PayOrderDO> list = orderService.getOrderList(exportReqVO); | 113 | List<PayOrderDO> list = orderService.getOrderList(exportReqVO); |
yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/controller/admin/refund/PayRefundController.java
| 1 | package cn.iocoder.yudao.module.pay.controller.admin.refund; | 1 | package cn.iocoder.yudao.module.pay.controller.admin.refund; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollectionUtil; | 3 | import cn.hutool.core.collection.CollectionUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 7 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 8 | import cn.iocoder.yudao.module.pay.controller.admin.refund.vo.*; | 8 | import cn.iocoder.yudao.module.pay.controller.admin.refund.vo.*; |
| 9 | import cn.iocoder.yudao.module.pay.convert.refund.PayRefundConvert; | 9 | import cn.iocoder.yudao.module.pay.convert.refund.PayRefundConvert; |
| 10 | import cn.iocoder.yudao.module.pay.dal.dataobject.app.PayAppDO; | 10 | import cn.iocoder.yudao.module.pay.dal.dataobject.app.PayAppDO; |
| @@ -14,6 +14,9 @@ import cn.iocoder.yudao.module.pay.service.refund.PayRefundService; | @@ -14,6 +14,9 @@ import cn.iocoder.yudao.module.pay.service.refund.PayRefundService; | ||
| 14 | import io.swagger.v3.oas.annotations.Operation; | 14 | import io.swagger.v3.oas.annotations.Operation; |
| 15 | import io.swagger.v3.oas.annotations.Parameter; | 15 | import io.swagger.v3.oas.annotations.Parameter; |
| 16 | import io.swagger.v3.oas.annotations.tags.Tag; | 16 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 17 | +import jakarta.annotation.Resource; | ||
| 18 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 19 | +import jakarta.validation.Valid; | ||
| 17 | import org.springframework.security.access.prepost.PreAuthorize; | 20 | import org.springframework.security.access.prepost.PreAuthorize; |
| 18 | import org.springframework.validation.annotation.Validated; | 21 | import org.springframework.validation.annotation.Validated; |
| 19 | import org.springframework.web.bind.annotation.GetMapping; | 22 | import org.springframework.web.bind.annotation.GetMapping; |
| @@ -21,17 +24,14 @@ import org.springframework.web.bind.annotation.RequestMapping; | @@ -21,17 +24,14 @@ import org.springframework.web.bind.annotation.RequestMapping; | ||
| 21 | import org.springframework.web.bind.annotation.RequestParam; | 24 | import org.springframework.web.bind.annotation.RequestParam; |
| 22 | import org.springframework.web.bind.annotation.RestController; | 25 | import org.springframework.web.bind.annotation.RestController; |
| 23 | 26 | ||
| 24 | -import jakarta.annotation.Resource; | ||
| 25 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 26 | -import jakarta.validation.Valid; | ||
| 27 | import java.io.IOException; | 27 | import java.io.IOException; |
| 28 | import java.util.ArrayList; | 28 | import java.util.ArrayList; |
| 29 | import java.util.List; | 29 | import java.util.List; |
| 30 | import java.util.Map; | 30 | import java.util.Map; |
| 31 | 31 | ||
| 32 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 32 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 33 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 33 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 34 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 34 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 35 | 35 | ||
| 36 | @Tag(name = "管理后台 - 退款订单") | 36 | @Tag(name = "管理后台 - 退款订单") |
| 37 | @RestController | 37 | @RestController |
| @@ -76,7 +76,7 @@ public class PayRefundController { | @@ -76,7 +76,7 @@ public class PayRefundController { | ||
| 76 | @GetMapping("/export-excel") | 76 | @GetMapping("/export-excel") |
| 77 | @Operation(summary = "导出退款订单 Excel") | 77 | @Operation(summary = "导出退款订单 Excel") |
| 78 | @PreAuthorize("@ss.hasPermission('pay:refund:export')") | 78 | @PreAuthorize("@ss.hasPermission('pay:refund:export')") |
| 79 | - @OperateLog(type = EXPORT) | 79 | + @ApiAccessLog(operateType = EXPORT) |
| 80 | public void exportRefundExcel(@Valid PayRefundExportReqVO exportReqVO, | 80 | public void exportRefundExcel(@Valid PayRefundExportReqVO exportReqVO, |
| 81 | HttpServletResponse response) throws IOException { | 81 | HttpServletResponse response) throws IOException { |
| 82 | List<PayRefundDO> list = refundService.getRefundList(exportReqVO); | 82 | List<PayRefundDO> list = refundService.getRefundList(exportReqVO); |
yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/controller/admin/wallet/PayWalletRechargeController.java
| 1 | package cn.iocoder.yudao.module.pay.controller.admin.wallet; | 1 | package cn.iocoder.yudao.module.pay.controller.admin.wallet; |
| 2 | 2 | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 5 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayOrderNotifyReqDTO; | 4 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayOrderNotifyReqDTO; |
| 6 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayRefundNotifyReqDTO; | 5 | import cn.iocoder.yudao.module.pay.api.notify.dto.PayRefundNotifyReqDTO; |
| 7 | import cn.iocoder.yudao.module.pay.service.wallet.PayWalletRechargeService; | 6 | import cn.iocoder.yudao.module.pay.service.wallet.PayWalletRechargeService; |
| @@ -32,7 +31,6 @@ public class PayWalletRechargeController { | @@ -32,7 +31,6 @@ public class PayWalletRechargeController { | ||
| 32 | @PostMapping("/update-paid") | 31 | @PostMapping("/update-paid") |
| 33 | @Operation(summary = "更新钱包充值为已充值") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob | 32 | @Operation(summary = "更新钱包充值为已充值") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob |
| 34 | @PermitAll // 无需登录, 内部校验实现 | 33 | @PermitAll // 无需登录, 内部校验实现 |
| 35 | - @OperateLog(enable = false) // 禁用操作日志,因为没有操作人 | ||
| 36 | public CommonResult<Boolean> updateWalletRechargerPaid(@Valid @RequestBody PayOrderNotifyReqDTO notifyReqDTO) { | 34 | public CommonResult<Boolean> updateWalletRechargerPaid(@Valid @RequestBody PayOrderNotifyReqDTO notifyReqDTO) { |
| 37 | walletRechargeService.updateWalletRechargerPaid(Long.valueOf(notifyReqDTO.getMerchantOrderId()), | 35 | walletRechargeService.updateWalletRechargerPaid(Long.valueOf(notifyReqDTO.getMerchantOrderId()), |
| 38 | notifyReqDTO.getPayOrderId()); | 36 | notifyReqDTO.getPayOrderId()); |
| @@ -51,7 +49,6 @@ public class PayWalletRechargeController { | @@ -51,7 +49,6 @@ public class PayWalletRechargeController { | ||
| 51 | @PostMapping("/update-refunded") | 49 | @PostMapping("/update-refunded") |
| 52 | @Operation(summary = "更新钱包充值为已退款") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob | 50 | @Operation(summary = "更新钱包充值为已退款") // 由 pay-module 支付服务,进行回调,可见 PayNotifyJob |
| 53 | @PermitAll // 无需登录, 内部校验实现 | 51 | @PermitAll // 无需登录, 内部校验实现 |
| 54 | - @OperateLog(enable = false) // 禁用操作日志,因为没有操作人 | ||
| 55 | public CommonResult<Boolean> updateWalletRechargeRefunded(@RequestBody PayRefundNotifyReqDTO notifyReqDTO) { | 52 | public CommonResult<Boolean> updateWalletRechargeRefunded(@RequestBody PayRefundNotifyReqDTO notifyReqDTO) { |
| 56 | walletRechargeService.updateWalletRechargeRefunded( | 53 | walletRechargeService.updateWalletRechargeRefunded( |
| 57 | Long.valueOf(notifyReqDTO.getMerchantOrderId()), notifyReqDTO.getPayRefundId()); | 54 | Long.valueOf(notifyReqDTO.getMerchantOrderId()), notifyReqDTO.getPayRefundId()); |
yudao-module-report/yudao-module-report-biz/pom.xml
| @@ -33,10 +33,6 @@ | @@ -33,10 +33,6 @@ | ||
| 33 | <!-- 业务组件 --> | 33 | <!-- 业务组件 --> |
| 34 | <dependency> | 34 | <dependency> |
| 35 | <groupId>cn.iocoder.boot</groupId> | 35 | <groupId>cn.iocoder.boot</groupId> |
| 36 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 37 | - </dependency> | ||
| 38 | - <dependency> | ||
| 39 | - <groupId>cn.iocoder.boot</groupId> | ||
| 40 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> | 36 | <artifactId>yudao-spring-boot-starter-biz-tenant</artifactId> |
| 41 | </dependency> | 37 | </dependency> |
| 42 | 38 |
yudao-module-report/yudao-module-report-biz/src/main/java/cn/iocoder/yudao/module/report/controller/admin/goview/GoViewDataController.java
| @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.report.controller.admin.goview; | @@ -3,7 +3,6 @@ package cn.iocoder.yudao.module.report.controller.admin.goview; | ||
| 3 | import cn.hutool.core.map.MapUtil; | 3 | import cn.hutool.core.map.MapUtil; |
| 4 | import cn.hutool.core.util.RandomUtil; | 4 | import cn.hutool.core.util.RandomUtil; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 6 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 7 | import cn.iocoder.yudao.module.report.controller.admin.goview.vo.data.GoViewDataGetBySqlReqVO; | 6 | import cn.iocoder.yudao.module.report.controller.admin.goview.vo.data.GoViewDataGetBySqlReqVO; |
| 8 | import cn.iocoder.yudao.module.report.controller.admin.goview.vo.data.GoViewDataRespVO; | 7 | import cn.iocoder.yudao.module.report.controller.admin.goview.vo.data.GoViewDataRespVO; |
| 9 | import cn.iocoder.yudao.module.report.service.goview.GoViewDataService; | 8 | import cn.iocoder.yudao.module.report.service.goview.GoViewDataService; |
| @@ -35,7 +34,6 @@ public class GoViewDataController { | @@ -35,7 +34,6 @@ public class GoViewDataController { | ||
| 35 | @RequestMapping("/get-by-sql") | 34 | @RequestMapping("/get-by-sql") |
| 36 | @Operation(summary = "使用 SQL 查询数据") | 35 | @Operation(summary = "使用 SQL 查询数据") |
| 37 | @PreAuthorize("@ss.hasPermission('report:go-view-data:get-by-sql')") | 36 | @PreAuthorize("@ss.hasPermission('report:go-view-data:get-by-sql')") |
| 38 | - @OperateLog(enable = false) // 不记录操作日志,因为不需要 | ||
| 39 | public CommonResult<GoViewDataRespVO> getDataBySQL(@Valid @RequestBody GoViewDataGetBySqlReqVO reqVO) { | 37 | public CommonResult<GoViewDataRespVO> getDataBySQL(@Valid @RequestBody GoViewDataGetBySqlReqVO reqVO) { |
| 40 | return success(goViewDataService.getDataBySQL(reqVO.getSql())); | 38 | return success(goViewDataService.getDataBySQL(reqVO.getSql())); |
| 41 | } | 39 | } |
| @@ -43,7 +41,6 @@ public class GoViewDataController { | @@ -43,7 +41,6 @@ public class GoViewDataController { | ||
| 43 | @RequestMapping("/get-by-http") | 41 | @RequestMapping("/get-by-http") |
| 44 | @Operation(summary = "使用 HTTP 查询数据", description = "这个只是示例接口,实际应该每个查询,都要写一个接口") | 42 | @Operation(summary = "使用 HTTP 查询数据", description = "这个只是示例接口,实际应该每个查询,都要写一个接口") |
| 45 | @PreAuthorize("@ss.hasPermission('report:go-view-data:get-by-http')") | 43 | @PreAuthorize("@ss.hasPermission('report:go-view-data:get-by-http')") |
| 46 | - @OperateLog(enable = false) // 不记录操作日志,因为不需要 | ||
| 47 | public CommonResult<GoViewDataRespVO> getDataByHttp( | 44 | public CommonResult<GoViewDataRespVO> getDataByHttp( |
| 48 | @RequestParam(required = false) Map<String, String> params, | 45 | @RequestParam(required = false) Map<String, String> params, |
| 49 | @RequestBody(required = false) String body) { // params、body 按照需要去接收,这里仅仅是示例 | 46 | @RequestBody(required = false) String body) { // params、body 按照需要去接收,这里仅仅是示例 |
yudao-module-system/yudao-module-system-biz/pom.xml
| @@ -32,10 +32,6 @@ | @@ -32,10 +32,6 @@ | ||
| 32 | <!-- 业务组件 --> | 32 | <!-- 业务组件 --> |
| 33 | <dependency> | 33 | <dependency> |
| 34 | <groupId>cn.iocoder.boot</groupId> | 34 | <groupId>cn.iocoder.boot</groupId> |
| 35 | - <artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId> | ||
| 36 | - </dependency> | ||
| 37 | - <dependency> | ||
| 38 | - <groupId>cn.iocoder.boot</groupId> | ||
| 39 | <artifactId>yudao-spring-boot-starter-biz-data-permission</artifactId> | 35 | <artifactId>yudao-spring-boot-starter-biz-data-permission</artifactId> |
| 40 | </dependency> | 36 | </dependency> |
| 41 | <dependency> | 37 | <dependency> |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/auth/AuthController.java
| @@ -5,7 +5,6 @@ import cn.hutool.core.util.StrUtil; | @@ -5,7 +5,6 @@ import cn.hutool.core.util.StrUtil; | ||
| 5 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 5 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 6 | import cn.iocoder.yudao.framework.common.enums.UserTypeEnum; | 6 | import cn.iocoder.yudao.framework.common.enums.UserTypeEnum; |
| 7 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.framework.security.config.SecurityProperties; | 8 | import cn.iocoder.yudao.framework.security.config.SecurityProperties; |
| 10 | import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils; | 9 | import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils; |
| 11 | import cn.iocoder.yudao.module.system.controller.admin.auth.vo.*; | 10 | import cn.iocoder.yudao.module.system.controller.admin.auth.vo.*; |
| @@ -66,7 +65,6 @@ public class AuthController { | @@ -66,7 +65,6 @@ public class AuthController { | ||
| 66 | @PostMapping("/login") | 65 | @PostMapping("/login") |
| 67 | @PermitAll | 66 | @PermitAll |
| 68 | @Operation(summary = "使用账号密码登录") | 67 | @Operation(summary = "使用账号密码登录") |
| 69 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 70 | public CommonResult<AuthLoginRespVO> login(@RequestBody @Valid AuthLoginReqVO reqVO) { | 68 | public CommonResult<AuthLoginRespVO> login(@RequestBody @Valid AuthLoginReqVO reqVO) { |
| 71 | return success(authService.login(reqVO)); | 69 | return success(authService.login(reqVO)); |
| 72 | } | 70 | } |
| @@ -74,7 +72,6 @@ public class AuthController { | @@ -74,7 +72,6 @@ public class AuthController { | ||
| 74 | @PostMapping("/logout") | 72 | @PostMapping("/logout") |
| 75 | @PermitAll | 73 | @PermitAll |
| 76 | @Operation(summary = "登出系统") | 74 | @Operation(summary = "登出系统") |
| 77 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 78 | public CommonResult<Boolean> logout(HttpServletRequest request) { | 75 | public CommonResult<Boolean> logout(HttpServletRequest request) { |
| 79 | String token = SecurityFrameworkUtils.obtainAuthorization(request, | 76 | String token = SecurityFrameworkUtils.obtainAuthorization(request, |
| 80 | securityProperties.getTokenHeader(), securityProperties.getTokenParameter()); | 77 | securityProperties.getTokenHeader(), securityProperties.getTokenParameter()); |
| @@ -88,7 +85,6 @@ public class AuthController { | @@ -88,7 +85,6 @@ public class AuthController { | ||
| 88 | @PermitAll | 85 | @PermitAll |
| 89 | @Operation(summary = "刷新令牌") | 86 | @Operation(summary = "刷新令牌") |
| 90 | @Parameter(name = "refreshToken", description = "刷新令牌", required = true) | 87 | @Parameter(name = "refreshToken", description = "刷新令牌", required = true) |
| 91 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 92 | public CommonResult<AuthLoginRespVO> refreshToken(@RequestParam("refreshToken") String refreshToken) { | 88 | public CommonResult<AuthLoginRespVO> refreshToken(@RequestParam("refreshToken") String refreshToken) { |
| 93 | return success(authService.refreshToken(refreshToken)); | 89 | return success(authService.refreshToken(refreshToken)); |
| 94 | } | 90 | } |
| @@ -124,7 +120,6 @@ public class AuthController { | @@ -124,7 +120,6 @@ public class AuthController { | ||
| 124 | @PostMapping("/sms-login") | 120 | @PostMapping("/sms-login") |
| 125 | @PermitAll | 121 | @PermitAll |
| 126 | @Operation(summary = "使用短信验证码登录") | 122 | @Operation(summary = "使用短信验证码登录") |
| 127 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 128 | public CommonResult<AuthLoginRespVO> smsLogin(@RequestBody @Valid AuthSmsLoginReqVO reqVO) { | 123 | public CommonResult<AuthLoginRespVO> smsLogin(@RequestBody @Valid AuthSmsLoginReqVO reqVO) { |
| 129 | return success(authService.smsLogin(reqVO)); | 124 | return success(authService.smsLogin(reqVO)); |
| 130 | } | 125 | } |
| @@ -132,7 +127,6 @@ public class AuthController { | @@ -132,7 +127,6 @@ public class AuthController { | ||
| 132 | @PostMapping("/send-sms-code") | 127 | @PostMapping("/send-sms-code") |
| 133 | @PermitAll | 128 | @PermitAll |
| 134 | @Operation(summary = "发送手机验证码") | 129 | @Operation(summary = "发送手机验证码") |
| 135 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 136 | public CommonResult<Boolean> sendLoginSmsCode(@RequestBody @Valid AuthSmsSendReqVO reqVO) { | 130 | public CommonResult<Boolean> sendLoginSmsCode(@RequestBody @Valid AuthSmsSendReqVO reqVO) { |
| 137 | authService.sendSmsCode(reqVO); | 131 | authService.sendSmsCode(reqVO); |
| 138 | return success(true); | 132 | return success(true); |
| @@ -156,7 +150,6 @@ public class AuthController { | @@ -156,7 +150,6 @@ public class AuthController { | ||
| 156 | @PostMapping("/social-login") | 150 | @PostMapping("/social-login") |
| 157 | @PermitAll | 151 | @PermitAll |
| 158 | @Operation(summary = "社交快捷登录,使用 code 授权码", description = "适合未登录的用户,但是社交账号已绑定用户") | 152 | @Operation(summary = "社交快捷登录,使用 code 授权码", description = "适合未登录的用户,但是社交账号已绑定用户") |
| 159 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 160 | public CommonResult<AuthLoginRespVO> socialQuickLogin(@RequestBody @Valid AuthSocialLoginReqVO reqVO) { | 153 | public CommonResult<AuthLoginRespVO> socialQuickLogin(@RequestBody @Valid AuthSocialLoginReqVO reqVO) { |
| 161 | return success(authService.socialLogin(reqVO)); | 154 | return success(authService.socialLogin(reqVO)); |
| 162 | } | 155 | } |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/captcha/CaptchaController.java
| @@ -2,7 +2,6 @@ package cn.iocoder.yudao.module.system.controller.admin.captcha; | @@ -2,7 +2,6 @@ package cn.iocoder.yudao.module.system.controller.admin.captcha; | ||
| 2 | 2 | ||
| 3 | import cn.hutool.core.util.StrUtil; | 3 | import cn.hutool.core.util.StrUtil; |
| 4 | import cn.iocoder.yudao.framework.common.util.servlet.ServletUtils; | 4 | import cn.iocoder.yudao.framework.common.util.servlet.ServletUtils; |
| 5 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 6 | import com.xingyuv.captcha.model.common.ResponseModel; | 5 | import com.xingyuv.captcha.model.common.ResponseModel; |
| 7 | import com.xingyuv.captcha.model.vo.CaptchaVO; | 6 | import com.xingyuv.captcha.model.vo.CaptchaVO; |
| 8 | import com.xingyuv.captcha.service.CaptchaService; | 7 | import com.xingyuv.captcha.service.CaptchaService; |
| @@ -28,7 +27,6 @@ public class CaptchaController { | @@ -28,7 +27,6 @@ public class CaptchaController { | ||
| 28 | @PostMapping({"/get"}) | 27 | @PostMapping({"/get"}) |
| 29 | @Operation(summary = "获得验证码") | 28 | @Operation(summary = "获得验证码") |
| 30 | @PermitAll | 29 | @PermitAll |
| 31 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 32 | public ResponseModel get(@RequestBody CaptchaVO data, HttpServletRequest request) { | 30 | public ResponseModel get(@RequestBody CaptchaVO data, HttpServletRequest request) { |
| 33 | assert request.getRemoteHost() != null; | 31 | assert request.getRemoteHost() != null; |
| 34 | data.setBrowserInfo(getRemoteId(request)); | 32 | data.setBrowserInfo(getRemoteId(request)); |
| @@ -38,7 +36,6 @@ public class CaptchaController { | @@ -38,7 +36,6 @@ public class CaptchaController { | ||
| 38 | @PostMapping("/check") | 36 | @PostMapping("/check") |
| 39 | @Operation(summary = "校验验证码") | 37 | @Operation(summary = "校验验证码") |
| 40 | @PermitAll | 38 | @PermitAll |
| 41 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 42 | public ResponseModel check(@RequestBody CaptchaVO data, HttpServletRequest request) { | 39 | public ResponseModel check(@RequestBody CaptchaVO data, HttpServletRequest request) { |
| 43 | data.setBrowserInfo(getRemoteId(request)); | 40 | data.setBrowserInfo(getRemoteId(request)); |
| 44 | return captchaService.check(data); | 41 | return captchaService.check(data); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/dept/PostController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.dept; | 1 | package cn.iocoder.yudao.module.system.controller.admin.dept; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.system.controller.admin.dept.vo.post.PostPageReqVO; | 10 | import cn.iocoder.yudao.module.system.controller.admin.dept.vo.post.PostPageReqVO; |
| 11 | -import cn.iocoder.yudao.module.system.controller.admin.dept.vo.post.PostSaveReqVO; | ||
| 12 | import cn.iocoder.yudao.module.system.controller.admin.dept.vo.post.PostRespVO; | 11 | import cn.iocoder.yudao.module.system.controller.admin.dept.vo.post.PostRespVO; |
| 12 | +import cn.iocoder.yudao.module.system.controller.admin.dept.vo.post.PostSaveReqVO; | ||
| 13 | import cn.iocoder.yudao.module.system.controller.admin.dept.vo.post.PostSimpleRespVO; | 13 | import cn.iocoder.yudao.module.system.controller.admin.dept.vo.post.PostSimpleRespVO; |
| 14 | import cn.iocoder.yudao.module.system.dal.dataobject.dept.PostDO; | 14 | import cn.iocoder.yudao.module.system.dal.dataobject.dept.PostDO; |
| 15 | import cn.iocoder.yudao.module.system.service.dept.PostService; | 15 | import cn.iocoder.yudao.module.system.service.dept.PostService; |
| 16 | import io.swagger.v3.oas.annotations.Operation; | 16 | import io.swagger.v3.oas.annotations.Operation; |
| 17 | import io.swagger.v3.oas.annotations.Parameter; | 17 | import io.swagger.v3.oas.annotations.Parameter; |
| 18 | import io.swagger.v3.oas.annotations.tags.Tag; | 18 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 19 | +import jakarta.annotation.Resource; | ||
| 20 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 21 | +import jakarta.validation.Valid; | ||
| 19 | import org.springframework.security.access.prepost.PreAuthorize; | 22 | import org.springframework.security.access.prepost.PreAuthorize; |
| 20 | import org.springframework.validation.annotation.Validated; | 23 | import org.springframework.validation.annotation.Validated; |
| 21 | import org.springframework.web.bind.annotation.*; | 24 | import org.springframework.web.bind.annotation.*; |
| 22 | 25 | ||
| 23 | -import jakarta.annotation.Resource; | ||
| 24 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 25 | -import jakarta.validation.Valid; | ||
| 26 | import java.io.IOException; | 26 | import java.io.IOException; |
| 27 | import java.util.Collections; | 27 | import java.util.Collections; |
| 28 | import java.util.Comparator; | 28 | import java.util.Comparator; |
| 29 | import java.util.List; | 29 | import java.util.List; |
| 30 | 30 | ||
| 31 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 32 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 32 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 33 | 33 | ||
| 34 | @Tag(name = "管理后台 - 岗位") | 34 | @Tag(name = "管理后台 - 岗位") |
| 35 | @RestController | 35 | @RestController |
| @@ -94,7 +94,7 @@ public class PostController { | @@ -94,7 +94,7 @@ public class PostController { | ||
| 94 | @GetMapping("/export") | 94 | @GetMapping("/export") |
| 95 | @Operation(summary = "岗位管理") | 95 | @Operation(summary = "岗位管理") |
| 96 | @PreAuthorize("@ss.hasPermission('system:post:export')") | 96 | @PreAuthorize("@ss.hasPermission('system:post:export')") |
| 97 | - @OperateLog(type = EXPORT) | 97 | + @ApiAccessLog(operateType = EXPORT) |
| 98 | public void export(HttpServletResponse response, @Validated PostPageReqVO reqVO) throws IOException { | 98 | public void export(HttpServletResponse response, @Validated PostPageReqVO reqVO) throws IOException { |
| 99 | reqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 99 | reqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
| 100 | List<PostDO> list = postService.getPostPage(reqVO).getList(); | 100 | List<PostDO> list = postService.getPostPage(reqVO).getList(); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/dict/DictDataController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.dict; | 1 | package cn.iocoder.yudao.module.system.controller.admin.dict; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.data.DictDataPageReqVO; | 10 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.data.DictDataPageReqVO; |
| 11 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.data.DictDataRespVO; | 11 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.data.DictDataRespVO; |
| 12 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.data.DictDataSaveReqVO; | 12 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.data.DictDataSaveReqVO; |
| @@ -16,18 +16,18 @@ import cn.iocoder.yudao.module.system.service.dict.DictDataService; | @@ -16,18 +16,18 @@ import cn.iocoder.yudao.module.system.service.dict.DictDataService; | ||
| 16 | import io.swagger.v3.oas.annotations.Operation; | 16 | import io.swagger.v3.oas.annotations.Operation; |
| 17 | import io.swagger.v3.oas.annotations.Parameter; | 17 | import io.swagger.v3.oas.annotations.Parameter; |
| 18 | import io.swagger.v3.oas.annotations.tags.Tag; | 18 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 19 | +import jakarta.annotation.Resource; | ||
| 20 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 21 | +import jakarta.validation.Valid; | ||
| 19 | import org.springframework.security.access.prepost.PreAuthorize; | 22 | import org.springframework.security.access.prepost.PreAuthorize; |
| 20 | import org.springframework.validation.annotation.Validated; | 23 | import org.springframework.validation.annotation.Validated; |
| 21 | import org.springframework.web.bind.annotation.*; | 24 | import org.springframework.web.bind.annotation.*; |
| 22 | 25 | ||
| 23 | -import jakarta.annotation.Resource; | ||
| 24 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 25 | -import jakarta.validation.Valid; | ||
| 26 | import java.io.IOException; | 26 | import java.io.IOException; |
| 27 | import java.util.List; | 27 | import java.util.List; |
| 28 | 28 | ||
| 29 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 30 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 30 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 31 | 31 | ||
| 32 | @Tag(name = "管理后台 - 字典数据") | 32 | @Tag(name = "管理后台 - 字典数据") |
| 33 | @RestController | 33 | @RestController |
| @@ -92,7 +92,7 @@ public class DictDataController { | @@ -92,7 +92,7 @@ public class DictDataController { | ||
| 92 | @GetMapping("/export") | 92 | @GetMapping("/export") |
| 93 | @Operation(summary = "导出字典数据") | 93 | @Operation(summary = "导出字典数据") |
| 94 | @PreAuthorize("@ss.hasPermission('system:dict:export')") | 94 | @PreAuthorize("@ss.hasPermission('system:dict:export')") |
| 95 | - @OperateLog(type = EXPORT) | 95 | + @ApiAccessLog(operateType = EXPORT) |
| 96 | public void export(HttpServletResponse response, @Valid DictDataPageReqVO exportReqVO) throws IOException { | 96 | public void export(HttpServletResponse response, @Valid DictDataPageReqVO exportReqVO) throws IOException { |
| 97 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 97 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
| 98 | List<DictDataDO> list = dictDataService.getDictDataPage(exportReqVO).getList(); | 98 | List<DictDataDO> list = dictDataService.getDictDataPage(exportReqVO).getList(); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/dict/DictTypeController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.dict; | 1 | package cn.iocoder.yudao.module.system.controller.admin.dict; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.type.DictTypePageReqVO; | 9 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.type.DictTypePageReqVO; |
| 10 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.type.DictTypeRespVO; | 10 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.type.DictTypeRespVO; |
| 11 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.type.DictTypeSaveReqVO; | 11 | import cn.iocoder.yudao.module.system.controller.admin.dict.vo.type.DictTypeSaveReqVO; |
| @@ -15,18 +15,18 @@ import cn.iocoder.yudao.module.system.service.dict.DictTypeService; | @@ -15,18 +15,18 @@ import cn.iocoder.yudao.module.system.service.dict.DictTypeService; | ||
| 15 | import io.swagger.v3.oas.annotations.Operation; | 15 | import io.swagger.v3.oas.annotations.Operation; |
| 16 | import io.swagger.v3.oas.annotations.Parameter; | 16 | import io.swagger.v3.oas.annotations.Parameter; |
| 17 | import io.swagger.v3.oas.annotations.tags.Tag; | 17 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 18 | +import jakarta.annotation.Resource; | ||
| 19 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 20 | +import jakarta.validation.Valid; | ||
| 18 | import org.springframework.security.access.prepost.PreAuthorize; | 21 | import org.springframework.security.access.prepost.PreAuthorize; |
| 19 | import org.springframework.validation.annotation.Validated; | 22 | import org.springframework.validation.annotation.Validated; |
| 20 | import org.springframework.web.bind.annotation.*; | 23 | import org.springframework.web.bind.annotation.*; |
| 21 | 24 | ||
| 22 | -import jakarta.annotation.Resource; | ||
| 23 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 24 | -import jakarta.validation.Valid; | ||
| 25 | import java.io.IOException; | 25 | import java.io.IOException; |
| 26 | import java.util.List; | 26 | import java.util.List; |
| 27 | 27 | ||
| 28 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 30 | 30 | ||
| 31 | @Tag(name = "管理后台 - 字典类型") | 31 | @Tag(name = "管理后台 - 字典类型") |
| 32 | @RestController | 32 | @RestController |
| @@ -90,7 +90,7 @@ public class DictTypeController { | @@ -90,7 +90,7 @@ public class DictTypeController { | ||
| 90 | @Operation(summary = "导出数据类型") | 90 | @Operation(summary = "导出数据类型") |
| 91 | @GetMapping("/export") | 91 | @GetMapping("/export") |
| 92 | @PreAuthorize("@ss.hasPermission('system:dict:query')") | 92 | @PreAuthorize("@ss.hasPermission('system:dict:query')") |
| 93 | - @OperateLog(type = EXPORT) | 93 | + @ApiAccessLog(operateType = EXPORT) |
| 94 | public void export(HttpServletResponse response, @Valid DictTypePageReqVO exportReqVO) throws IOException { | 94 | public void export(HttpServletResponse response, @Valid DictTypePageReqVO exportReqVO) throws IOException { |
| 95 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 95 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
| 96 | List<DictTypeDO> list = dictTypeService.getDictTypePage(exportReqVO).getList(); | 96 | List<DictTypeDO> list = dictTypeService.getDictTypePage(exportReqVO).getList(); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/errorcode/ErrorCodeController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.errorcode; | 1 | package cn.iocoder.yudao.module.system.controller.admin.errorcode; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | -import cn.iocoder.yudao.module.system.controller.admin.errorcode.vo.*; | 9 | +import cn.iocoder.yudao.module.system.controller.admin.errorcode.vo.ErrorCodePageReqVO; |
| 10 | +import cn.iocoder.yudao.module.system.controller.admin.errorcode.vo.ErrorCodeRespVO; | ||
| 11 | +import cn.iocoder.yudao.module.system.controller.admin.errorcode.vo.ErrorCodeSaveReqVO; | ||
| 10 | import cn.iocoder.yudao.module.system.dal.dataobject.errorcode.ErrorCodeDO; | 12 | import cn.iocoder.yudao.module.system.dal.dataobject.errorcode.ErrorCodeDO; |
| 11 | import cn.iocoder.yudao.module.system.service.errorcode.ErrorCodeService; | 13 | import cn.iocoder.yudao.module.system.service.errorcode.ErrorCodeService; |
| 12 | -import io.swagger.v3.oas.annotations.tags.Tag; | ||
| 13 | -import io.swagger.v3.oas.annotations.Parameter; | ||
| 14 | import io.swagger.v3.oas.annotations.Operation; | 14 | import io.swagger.v3.oas.annotations.Operation; |
| 15 | +import io.swagger.v3.oas.annotations.Parameter; | ||
| 16 | +import io.swagger.v3.oas.annotations.tags.Tag; | ||
| 17 | +import jakarta.annotation.Resource; | ||
| 18 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 19 | +import jakarta.validation.Valid; | ||
| 15 | import org.springframework.security.access.prepost.PreAuthorize; | 20 | import org.springframework.security.access.prepost.PreAuthorize; |
| 16 | import org.springframework.validation.annotation.Validated; | 21 | import org.springframework.validation.annotation.Validated; |
| 17 | import org.springframework.web.bind.annotation.*; | 22 | import org.springframework.web.bind.annotation.*; |
| 18 | 23 | ||
| 19 | -import jakarta.annotation.Resource; | ||
| 20 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 21 | -import jakarta.validation.Valid; | ||
| 22 | import java.io.IOException; | 24 | import java.io.IOException; |
| 23 | import java.util.List; | 25 | import java.util.List; |
| 24 | 26 | ||
| 27 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 25 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 26 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | 29 | ||
| 28 | @Tag(name = "管理后台 - 错误码") | 30 | @Tag(name = "管理后台 - 错误码") |
| 29 | @RestController | 31 | @RestController |
| @@ -78,7 +80,7 @@ public class ErrorCodeController { | @@ -78,7 +80,7 @@ public class ErrorCodeController { | ||
| 78 | @GetMapping("/export-excel") | 80 | @GetMapping("/export-excel") |
| 79 | @Operation(summary = "导出错误码 Excel") | 81 | @Operation(summary = "导出错误码 Excel") |
| 80 | @PreAuthorize("@ss.hasPermission('system:error-code:export')") | 82 | @PreAuthorize("@ss.hasPermission('system:error-code:export')") |
| 81 | - @OperateLog(type = EXPORT) | 83 | + @ApiAccessLog(operateType = EXPORT) |
| 82 | public void exportErrorCodeExcel(@Valid ErrorCodePageReqVO exportReqVO, | 84 | public void exportErrorCodeExcel(@Valid ErrorCodePageReqVO exportReqVO, |
| 83 | HttpServletResponse response) throws IOException { | 85 | HttpServletResponse response) throws IOException { |
| 84 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 86 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/logger/LoginLogController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.logger; | 1 | package cn.iocoder.yudao.module.system.controller.admin.logger; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.system.controller.admin.logger.vo.loginlog.LoginLogPageReqVO; | 9 | import cn.iocoder.yudao.module.system.controller.admin.logger.vo.loginlog.LoginLogPageReqVO; |
| 10 | import cn.iocoder.yudao.module.system.controller.admin.logger.vo.loginlog.LoginLogRespVO; | 10 | import cn.iocoder.yudao.module.system.controller.admin.logger.vo.loginlog.LoginLogRespVO; |
| 11 | import cn.iocoder.yudao.module.system.dal.dataobject.logger.LoginLogDO; | 11 | import cn.iocoder.yudao.module.system.dal.dataobject.logger.LoginLogDO; |
| 12 | import cn.iocoder.yudao.module.system.service.logger.LoginLogService; | 12 | import cn.iocoder.yudao.module.system.service.logger.LoginLogService; |
| 13 | import io.swagger.v3.oas.annotations.Operation; | 13 | import io.swagger.v3.oas.annotations.Operation; |
| 14 | import io.swagger.v3.oas.annotations.tags.Tag; | 14 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 15 | +import jakarta.annotation.Resource; | ||
| 16 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 17 | +import jakarta.validation.Valid; | ||
| 15 | import org.springframework.security.access.prepost.PreAuthorize; | 18 | import org.springframework.security.access.prepost.PreAuthorize; |
| 16 | import org.springframework.validation.annotation.Validated; | 19 | import org.springframework.validation.annotation.Validated; |
| 17 | import org.springframework.web.bind.annotation.GetMapping; | 20 | import org.springframework.web.bind.annotation.GetMapping; |
| 18 | import org.springframework.web.bind.annotation.RequestMapping; | 21 | import org.springframework.web.bind.annotation.RequestMapping; |
| 19 | import org.springframework.web.bind.annotation.RestController; | 22 | import org.springframework.web.bind.annotation.RestController; |
| 20 | 23 | ||
| 21 | -import jakarta.annotation.Resource; | ||
| 22 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 23 | -import jakarta.validation.Valid; | ||
| 24 | import java.io.IOException; | 24 | import java.io.IOException; |
| 25 | import java.util.List; | 25 | import java.util.List; |
| 26 | 26 | ||
| 27 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 28 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | 29 | ||
| 30 | @Tag(name = "管理后台 - 登录日志") | 30 | @Tag(name = "管理后台 - 登录日志") |
| 31 | @RestController | 31 | @RestController |
| @@ -47,7 +47,7 @@ public class LoginLogController { | @@ -47,7 +47,7 @@ public class LoginLogController { | ||
| 47 | @GetMapping("/export") | 47 | @GetMapping("/export") |
| 48 | @Operation(summary = "导出登录日志 Excel") | 48 | @Operation(summary = "导出登录日志 Excel") |
| 49 | @PreAuthorize("@ss.hasPermission('system:login-log:export')") | 49 | @PreAuthorize("@ss.hasPermission('system:login-log:export')") |
| 50 | - @OperateLog(type = EXPORT) | 50 | + @ApiAccessLog(operateType = EXPORT) |
| 51 | public void exportLoginLog(HttpServletResponse response, @Valid LoginLogPageReqVO exportReqVO) throws IOException { | 51 | public void exportLoginLog(HttpServletResponse response, @Valid LoginLogPageReqVO exportReqVO) throws IOException { |
| 52 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 52 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
| 53 | List<LoginLogDO> list = loginLogService.getLoginLogPage(exportReqVO).getList(); | 53 | List<LoginLogDO> list = loginLogService.getLoginLogPage(exportReqVO).getList(); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/logger/OperateLogController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.logger; | 1 | package cn.iocoder.yudao.module.system.controller.admin.logger; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.framework.translate.core.TranslateUtils; | 9 | import cn.iocoder.yudao.framework.translate.core.TranslateUtils; |
| 10 | import cn.iocoder.yudao.module.system.controller.admin.logger.vo.operatelog.OperateLogPageReqVO; | 10 | import cn.iocoder.yudao.module.system.controller.admin.logger.vo.operatelog.OperateLogPageReqVO; |
| 11 | import cn.iocoder.yudao.module.system.controller.admin.logger.vo.operatelog.OperateLogRespVO; | 11 | import cn.iocoder.yudao.module.system.controller.admin.logger.vo.operatelog.OperateLogRespVO; |
| @@ -25,8 +25,8 @@ import org.springframework.web.bind.annotation.RestController; | @@ -25,8 +25,8 @@ import org.springframework.web.bind.annotation.RestController; | ||
| 25 | import java.io.IOException; | 25 | import java.io.IOException; |
| 26 | import java.util.List; | 26 | import java.util.List; |
| 27 | 27 | ||
| 28 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 30 | 30 | ||
| 31 | @Tag(name = "管理后台 - 操作日志") | 31 | @Tag(name = "管理后台 - 操作日志") |
| 32 | @RestController | 32 | @RestController |
| @@ -48,7 +48,7 @@ public class OperateLogController { | @@ -48,7 +48,7 @@ public class OperateLogController { | ||
| 48 | @Operation(summary = "导出操作日志") | 48 | @Operation(summary = "导出操作日志") |
| 49 | @GetMapping("/export") | 49 | @GetMapping("/export") |
| 50 | @PreAuthorize("@ss.hasPermission('system:operate-log:export')") | 50 | @PreAuthorize("@ss.hasPermission('system:operate-log:export')") |
| 51 | - @OperateLog(type = EXPORT) | 51 | + @ApiAccessLog(operateType = EXPORT) |
| 52 | public void exportOperateLog(HttpServletResponse response, @Valid OperateLogPageReqVO exportReqVO) throws IOException { | 52 | public void exportOperateLog(HttpServletResponse response, @Valid OperateLogPageReqVO exportReqVO) throws IOException { |
| 53 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 53 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
| 54 | List<OperateLogDO> list = operateLogService.getOperateLogPage(exportReqVO).getList(); | 54 | List<OperateLogDO> list = operateLogService.getOperateLogPage(exportReqVO).getList(); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/oauth2/OAuth2OpenController.java
| @@ -8,7 +8,6 @@ import cn.iocoder.yudao.framework.common.enums.UserTypeEnum; | @@ -8,7 +8,6 @@ import cn.iocoder.yudao.framework.common.enums.UserTypeEnum; | ||
| 8 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 8 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 9 | import cn.iocoder.yudao.framework.common.util.http.HttpUtils; | 9 | import cn.iocoder.yudao.framework.common.util.http.HttpUtils; |
| 10 | import cn.iocoder.yudao.framework.common.util.json.JsonUtils; | 10 | import cn.iocoder.yudao.framework.common.util.json.JsonUtils; |
| 11 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 12 | import cn.iocoder.yudao.module.system.controller.admin.oauth2.vo.open.OAuth2OpenAccessTokenRespVO; | 11 | import cn.iocoder.yudao.module.system.controller.admin.oauth2.vo.open.OAuth2OpenAccessTokenRespVO; |
| 13 | import cn.iocoder.yudao.module.system.controller.admin.oauth2.vo.open.OAuth2OpenAuthorizeInfoRespVO; | 12 | import cn.iocoder.yudao.module.system.controller.admin.oauth2.vo.open.OAuth2OpenAuthorizeInfoRespVO; |
| 14 | import cn.iocoder.yudao.module.system.controller.admin.oauth2.vo.open.OAuth2OpenCheckTokenRespVO; | 13 | import cn.iocoder.yudao.module.system.controller.admin.oauth2.vo.open.OAuth2OpenCheckTokenRespVO; |
| @@ -95,7 +94,6 @@ public class OAuth2OpenController { | @@ -95,7 +94,6 @@ public class OAuth2OpenController { | ||
| 95 | @Parameter(name = "scope", example = "user_info"), | 94 | @Parameter(name = "scope", example = "user_info"), |
| 96 | @Parameter(name = "refresh_token", example = "123424233"), | 95 | @Parameter(name = "refresh_token", example = "123424233"), |
| 97 | }) | 96 | }) |
| 98 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 99 | public CommonResult<OAuth2OpenAccessTokenRespVO> postAccessToken(HttpServletRequest request, | 97 | public CommonResult<OAuth2OpenAccessTokenRespVO> postAccessToken(HttpServletRequest request, |
| 100 | @RequestParam("grant_type") String grantType, | 98 | @RequestParam("grant_type") String grantType, |
| 101 | @RequestParam(value = "code", required = false) String code, // 授权码模式 | 99 | @RequestParam(value = "code", required = false) String code, // 授权码模式 |
| @@ -146,7 +144,6 @@ public class OAuth2OpenController { | @@ -146,7 +144,6 @@ public class OAuth2OpenController { | ||
| 146 | @PermitAll | 144 | @PermitAll |
| 147 | @Operation(summary = "删除访问令牌") | 145 | @Operation(summary = "删除访问令牌") |
| 148 | @Parameter(name = "token", required = true, description = "访问令牌", example = "biu") | 146 | @Parameter(name = "token", required = true, description = "访问令牌", example = "biu") |
| 149 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 150 | public CommonResult<Boolean> revokeToken(HttpServletRequest request, | 147 | public CommonResult<Boolean> revokeToken(HttpServletRequest request, |
| 151 | @RequestParam("token") String token) { | 148 | @RequestParam("token") String token) { |
| 152 | // 校验客户端 | 149 | // 校验客户端 |
| @@ -165,7 +162,6 @@ public class OAuth2OpenController { | @@ -165,7 +162,6 @@ public class OAuth2OpenController { | ||
| 165 | @PermitAll | 162 | @PermitAll |
| 166 | @Operation(summary = "校验访问令牌") | 163 | @Operation(summary = "校验访问令牌") |
| 167 | @Parameter(name = "token", required = true, description = "访问令牌", example = "biu") | 164 | @Parameter(name = "token", required = true, description = "访问令牌", example = "biu") |
| 168 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 169 | public CommonResult<OAuth2OpenCheckTokenRespVO> checkToken(HttpServletRequest request, | 165 | public CommonResult<OAuth2OpenCheckTokenRespVO> checkToken(HttpServletRequest request, |
| 170 | @RequestParam("token") String token) { | 166 | @RequestParam("token") String token) { |
| 171 | // 校验客户端 | 167 | // 校验客户端 |
| @@ -216,7 +212,6 @@ public class OAuth2OpenController { | @@ -216,7 +212,6 @@ public class OAuth2OpenController { | ||
| 216 | @Parameter(name = "auto_approve", required = true, description = "用户是否接受", example = "true"), | 212 | @Parameter(name = "auto_approve", required = true, description = "用户是否接受", example = "true"), |
| 217 | @Parameter(name = "state", example = "1") | 213 | @Parameter(name = "state", example = "1") |
| 218 | }) | 214 | }) |
| 219 | - @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 | ||
| 220 | public CommonResult<String> approveOrDeny(@RequestParam("response_type") String responseType, | 215 | public CommonResult<String> approveOrDeny(@RequestParam("response_type") String responseType, |
| 221 | @RequestParam("client_id") String clientId, | 216 | @RequestParam("client_id") String clientId, |
| 222 | @RequestParam(value = "scope", required = false) String scope, | 217 | @RequestParam(value = "scope", required = false) String scope, |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/permission/RoleController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.permission; | 1 | package cn.iocoder.yudao.module.system.controller.admin.permission; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 8 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.system.controller.admin.permission.vo.role.*; | 10 | import cn.iocoder.yudao.module.system.controller.admin.permission.vo.role.*; |
| 11 | import cn.iocoder.yudao.module.system.dal.dataobject.permission.RoleDO; | 11 | import cn.iocoder.yudao.module.system.dal.dataobject.permission.RoleDO; |
| 12 | import cn.iocoder.yudao.module.system.service.permission.RoleService; | 12 | import cn.iocoder.yudao.module.system.service.permission.RoleService; |
| 13 | import io.swagger.v3.oas.annotations.Operation; | 13 | import io.swagger.v3.oas.annotations.Operation; |
| 14 | import io.swagger.v3.oas.annotations.Parameter; | 14 | import io.swagger.v3.oas.annotations.Parameter; |
| 15 | import io.swagger.v3.oas.annotations.tags.Tag; | 15 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 16 | +import jakarta.annotation.Resource; | ||
| 17 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 18 | +import jakarta.validation.Valid; | ||
| 16 | import org.springframework.security.access.prepost.PreAuthorize; | 19 | import org.springframework.security.access.prepost.PreAuthorize; |
| 17 | import org.springframework.validation.annotation.Validated; | 20 | import org.springframework.validation.annotation.Validated; |
| 18 | import org.springframework.web.bind.annotation.*; | 21 | import org.springframework.web.bind.annotation.*; |
| 19 | 22 | ||
| 20 | -import jakarta.annotation.Resource; | ||
| 21 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 22 | -import jakarta.validation.Valid; | ||
| 23 | import java.io.IOException; | 23 | import java.io.IOException; |
| 24 | import java.util.Comparator; | 24 | import java.util.Comparator; |
| 25 | import java.util.List; | 25 | import java.util.List; |
| 26 | 26 | ||
| 27 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 28 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | import static java.util.Collections.singleton; | 29 | import static java.util.Collections.singleton; |
| 30 | 30 | ||
| 31 | @Tag(name = "管理后台 - 角色") | 31 | @Tag(name = "管理后台 - 角色") |
| @@ -95,7 +95,7 @@ public class RoleController { | @@ -95,7 +95,7 @@ public class RoleController { | ||
| 95 | 95 | ||
| 96 | @GetMapping("/export-excel") | 96 | @GetMapping("/export-excel") |
| 97 | @Operation(summary = "导出角色 Excel") | 97 | @Operation(summary = "导出角色 Excel") |
| 98 | - @OperateLog(type = EXPORT) | 98 | + @ApiAccessLog(operateType = EXPORT) |
| 99 | @PreAuthorize("@ss.hasPermission('system:role:export')") | 99 | @PreAuthorize("@ss.hasPermission('system:role:export')") |
| 100 | public void export(HttpServletResponse response, @Validated RolePageReqVO exportReqVO) throws IOException { | 100 | public void export(HttpServletResponse response, @Validated RolePageReqVO exportReqVO) throws IOException { |
| 101 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 101 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/sensitiveword/SensitiveWordController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.sensitiveword; | 1 | package cn.iocoder.yudao.module.system.controller.admin.sensitiveword; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.system.controller.admin.sensitiveword.vo.SensitiveWordPageReqVO; | 9 | import cn.iocoder.yudao.module.system.controller.admin.sensitiveword.vo.SensitiveWordPageReqVO; |
| 10 | import cn.iocoder.yudao.module.system.controller.admin.sensitiveword.vo.SensitiveWordRespVO; | 10 | import cn.iocoder.yudao.module.system.controller.admin.sensitiveword.vo.SensitiveWordRespVO; |
| 11 | import cn.iocoder.yudao.module.system.controller.admin.sensitiveword.vo.SensitiveWordSaveVO; | 11 | import cn.iocoder.yudao.module.system.controller.admin.sensitiveword.vo.SensitiveWordSaveVO; |
| @@ -14,19 +14,19 @@ import cn.iocoder.yudao.module.system.service.sensitiveword.SensitiveWordService | @@ -14,19 +14,19 @@ import cn.iocoder.yudao.module.system.service.sensitiveword.SensitiveWordService | ||
| 14 | import io.swagger.v3.oas.annotations.Operation; | 14 | import io.swagger.v3.oas.annotations.Operation; |
| 15 | import io.swagger.v3.oas.annotations.Parameter; | 15 | import io.swagger.v3.oas.annotations.Parameter; |
| 16 | import io.swagger.v3.oas.annotations.tags.Tag; | 16 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 17 | +import jakarta.annotation.Resource; | ||
| 18 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 19 | +import jakarta.validation.Valid; | ||
| 17 | import org.springframework.security.access.prepost.PreAuthorize; | 20 | import org.springframework.security.access.prepost.PreAuthorize; |
| 18 | import org.springframework.validation.annotation.Validated; | 21 | import org.springframework.validation.annotation.Validated; |
| 19 | import org.springframework.web.bind.annotation.*; | 22 | import org.springframework.web.bind.annotation.*; |
| 20 | 23 | ||
| 21 | -import jakarta.annotation.Resource; | ||
| 22 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 23 | -import jakarta.validation.Valid; | ||
| 24 | import java.io.IOException; | 24 | import java.io.IOException; |
| 25 | import java.util.List; | 25 | import java.util.List; |
| 26 | import java.util.Set; | 26 | import java.util.Set; |
| 27 | 27 | ||
| 28 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 30 | 30 | ||
| 31 | @Tag(name = "管理后台 - 敏感词") | 31 | @Tag(name = "管理后台 - 敏感词") |
| 32 | @RestController | 32 | @RestController |
| @@ -81,7 +81,7 @@ public class SensitiveWordController { | @@ -81,7 +81,7 @@ public class SensitiveWordController { | ||
| 81 | @GetMapping("/export-excel") | 81 | @GetMapping("/export-excel") |
| 82 | @Operation(summary = "导出敏感词 Excel") | 82 | @Operation(summary = "导出敏感词 Excel") |
| 83 | @PreAuthorize("@ss.hasPermission('system:sensitive-word:export')") | 83 | @PreAuthorize("@ss.hasPermission('system:sensitive-word:export')") |
| 84 | - @OperateLog(type = EXPORT) | 84 | + @ApiAccessLog(operateType = EXPORT) |
| 85 | public void exportSensitiveWordExcel(@Valid SensitiveWordPageReqVO exportReqVO, | 85 | public void exportSensitiveWordExcel(@Valid SensitiveWordPageReqVO exportReqVO, |
| 86 | HttpServletResponse response) throws IOException { | 86 | HttpServletResponse response) throws IOException { |
| 87 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 87 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/sms/SmsCallbackController.java
| @@ -2,7 +2,6 @@ package cn.iocoder.yudao.module.system.controller.admin.sms; | @@ -2,7 +2,6 @@ package cn.iocoder.yudao.module.system.controller.admin.sms; | ||
| 2 | 2 | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.util.servlet.ServletUtils; | 4 | import cn.iocoder.yudao.framework.common.util.servlet.ServletUtils; |
| 5 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 6 | import cn.iocoder.yudao.module.system.framework.sms.core.enums.SmsChannelEnum; | 5 | import cn.iocoder.yudao.module.system.framework.sms.core.enums.SmsChannelEnum; |
| 7 | import cn.iocoder.yudao.module.system.service.sms.SmsSendService; | 6 | import cn.iocoder.yudao.module.system.service.sms.SmsSendService; |
| 8 | import io.swagger.v3.oas.annotations.Operation; | 7 | import io.swagger.v3.oas.annotations.Operation; |
| @@ -28,7 +27,6 @@ public class SmsCallbackController { | @@ -28,7 +27,6 @@ public class SmsCallbackController { | ||
| 28 | @PostMapping("/aliyun") | 27 | @PostMapping("/aliyun") |
| 29 | @PermitAll | 28 | @PermitAll |
| 30 | @Operation(summary = "阿里云短信的回调", description = "参见 https://help.aliyun.com/document_detail/120998.html 文档") | 29 | @Operation(summary = "阿里云短信的回调", description = "参见 https://help.aliyun.com/document_detail/120998.html 文档") |
| 31 | - @OperateLog(enable = false) | ||
| 32 | public CommonResult<Boolean> receiveAliyunSmsStatus(HttpServletRequest request) throws Throwable { | 30 | public CommonResult<Boolean> receiveAliyunSmsStatus(HttpServletRequest request) throws Throwable { |
| 33 | String text = ServletUtils.getBody(request); | 31 | String text = ServletUtils.getBody(request); |
| 34 | smsSendService.receiveSmsStatus(SmsChannelEnum.ALIYUN.getCode(), text); | 32 | smsSendService.receiveSmsStatus(SmsChannelEnum.ALIYUN.getCode(), text); |
| @@ -38,7 +36,6 @@ public class SmsCallbackController { | @@ -38,7 +36,6 @@ public class SmsCallbackController { | ||
| 38 | @PostMapping("/tencent") | 36 | @PostMapping("/tencent") |
| 39 | @PermitAll | 37 | @PermitAll |
| 40 | @Operation(summary = "腾讯云短信的回调", description = "参见 https://cloud.tencent.com/document/product/382/52077 文档") | 38 | @Operation(summary = "腾讯云短信的回调", description = "参见 https://cloud.tencent.com/document/product/382/52077 文档") |
| 41 | - @OperateLog(enable = false) | ||
| 42 | public CommonResult<Boolean> receiveTencentSmsStatus(HttpServletRequest request) throws Throwable { | 39 | public CommonResult<Boolean> receiveTencentSmsStatus(HttpServletRequest request) throws Throwable { |
| 43 | String text = ServletUtils.getBody(request); | 40 | String text = ServletUtils.getBody(request); |
| 44 | smsSendService.receiveSmsStatus(SmsChannelEnum.TENCENT.getCode(), text); | 41 | smsSendService.receiveSmsStatus(SmsChannelEnum.TENCENT.getCode(), text); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/sms/SmsLogController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.sms; | 1 | package cn.iocoder.yudao.module.system.controller.admin.sms; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.system.controller.admin.sms.vo.log.SmsLogPageReqVO; | 9 | import cn.iocoder.yudao.module.system.controller.admin.sms.vo.log.SmsLogPageReqVO; |
| 10 | import cn.iocoder.yudao.module.system.controller.admin.sms.vo.log.SmsLogRespVO; | 10 | import cn.iocoder.yudao.module.system.controller.admin.sms.vo.log.SmsLogRespVO; |
| 11 | import cn.iocoder.yudao.module.system.dal.dataobject.sms.SmsLogDO; | 11 | import cn.iocoder.yudao.module.system.dal.dataobject.sms.SmsLogDO; |
| 12 | import cn.iocoder.yudao.module.system.service.sms.SmsLogService; | 12 | import cn.iocoder.yudao.module.system.service.sms.SmsLogService; |
| 13 | import io.swagger.v3.oas.annotations.Operation; | 13 | import io.swagger.v3.oas.annotations.Operation; |
| 14 | import io.swagger.v3.oas.annotations.tags.Tag; | 14 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 15 | +import jakarta.annotation.Resource; | ||
| 16 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 17 | +import jakarta.validation.Valid; | ||
| 15 | import org.springframework.security.access.prepost.PreAuthorize; | 18 | import org.springframework.security.access.prepost.PreAuthorize; |
| 16 | import org.springframework.validation.annotation.Validated; | 19 | import org.springframework.validation.annotation.Validated; |
| 17 | import org.springframework.web.bind.annotation.GetMapping; | 20 | import org.springframework.web.bind.annotation.GetMapping; |
| 18 | import org.springframework.web.bind.annotation.RequestMapping; | 21 | import org.springframework.web.bind.annotation.RequestMapping; |
| 19 | import org.springframework.web.bind.annotation.RestController; | 22 | import org.springframework.web.bind.annotation.RestController; |
| 20 | 23 | ||
| 21 | -import jakarta.annotation.Resource; | ||
| 22 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 23 | -import jakarta.validation.Valid; | ||
| 24 | import java.io.IOException; | 24 | import java.io.IOException; |
| 25 | import java.util.List; | 25 | import java.util.List; |
| 26 | 26 | ||
| 27 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 28 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 29 | 29 | ||
| 30 | @Tag(name = "管理后台 - 短信日志") | 30 | @Tag(name = "管理后台 - 短信日志") |
| 31 | @RestController | 31 | @RestController |
| @@ -47,7 +47,7 @@ public class SmsLogController { | @@ -47,7 +47,7 @@ public class SmsLogController { | ||
| 47 | @GetMapping("/export-excel") | 47 | @GetMapping("/export-excel") |
| 48 | @Operation(summary = "导出短信日志 Excel") | 48 | @Operation(summary = "导出短信日志 Excel") |
| 49 | @PreAuthorize("@ss.hasPermission('system:sms-log:export')") | 49 | @PreAuthorize("@ss.hasPermission('system:sms-log:export')") |
| 50 | - @OperateLog(type = EXPORT) | 50 | + @ApiAccessLog(operateType = EXPORT) |
| 51 | public void exportSmsLogExcel(@Valid SmsLogPageReqVO exportReqVO, | 51 | public void exportSmsLogExcel(@Valid SmsLogPageReqVO exportReqVO, |
| 52 | HttpServletResponse response) throws IOException { | 52 | HttpServletResponse response) throws IOException { |
| 53 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 53 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/sms/SmsTemplateController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.sms; | 1 | package cn.iocoder.yudao.module.system.controller.admin.sms; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 4 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 5 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 5 | import cn.iocoder.yudao.module.system.controller.admin.sms.vo.template.*; | 6 | import cn.iocoder.yudao.module.system.controller.admin.sms.vo.template.*; |
| @@ -9,7 +10,6 @@ import cn.iocoder.yudao.module.system.service.sms.SmsSendService; | @@ -9,7 +10,6 @@ import cn.iocoder.yudao.module.system.service.sms.SmsSendService; | ||
| 9 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 10 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 10 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 11 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 11 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 12 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 12 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 13 | import io.swagger.v3.oas.annotations.tags.Tag; | 13 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 14 | import io.swagger.v3.oas.annotations.Parameter; | 14 | import io.swagger.v3.oas.annotations.Parameter; |
| 15 | import io.swagger.v3.oas.annotations.Operation; | 15 | import io.swagger.v3.oas.annotations.Operation; |
| @@ -22,8 +22,8 @@ import jakarta.validation.Valid; | @@ -22,8 +22,8 @@ import jakarta.validation.Valid; | ||
| 22 | import java.io.IOException; | 22 | import java.io.IOException; |
| 23 | import java.util.List; | 23 | import java.util.List; |
| 24 | 24 | ||
| 25 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 25 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 26 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 26 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 27 | 27 | ||
| 28 | @Tag(name = "管理后台 - 短信模板") | 28 | @Tag(name = "管理后台 - 短信模板") |
| 29 | @RestController | 29 | @RestController |
| @@ -79,7 +79,7 @@ public class SmsTemplateController { | @@ -79,7 +79,7 @@ public class SmsTemplateController { | ||
| 79 | @GetMapping("/export-excel") | 79 | @GetMapping("/export-excel") |
| 80 | @Operation(summary = "导出短信模板 Excel") | 80 | @Operation(summary = "导出短信模板 Excel") |
| 81 | @PreAuthorize("@ss.hasPermission('system:sms-template:export')") | 81 | @PreAuthorize("@ss.hasPermission('system:sms-template:export')") |
| 82 | - @OperateLog(type = EXPORT) | 82 | + @ApiAccessLog(operateType = EXPORT) |
| 83 | public void exportSmsTemplateExcel(@Valid SmsTemplatePageReqVO exportReqVO, | 83 | public void exportSmsTemplateExcel(@Valid SmsTemplatePageReqVO exportReqVO, |
| 84 | HttpServletResponse response) throws IOException { | 84 | HttpServletResponse response) throws IOException { |
| 85 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 85 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/tenant/TenantController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.tenant; | 1 | package cn.iocoder.yudao.module.system.controller.admin.tenant; |
| 2 | 2 | ||
| 3 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 3 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 4 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 5 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 6 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; | 7 | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| 7 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 8 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 9 | import cn.iocoder.yudao.module.system.controller.admin.tenant.vo.tenant.TenantPageReqVO; | 9 | import cn.iocoder.yudao.module.system.controller.admin.tenant.vo.tenant.TenantPageReqVO; |
| 10 | import cn.iocoder.yudao.module.system.controller.admin.tenant.vo.tenant.TenantRespVO; | 10 | import cn.iocoder.yudao.module.system.controller.admin.tenant.vo.tenant.TenantRespVO; |
| 11 | import cn.iocoder.yudao.module.system.controller.admin.tenant.vo.tenant.TenantSaveReqVO; | 11 | import cn.iocoder.yudao.module.system.controller.admin.tenant.vo.tenant.TenantSaveReqVO; |
| @@ -15,18 +15,18 @@ import cn.iocoder.yudao.module.system.service.tenant.TenantService; | @@ -15,18 +15,18 @@ import cn.iocoder.yudao.module.system.service.tenant.TenantService; | ||
| 15 | import io.swagger.v3.oas.annotations.Operation; | 15 | import io.swagger.v3.oas.annotations.Operation; |
| 16 | import io.swagger.v3.oas.annotations.Parameter; | 16 | import io.swagger.v3.oas.annotations.Parameter; |
| 17 | import io.swagger.v3.oas.annotations.tags.Tag; | 17 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 18 | -import org.springframework.security.access.prepost.PreAuthorize; | ||
| 19 | -import org.springframework.web.bind.annotation.*; | ||
| 20 | - | ||
| 21 | import jakarta.annotation.Resource; | 18 | import jakarta.annotation.Resource; |
| 22 | import jakarta.annotation.security.PermitAll; | 19 | import jakarta.annotation.security.PermitAll; |
| 23 | import jakarta.servlet.http.HttpServletResponse; | 20 | import jakarta.servlet.http.HttpServletResponse; |
| 24 | import jakarta.validation.Valid; | 21 | import jakarta.validation.Valid; |
| 22 | +import org.springframework.security.access.prepost.PreAuthorize; | ||
| 23 | +import org.springframework.web.bind.annotation.*; | ||
| 24 | + | ||
| 25 | import java.io.IOException; | 25 | import java.io.IOException; |
| 26 | import java.util.List; | 26 | import java.util.List; |
| 27 | 27 | ||
| 28 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 29 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 30 | 30 | ||
| 31 | @Tag(name = "管理后台 - 租户") | 31 | @Tag(name = "管理后台 - 租户") |
| 32 | @RestController | 32 | @RestController |
| @@ -98,7 +98,7 @@ public class TenantController { | @@ -98,7 +98,7 @@ public class TenantController { | ||
| 98 | @GetMapping("/export-excel") | 98 | @GetMapping("/export-excel") |
| 99 | @Operation(summary = "导出租户 Excel") | 99 | @Operation(summary = "导出租户 Excel") |
| 100 | @PreAuthorize("@ss.hasPermission('system:tenant:export')") | 100 | @PreAuthorize("@ss.hasPermission('system:tenant:export')") |
| 101 | - @OperateLog(type = EXPORT) | 101 | + @ApiAccessLog(operateType = EXPORT) |
| 102 | public void exportTenantExcel(@Valid TenantPageReqVO exportReqVO, | 102 | public void exportTenantExcel(@Valid TenantPageReqVO exportReqVO, |
| 103 | HttpServletResponse response) throws IOException { | 103 | HttpServletResponse response) throws IOException { |
| 104 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 104 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/user/UserController.java
| 1 | package cn.iocoder.yudao.module.system.controller.admin.user; | 1 | package cn.iocoder.yudao.module.system.controller.admin.user; |
| 2 | 2 | ||
| 3 | import cn.hutool.core.collection.CollUtil; | 3 | import cn.hutool.core.collection.CollUtil; |
| 4 | +import cn.iocoder.yudao.framework.apilog.core.annotations.ApiAccessLog; | ||
| 4 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; | 5 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 5 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; | 6 | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| 6 | import cn.iocoder.yudao.framework.common.pojo.PageParam; | 7 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 7 | import cn.iocoder.yudao.framework.common.pojo.PageResult; | 8 | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| 8 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; | 9 | import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; |
| 9 | -import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; | ||
| 10 | import cn.iocoder.yudao.module.system.controller.admin.user.vo.user.*; | 10 | import cn.iocoder.yudao.module.system.controller.admin.user.vo.user.*; |
| 11 | import cn.iocoder.yudao.module.system.convert.user.UserConvert; | 11 | import cn.iocoder.yudao.module.system.convert.user.UserConvert; |
| 12 | import cn.iocoder.yudao.module.system.dal.dataobject.dept.DeptDO; | 12 | import cn.iocoder.yudao.module.system.dal.dataobject.dept.DeptDO; |
| @@ -18,22 +18,22 @@ import io.swagger.v3.oas.annotations.Operation; | @@ -18,22 +18,22 @@ import io.swagger.v3.oas.annotations.Operation; | ||
| 18 | import io.swagger.v3.oas.annotations.Parameter; | 18 | import io.swagger.v3.oas.annotations.Parameter; |
| 19 | import io.swagger.v3.oas.annotations.Parameters; | 19 | import io.swagger.v3.oas.annotations.Parameters; |
| 20 | import io.swagger.v3.oas.annotations.tags.Tag; | 20 | import io.swagger.v3.oas.annotations.tags.Tag; |
| 21 | +import jakarta.annotation.Resource; | ||
| 22 | +import jakarta.servlet.http.HttpServletResponse; | ||
| 23 | +import jakarta.validation.Valid; | ||
| 21 | import org.springframework.security.access.prepost.PreAuthorize; | 24 | import org.springframework.security.access.prepost.PreAuthorize; |
| 22 | import org.springframework.validation.annotation.Validated; | 25 | import org.springframework.validation.annotation.Validated; |
| 23 | import org.springframework.web.bind.annotation.*; | 26 | import org.springframework.web.bind.annotation.*; |
| 24 | import org.springframework.web.multipart.MultipartFile; | 27 | import org.springframework.web.multipart.MultipartFile; |
| 25 | 28 | ||
| 26 | -import jakarta.annotation.Resource; | ||
| 27 | -import jakarta.servlet.http.HttpServletResponse; | ||
| 28 | -import jakarta.validation.Valid; | ||
| 29 | import java.io.IOException; | 29 | import java.io.IOException; |
| 30 | import java.util.Arrays; | 30 | import java.util.Arrays; |
| 31 | import java.util.List; | 31 | import java.util.List; |
| 32 | import java.util.Map; | 32 | import java.util.Map; |
| 33 | 33 | ||
| 34 | +import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; | ||
| 34 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 35 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 35 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 36 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| 36 | -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; | ||
| 37 | 37 | ||
| 38 | @Tag(name = "管理后台 - 用户") | 38 | @Tag(name = "管理后台 - 用户") |
| 39 | @RestController | 39 | @RestController |
| @@ -127,7 +127,7 @@ public class UserController { | @@ -127,7 +127,7 @@ public class UserController { | ||
| 127 | @GetMapping("/export") | 127 | @GetMapping("/export") |
| 128 | @Operation(summary = "导出用户") | 128 | @Operation(summary = "导出用户") |
| 129 | @PreAuthorize("@ss.hasPermission('system:user:export')") | 129 | @PreAuthorize("@ss.hasPermission('system:user:export')") |
| 130 | - @OperateLog(type = EXPORT) | 130 | + @ApiAccessLog(operateType = EXPORT) |
| 131 | public void exportUserList(@Validated UserPageReqVO exportReqVO, | 131 | public void exportUserList(@Validated UserPageReqVO exportReqVO, |
| 132 | HttpServletResponse response) throws IOException { | 132 | HttpServletResponse response) throws IOException { |
| 133 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); | 133 | exportReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |