| |
---|
| | import com.fasterxml.jackson.annotation.JsonIgnore; |
---|
| | import com.fasterxml.jackson.annotation.JsonProperty; |
---|
| | import org.ntlab.acanthus_server.models.Accounts; |
---|
| | import org.ntlab.acanthus_server.models.Gallery; |
---|
| | import org.springframework.validation.beanvalidation.LocalValidatorFactoryBean; |
---|
| | |
---|
| | import java.time.LocalDateTime; |
---|
| | import java.time.format.DateTimeFormatter; |
---|
| | import java.util.ArrayList; |
---|
| | import java.util.Collection; |
---|
| | import java.util.Date; |
---|
| | import java.util.HashMap; |
---|
| |
---|
| | @JsonProperty("description") |
---|
| | private String description; |
---|
| | private Boolean isPublic; |
---|
| | @JsonProperty("createdDate") |
---|
| | private LocalDateTime createdDate; |
---|
| | private String createdDate; |
---|
| | @JsonProperty("lastUpdate") |
---|
| | private String lastUpdate; |
---|
| | @JsonProperty("likes") |
---|
| | private Integer likes; |
---|
| |
---|
| | @JsonIgnore |
---|
| | private boolean isDummy; |
---|
| | |
---|
| | public Animation(Integer aid, String name, Account owner) { |
---|
| | |
---|
| | LocalDateTime date = LocalDateTime.now(); |
---|
| | DateTimeFormatter dateTimeFormatter = DateTimeFormatter.ofPattern("yyyy/MM/dd HH:mm:ss"); |
---|
| | // ↑ "yyyy/MM/dd HH:mm:ss"という形の日付を表示させるための前処理 |
---|
| | |
---|
| | this.aid = aid; |
---|
| | this.name = name; |
---|
| | this.createdDate = LocalDateTime.now(); |
---|
| | this.createdDate = date.format(dateTimeFormatter); |
---|
| | this.isPublic = false; |
---|
| | this.owner = owner; |
---|
| | this.editors.add(new Editor(owner, true)); |
---|
| | this.pageMap.put(0, new Page()); |
---|
| |
---|
| | public Collection<Account> getInvites() { |
---|
| | return invites; |
---|
| | } |
---|
| | |
---|
| | public LocalDateTime getCreatedDate(){return createdDate;} |
---|
| | public String getCreatedDate(){return createdDate;} |
---|
| | |
---|
| | //----------------------------------------------------------------- |
---|
| | // remover |
---|
| | |
---|
| |
---|
| | this.isPublic = false; |
---|
| | this.owner = ownerAccount; |
---|
| | this.editors.add(new Editor(owner, true)); |
---|
| | this.pageMap.put(0, new Page()); |
---|
| | this.createdDate = LocalDateTime.now(); |
---|
| | |
---|
| | LocalDateTime date = LocalDateTime.now(); |
---|
| | DateTimeFormatter dateTimeFormatter = DateTimeFormatter.ofPattern("yyyy/MM/dd HH:mm:ss"); |
---|
| | this.createdDate = date.format(dateTimeFormatter); |
---|
| | |
---|
| | //this.lastAccess = LocalDateTime.of(2015, 12, 15, 0, 0); |
---|
| | |
---|
| | var newWork = new Work(); //ユーザーの制作作品の作成 |
---|
| |
---|
| | |