NCBACK-33 add start logic for verify by token
Test Workflow / test (push) Successful in 4s

This commit is contained in:
vladp
2026-01-16 20:20:14 +07:00
parent 0ed3f958ff
commit 4704f780e5
31 changed files with 333 additions and 34 deletions
@@ -0,0 +1,31 @@
package ru.soune.nocopy.entity.user;
import jakarta.persistence.*;
import lombok.*;
import java.time.LocalDateTime;
@Entity
@Table(name = "email_verification_tokens")
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
public class EmailVerificationToken {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "user_id", nullable = false)
private User user;
@Column(name = "token", nullable = false, length = 6)
private String token;
@Column(name = "expires_at", nullable = false)
private LocalDateTime expiresAt;
@Column(name = "created_at", nullable = false)
private LocalDateTime createdAt;
}