mirror of
http://192.168.1.205:9980/cf_devdept2/cf_imes_server.git
synced 2026-08-12 21:02:08 +08:00
1、新增贴皮管理增删改、上传图片、分页/单个查询接口;2、整理对应参数校验国际化;
This commit is contained in:
+1
-1
@@ -5,7 +5,7 @@ import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.cf.imes.framework.excel.core.annotations.EnumFormat;
|
||||
import com.cf.imes.framework.excel.core.convert.EnumBoolValConvert;
|
||||
import com.cf.imes.framework.excel.core.convert.EnumConvert;
|
||||
import com.cf.imes.module.system.enums.common.WhetherEnum;
|
||||
import com.cf.imes.framework.excel.core.enums.WhetherEnum;
|
||||
import com.cf.imes.module.system.enums.pay.DurationUnitEnum;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
-22
@@ -1,22 +0,0 @@
|
||||
package com.cf.imes.module.system.enums.common;
|
||||
|
||||
import com.cf.imes.framework.excel.core.convert.BaseBoolValEnum;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* 是否枚举
|
||||
*
|
||||
* @author Gqr
|
||||
* @since 2025/9/25 15:54
|
||||
*/
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public enum WhetherEnum implements BaseBoolValEnum {
|
||||
TRUE(true, "whether.yes"),
|
||||
FALSE(false, "whether.no");
|
||||
|
||||
private final Boolean code;
|
||||
|
||||
private final String desc;
|
||||
}
|
||||
+1
-1
File diff suppressed because one or more lines are too long
-34
@@ -1,34 +0,0 @@
|
||||
package com.cf.imes.module.system.enums.common;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
import static org.junit.jupiter.api.Assertions.*;
|
||||
|
||||
/**
|
||||
* {@link WhetherEnum} 的单元测试
|
||||
*/
|
||||
class WhetherEnumTest {
|
||||
|
||||
@Test
|
||||
void testEnumValues() {
|
||||
// 验证枚举值 TRUE
|
||||
assertEquals(true, WhetherEnum.TRUE.getCode());
|
||||
assertEquals("whether.yes", WhetherEnum.TRUE.getDesc());
|
||||
|
||||
// 验证枚举值 FALSE
|
||||
assertEquals(false, WhetherEnum.FALSE.getCode());
|
||||
assertEquals("whether.no", WhetherEnum.FALSE.getDesc());
|
||||
}
|
||||
|
||||
@Test
|
||||
void testEnumSize() {
|
||||
// 验证枚举值的数量
|
||||
assertEquals(2, WhetherEnum.values().length);
|
||||
}
|
||||
|
||||
@Test
|
||||
void testGetCode() {
|
||||
// 测试 getCode 方法
|
||||
assertTrue(WhetherEnum.TRUE.getCode());
|
||||
assertFalse(WhetherEnum.FALSE.getCode());
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user