🎨 规范代码.

This commit is contained in:
lijiahangmax
2024-12-23 23:23:42 +08:00
parent 79f14632bb
commit 41a9bebe06
6 changed files with 15 additions and 21 deletions

View File

@@ -15,6 +15,7 @@
*/
package org.dromara.visor.framework.common.entity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
/**
@@ -25,16 +26,13 @@ import lombok.Data;
* @since 2024/6/24 15:03
*/
@Data
@Schema(name = "AutoClearConfig", description = "自动清理配置")
public class AutoClearConfig {
/**
* 是否开启
*/
@Schema(description = "是否开启")
private Boolean enabled;
/**
* 保留周期 (天)
*/
@Schema(description = "保留周期 (天)")
private Integer keepPeriod;
}

View File

@@ -31,7 +31,7 @@ import javax.validation.constraints.NotNull;
* @since 2023/7/12 23:14
*/
@Data
@Schema(description = "公共页码请求")
@Schema(name = "PageRequest", description = "公共页码请求")
public class PageRequest {
@NotNull(groups = Page.class)

View File

@@ -15,6 +15,7 @@
*/
package org.dromara.visor.framework.common.entity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
/**
@@ -25,21 +26,16 @@ import lombok.Data;
* @since 2023/12/29 11:57
*/
@Data
@Schema(name = "RequestIdentityModel", description = "请求留痕模型")
public class RequestIdentityModel implements RequestIdentity {
/**
* 请求地址
*/
@Schema(description = "请求地址")
private String address;
/**
* 请求位置
*/
@Schema(description = "请求位置")
private String location;
/**
* userAgent
*/
@Schema(description = "userAgent")
private String userAgent;
}

View File

@@ -56,8 +56,8 @@ public interface ExecLogDAO extends IMapper<ExecLogDO> {
* @param limit limit
* @return rows
*/
List<ExecLogDO> getExecHistory(@Param("source") String source,
@Param("userId") Long userId,
@Param("limit") Integer limit);
List<ExecLogDO> selectExecHistory(@Param("source") String source,
@Param("userId") Long userId,
@Param("limit") Integer limit);
}

View File

@@ -132,7 +132,7 @@ public class ExecLogServiceImpl implements ExecLogService {
@Override
public List<ExecLogVO> getExecHistory(ExecLogQueryRequest request) {
// 查询执行记录
List<ExecLogDO> rows = execLogDAO.getExecHistory(request.getSource(), request.getUserId(), request.getLimit());
List<ExecLogDO> rows = execLogDAO.selectExecHistory(request.getSource(), request.getUserId(), request.getLimit());
if (rows.isEmpty()) {
return Lists.empty();
}

View File

@@ -31,7 +31,7 @@
id, user_id, username, source, source_id, exec_mode, description, exec_seq, command, parameter_schema, timeout, script_exec, status, start_time, finish_time, create_time, update_time, creator, updater, deleted
</sql>
<select id="getExecHistory" resultMap="BaseResultMap">
<select id="selectExecHistory" resultMap="BaseResultMap">
SELECT
<include refid="Base_Column_List"/>
FROM exec_log e