상태값 enum 변경, spotlessApply 적용
This commit is contained in:
@@ -46,7 +46,8 @@ public class MembersDto {
|
||||
ZonedDateTime createdDttm,
|
||||
ZonedDateTime firstLoginDttm,
|
||||
ZonedDateTime lastLoginDttm,
|
||||
ZonedDateTime statusChgDttm) {
|
||||
ZonedDateTime statusChgDttm,
|
||||
Boolean pwdResetYn) {
|
||||
this.id = id;
|
||||
this.uuid = uuid;
|
||||
this.userRole = userRole;
|
||||
@@ -54,7 +55,7 @@ public class MembersDto {
|
||||
this.name = name;
|
||||
this.employeeNo = employeeNo;
|
||||
this.status = status;
|
||||
this.statusName = getStatusName(status);
|
||||
this.statusName = getStatusName(status, pwdResetYn);
|
||||
this.createdDttm = createdDttm;
|
||||
this.firstLoginDttm = firstLoginDttm;
|
||||
this.lastLoginDttm = lastLoginDttm;
|
||||
@@ -66,8 +67,12 @@ public class MembersDto {
|
||||
return type.getText();
|
||||
}
|
||||
|
||||
private String getStatusName(String status) {
|
||||
private String getStatusName(String status, Boolean pwdResetYn) {
|
||||
StatusType type = Enums.fromId(StatusType.class, status);
|
||||
pwdResetYn = pwdResetYn != null && pwdResetYn;
|
||||
if (type.equals(StatusType.PENDING) && pwdResetYn) {
|
||||
type = StatusType.ACTIVE;
|
||||
}
|
||||
return type.getText();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user