[新增]获取用户信息的接口中增加更新时间
All checks were successful
CI / Docker-Build (push) Successful in 2m12s

This commit is contained in:
thesai 2024-09-25 13:27:39 +08:00
parent 436a07bcf4
commit 1e2ed4d305

View File

@ -7,18 +7,17 @@ import club.joylink.rtss.vo.client.org.OrgVO;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;
import org.springframework.util.CollectionUtils;
import org.springframework.util.StringUtils;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import javax.validation.constraints.NotBlank;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;
import org.springframework.util.CollectionUtils;
import org.springframework.util.StringUtils;
/**
* 账户对象
@ -28,6 +27,7 @@ import java.util.List;
@Setter
@EqualsAndHashCode
public class AccountVO implements Serializable {
@JsonSerialize(using = ToStringSerializer.class)
private Long id;
@ -129,6 +129,11 @@ public class AccountVO implements Serializable {
*/
private LocalDateTime createTime;
/**
* 更新时间
*/
private LocalDateTime updateTime;
//单位信息
private Long companyId;
@ -163,6 +168,7 @@ public class AccountVO implements Serializable {
this.email = account.getEmail();
this.status = account.getStatus();
this.createTime = account.getCreateTime();
this.updateTime = account.getUpdateTime();
}
public static AccountVO system() {
@ -219,7 +225,8 @@ public class AccountVO implements Serializable {
@Override
public String toString() {
return "UserVO [id=" + id + ", name=" + name + ", nickname=" + nickname + ", mobile=" + mobile + ", email=" + email + ", nationcode="
return "UserVO [id=" + id + ", name=" + name + ", nickname=" + nickname + ", mobile=" + mobile
+ ", email=" + email + ", nationcode="
+ nationcode + ", wxId=" + wxId + "]";
}
@ -269,7 +276,8 @@ public class AccountVO implements Serializable {
@JsonIgnore
public boolean isAdmin() {
return !CollectionUtils.isEmpty(this.roles)
&& (this.roles.contains(BusinessConsts.ROLE_04) || this.roles.contains(BusinessConsts.ROLE_05));
&& (this.roles.contains(BusinessConsts.ROLE_04) || this.roles.contains(
BusinessConsts.ROLE_05));
}
/**