feat: enable multi-option polls

This commit is contained in:
Tim
2025-08-31 12:13:41 +08:00
parent 3808becc8b
commit 2f339fdbdb
12 changed files with 117 additions and 32 deletions

View File

@@ -6,7 +6,7 @@ import lombok.NoArgsConstructor;
import lombok.Setter;
@Entity
@Table(name = "poll_votes", uniqueConstraints = @UniqueConstraint(columnNames = {"post_id", "user_id"}))
@Table(name = "poll_votes", uniqueConstraints = @UniqueConstraint(columnNames = {"post_id", "user_id", "option_index"}))
@Getter
@Setter
@NoArgsConstructor