mirror of
				https://github.com/continew-org/continew-admin.git
				synced 2025-11-04 10:57:10 +08:00 
			
		
		
		
	优化:优化部分校验类型(业务验证迁移到 Service 层,使用 CheckUtils 来验证)
This commit is contained in:
		@@ -33,6 +33,7 @@ import top.charles7c.cnadmin.common.enums.DisEnableStatusEnum;
 | 
			
		||||
 * @since 2023/1/24 19:51
 | 
			
		||||
 */
 | 
			
		||||
@Data
 | 
			
		||||
@Schema(description = "修改状态信息")
 | 
			
		||||
public class UpdateStatusRequest implements Serializable {
 | 
			
		||||
 | 
			
		||||
    private static final long serialVersionUID = 1L;
 | 
			
		||||
@@ -40,7 +41,7 @@ public class UpdateStatusRequest implements Serializable {
 | 
			
		||||
    /**
 | 
			
		||||
     * 状态(1启用 2禁用)
 | 
			
		||||
     */
 | 
			
		||||
    @Schema(description = "状态(1启用 2禁用)")
 | 
			
		||||
    @Schema(description = "状态(1启用 2禁用)", type = "Integer", allowableValues = {"1", "2"})
 | 
			
		||||
    @NotNull(message = "状态非法")
 | 
			
		||||
    private DisEnableStatusEnum status;
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
@@ -23,7 +23,7 @@ import lombok.extern.slf4j.Slf4j;
 | 
			
		||||
import top.charles7c.cnadmin.common.exception.ServiceException;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 业务检查工具类(抛出 500 ServiceException)
 | 
			
		||||
 * 业务参数校验工具类(抛出 500 ServiceException)
 | 
			
		||||
 *
 | 
			
		||||
 * @author Charles7c
 | 
			
		||||
 * @see ServiceException
 | 
			
		||||
 
 | 
			
		||||
@@ -23,7 +23,7 @@ import lombok.extern.slf4j.Slf4j;
 | 
			
		||||
import top.charles7c.cnadmin.common.exception.BadRequestException;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 校验工具类(抛出 400 BadRequestException)
 | 
			
		||||
 * 基本参数校验工具类(抛出 400 BadRequestException)
 | 
			
		||||
 *
 | 
			
		||||
 * @author Charles7c
 | 
			
		||||
 * @since 2022/12/21 20:56
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user