龚焕茏
2024-08-22 1b299b7a0ff1186efc9c62a52a3822d07b07deab
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package enumeration.general;
 
import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.Getter;
 
/**
 * 运维检测结果
 *
 * @author:xp
 * @date:2024/3/4 15:05
 */
@Getter
public enum YwCheckResult {
 
    SUCCESS("SUCCESS", "成功,完成"),
    FAIL("FAIL", "失败、未完成");
 
 
    @EnumValue // 标明该字段存入数据库
    @JsonValue // 标明在转JSON时使用该字段,即响应时
    private final String code;
 
    private final String desc;
 
    YwCheckResult(String code, String desc) {
        this.code = code;
        this.desc = desc;
    }
 
}