optimized code

master
RuoYi 2023-06-29 19:36:24 +08:00
parent 7358a2027d
commit cc74bde7be
5 changed files with 35 additions and 25 deletions

View File

@ -62,11 +62,11 @@ spring:
active: druid active: druid
# 文件上传 # 文件上传
servlet: servlet:
multipart: multipart:
# 单个文件大小 # 单个文件大小
max-file-size: 10MB max-file-size: 10MB
# 设置总上传的文件大小 # 设置总上传的文件大小
max-request-size: 20MB max-request-size: 20MB
# 服务模块 # 服务模块
devtools: devtools:
restart: restart:
@ -75,12 +75,12 @@ spring:
# MyBatis # MyBatis
mybatis: mybatis:
# 搜索指定包别名 # 搜索指定包别名
typeAliasesPackage: com.ruoyi.**.domain typeAliasesPackage: com.ruoyi.**.domain
# 配置mapper的扫描找到所有的mapper.xml映射文件 # 配置mapper的扫描找到所有的mapper.xml映射文件
mapperLocations: classpath*:mapper/**/*Mapper.xml mapperLocations: classpath*:mapper/**/*Mapper.xml
# 加载全局的配置文件 # 加载全局的配置文件
configLocation: classpath:mybatis/mybatis-config.xml configLocation: classpath:mybatis/mybatis-config.xml
# PageHelper分页插件 # PageHelper分页插件
pagehelper: pagehelper:

View File

@ -59,12 +59,12 @@ public @interface Excel
public int roundingMode() default BigDecimal.ROUND_HALF_EVEN; public int roundingMode() default BigDecimal.ROUND_HALF_EVEN;
/** /**
* excel * excel
*/ */
public double height() default 14; public double height() default 14;
/** /**
* excel * excel
*/ */
public double width() default 16; public double width() default 16;
@ -114,7 +114,7 @@ public @interface Excel
public ColumnType cellType() default ColumnType.STRING; public ColumnType cellType() default ColumnType.STRING;
/** /**
* *
*/ */
public IndexedColors headerBackgroundColor() default IndexedColors.GREY_50_PERCENT; public IndexedColors headerBackgroundColor() default IndexedColors.GREY_50_PERCENT;
@ -124,7 +124,7 @@ public @interface Excel
public IndexedColors headerColor() default IndexedColors.WHITE; public IndexedColors headerColor() default IndexedColors.WHITE;
/** /**
* *
*/ */
public IndexedColors backgroundColor() default IndexedColors.WHITE; public IndexedColors backgroundColor() default IndexedColors.WHITE;

View File

@ -188,7 +188,17 @@ public class AjaxResult extends HashMap<String, Object>
*/ */
public boolean isSuccess() public boolean isSuccess()
{ {
return !isError(); return Objects.equals(Type.SUCCESS.value, this.get(CODE_TAG));
}
/**
*
*
* @return
*/
public boolean isWarn()
{
return Objects.equals(Type.WARN.value, this.get(CODE_TAG));
} }
/** /**

View File

@ -66,7 +66,7 @@ public final class UUID implements java.io.Serializable, Comparable<UUID>
} }
/** /**
* 4UUID 使线 UUID * 4UUID
* *
* @return {@code UUID} * @return {@code UUID}
*/ */

View File

@ -52,7 +52,7 @@ public class PermissionService
/** /**
* hiddenBoolean使hasAnyPermissions * hiddenBoolean使hasAnyPermissions
* *
* @param permissions PERMISSION_NAMES_DELIMETER * @param permissions PERMISSION_DELIMETER
* @return * @return
*/ */
public String hasAnyPermi(String permissions) public String hasAnyPermi(String permissions)
@ -129,7 +129,7 @@ public class PermissionService
/** /**
* *
* *
* @param permissions PERMISSION_NAMES_DELIMETER * @param permissions PERMISSION_DELIMETER
* @return * @return
*/ */
public boolean hasAnyPermissions(String permissions) public boolean hasAnyPermissions(String permissions)