feat(backend.domain): lab2 add session and add password to user

This commit is contained in:
Голиков Maximillian Антон
2026-10-01 07:51:07 +03:00
parent 380d0ef710
commit 3d9e944c9a
+12 -4
View File
@@ -7,10 +7,11 @@ type Health struct {
} }
type User struct { type User struct {
ID string ID string
Username string Username string
DisplayName string DisplayName string
CreatedAt time.Time PasswordHash string // в DTO UserResponse его не будет
CreatedAt time.Time
} }
type Chat struct { type Chat struct {
@@ -27,3 +28,10 @@ type Message struct {
Text string Text string
CreatedAt time.Time CreatedAt time.Time
} }
type Session struct {
TokenHash []byte
UserID string
ExpiresAt time.Time
CreatedAt time.Time
}