diff --git a/src/main/java/org/ntlab/acanthus_server/entities/Account.java b/src/main/java/org/ntlab/acanthus_server/entities/Account.java index 1b17fd1..225f6df 100644 --- a/src/main/java/org/ntlab/acanthus_server/entities/Account.java +++ b/src/main/java/org/ntlab/acanthus_server/entities/Account.java @@ -45,6 +45,8 @@ private String email; @JsonProperty("work") private HashMap workHashMap = new HashMap<>(); + @JsonProperty("follows") + private HashMap followsHashMap = new HashMap<>(); @JsonIgnore private Integer uid; @@ -97,6 +99,11 @@ this.workHashMap.put(aid, work); } + public void addFollowsHashMap(Account account) { + var uid = account.getUid(); + this.followsHashMap.put(uid, account); + } + //----------------------------------------------------------------- // getter public Integer getUid() { @@ -124,6 +131,10 @@ return this.workHashMap; } + public HashMap getFollowsHashMap() { + return this.followsHashMap; + } + //----------------------------------------------------------------- // 招待されている作品を返す @JsonIgnore