chore: port lab 2 solution

This commit is contained in:
kk10
2026-10-16 19:50:49 +03:00
parent 0ab3a341aa
commit 6e0829e628
71 changed files with 4305 additions and 6 deletions
+14
View File
@@ -0,0 +1,14 @@
package model
import (
"time"
"github.com/google/uuid"
)
type Chat struct {
ID uuid.UUID
Title string
MemberIDs []uuid.UUID
CreatedAt time.Time
}
+15
View File
@@ -0,0 +1,15 @@
package model
import (
"time"
"github.com/google/uuid"
)
type Message struct {
ID uuid.UUID
ChatID uuid.UUID
SenderID uuid.UUID
Text string
CreatedAt time.Time
}
+9
View File
@@ -0,0 +1,9 @@
package model
import "time"
type Session struct {
Token string
ExpiresAt time.Time
User User
}
+14
View File
@@ -0,0 +1,14 @@
package model
import (
"time"
"github.com/google/uuid"
)
type User struct {
ID uuid.UUID
Username string
DisplayName string
CreatedAt time.Time
}