- package Models
-
- import (
- "time"
-
- "github.com/gofrs/uuid"
- )
-
- // Set with User being the requestee, and FriendID being the requester
- type Friend struct {
- Base
- UserID uuid.UUID `gorm:"type:uuid;column:user_id;not null;" json:"user_id"`
- User User `json:"user"`
- FriendID string `gorm:"not null" json:"friend_id"` // Stored encrypted
- AcceptedAt time.Time `json:"accepted_at"`
- }
|