package models
import (
"gorm.io/gorm"
"time"
)
type ServerSetting struct {
gorm.Model
Name string `json:"name"`
Description string `json:"description"`
Value string `json:"value"`
}
type User struct {
Email string `json:"email" gorm:"unique;not null"`
Username string `json:"username" gorm:"unique;not null"`
FirstName string `json:"first_name"`
LastName string `json:"last_name"`
AuthType string `json:"auth_type"`
Password string `json:"password"`
type MediaItem struct {
User User `json:"user" gorm:"ForeignKey:ID"`
EXIFDate time.Time `json:"exif_date"`
Latitude string `json:"latitude"`
Longitude string `json:"longitude"`
MediaType uint `json:"media_type"`
RelPath string `json:"rel_path"`
Tags []Tag `json:"tags" gorm:"many2many:media_tags;"`
Albums []Album `json:"albums" gorm:"many2many:media_albums;"`
type Tag struct {
type Album struct {