mirror of https://gitee.com/stylefeng/roses
【notice】修改拼写错误
parent
4debb92dc5
commit
1619e5d2d7
|
@ -9,7 +9,7 @@ import lombok.Getter;
|
||||||
* @date 2021/1/8 13:26
|
* @date 2021/1/8 13:26
|
||||||
*/
|
*/
|
||||||
@Getter
|
@Getter
|
||||||
public enum MessageProrityLevelEnum {
|
public enum MessagePriorityLevelEnum {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 高
|
* 高
|
||||||
|
@ -30,7 +30,7 @@ public enum MessageProrityLevelEnum {
|
||||||
|
|
||||||
private final String name;
|
private final String name;
|
||||||
|
|
||||||
MessageProrityLevelEnum(String code, String name) {
|
MessagePriorityLevelEnum(String code, String name) {
|
||||||
this.code = code;
|
this.code = code;
|
||||||
this.name = name;
|
this.name = name;
|
||||||
}
|
}
|
||||||
|
@ -39,7 +39,7 @@ public enum MessageProrityLevelEnum {
|
||||||
if (code == null) {
|
if (code == null) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
for (MessageProrityLevelEnum flagEnum : MessageProrityLevelEnum.values()) {
|
for (MessagePriorityLevelEnum flagEnum : MessagePriorityLevelEnum.values()) {
|
||||||
if (flagEnum.getCode().equals(code)) {
|
if (flagEnum.getCode().equals(code)) {
|
||||||
return flagEnum.name;
|
return flagEnum.name;
|
||||||
}
|
}
|
|
@ -1,6 +1,6 @@
|
||||||
package cn.stylefeng.roses.kernel.message.api.pojo;
|
package cn.stylefeng.roses.kernel.message.api.pojo;
|
||||||
|
|
||||||
import cn.stylefeng.roses.kernel.message.api.enums.MessageProrityLevelEnum;
|
import cn.stylefeng.roses.kernel.message.api.enums.MessagePriorityLevelEnum;
|
||||||
import cn.stylefeng.roses.kernel.message.api.enums.MessageReadFlagEnum;
|
import cn.stylefeng.roses.kernel.message.api.enums.MessageReadFlagEnum;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
|
@ -86,7 +86,7 @@ public class MessageResponse implements Serializable {
|
||||||
public String getPriorityLevelValue(){
|
public String getPriorityLevelValue(){
|
||||||
AtomicReference<String> value = new AtomicReference<>("");
|
AtomicReference<String> value = new AtomicReference<>("");
|
||||||
Optional.ofNullable(this.priorityLevel).ifPresent(val ->{
|
Optional.ofNullable(this.priorityLevel).ifPresent(val ->{
|
||||||
value.set(MessageProrityLevelEnum.getName(this.priorityLevel));
|
value.set(MessagePriorityLevelEnum.getName(this.priorityLevel));
|
||||||
});
|
});
|
||||||
return value.get();
|
return value.get();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
package cn.stylefeng.roses.kernel.notice.modular.entity;
|
package cn.stylefeng.roses.kernel.notice.modular.entity;
|
||||||
|
|
||||||
import cn.stylefeng.roses.kernel.db.api.pojo.entity.BaseEntity;
|
import cn.stylefeng.roses.kernel.db.api.pojo.entity.BaseEntity;
|
||||||
|
import cn.stylefeng.roses.kernel.message.api.enums.MessagePriorityLevelEnum;
|
||||||
import com.baomidou.mybatisplus.annotation.FieldFill;
|
import com.baomidou.mybatisplus.annotation.FieldFill;
|
||||||
import com.baomidou.mybatisplus.annotation.TableField;
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
import com.baomidou.mybatisplus.annotation.TableId;
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
@ -9,6 +10,8 @@ import lombok.Data;
|
||||||
import lombok.EqualsAndHashCode;
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
import java.util.Optional;
|
||||||
|
import java.util.concurrent.atomic.AtomicReference;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 通知表
|
* 通知表
|
||||||
|
@ -76,5 +79,12 @@ public class SysNotice extends BaseEntity {
|
||||||
@TableField(value = "del_flag", fill = FieldFill.INSERT)
|
@TableField(value = "del_flag", fill = FieldFill.INSERT)
|
||||||
private String delFlag;
|
private String delFlag;
|
||||||
|
|
||||||
|
public String getPriorityLevelValue(){
|
||||||
|
AtomicReference<String> value = new AtomicReference<>("");
|
||||||
|
Optional.ofNullable(this.priorityLevel).ifPresent(val ->{
|
||||||
|
value.set(MessagePriorityLevelEnum.getName(this.priorityLevel));
|
||||||
|
});
|
||||||
|
return value.get();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue