Skip to content

Commit

Permalink
[refactor] Stamp에서 NotNull 제약조건 추가 (#401)
Browse files Browse the repository at this point in the history
  • Loading branch information
kseysh committed Oct 8, 2024
1 parent f62ae95 commit 4d7830c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/main/java/org/sopt/app/domain/entity/soptamp/Stamp.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import io.hypersistence.utils.hibernate.type.array.ListArrayType;
import jakarta.persistence.*;
import jakarta.validation.constraints.NotNull;
import java.util.List;
import lombok.*;
import org.hibernate.annotations.Type;
Expand All @@ -18,16 +19,20 @@ public class Stamp extends BaseEntity {
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;

@NotNull
private String contents;

@Column(columnDefinition = "text[]")
@Type(value= ListArrayType.class)
private List<String> images;

@NotNull
private Long userId;

@NotNull
private Long missionId;

@NotNull
@Column(length = 10)
private String activityDate;

Expand Down

0 comments on commit 4d7830c

Please sign in to comment.