Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Base ¶
type Base struct { ID uint64 `json:"id" gorm:"column:id;" db:"id"` CreatedAt *time.Time `json:"created_at,omitempty" gorm:"column:created_at;" db:"created_at"` UpdatedAt *time.Time `json:"updated_at,omitempty" gorm:"column:updated_at;" db:"updated_at"` DeletedAt *time.Time `json:"deleted_at,omitempty" gorm:"column:deleted_at;" db:"deleted_at"` }
type Category ¶
type Comment ¶
type CreateCategoryParams ¶
type CreateUserParams ¶
type CreateVideoParams ¶
type LoginParams ¶
type LoginResponse ¶
type LoginResponse struct { SessionID uuid.UUID `json:"session_id"` AccessToken string `json:"access_token"` AccessTokenExpiresAt time.Time `json:"access_token_expires_at"` RefreshToken string `json:"refresh_token"` RefreshTokenExpiresAt time.Time `json:"refresh_token_expires_at"` User UserResponse `json:"user"` }
type Session ¶
type Session struct { ID uuid.UUID `json:"id" gorm:"column:id;"` OwnerID uint64 `json:"owner_id" gorm:"column:owner_id;"` RefreshToken string `json:"refresh_token" gorm:"column:refresh_token;"` UserAgent string `json:"user_agent" gorm:"column:user_agent;"` ClientIp string `json:"client_ip" gorm:"column:client_ip;"` IsBlocked bool `json:"is_blocked" gorm:"column:is_blocked;"` ExpiresAt time.Time `json:"expires_at" gorm:"column:expires_at;"` CreatedAt time.Time `json:"created_at" gorm:"column:created_at;"` }
type User ¶
type User struct { Base Username string `json:"username" gorm:"column:username;"` HashedPassword string `json:"-" gorm:"column:hashed_password;"` Salt string `json:"-" gorm:"column:salt;"` FullName string `json:"full_name" gorm:"column:full_name;"` Email string `json:"email" gorm:"column:email;"` PasswordChangedAt time.Time `json:"password_changed_at" gorm:"column:password_changed_at;"` }
type UserResponse ¶
type Video ¶
type Video struct { Base Title string `json:"title" gorm:"column:title;"` Description string `json:"description" gorm:"column:description;"` Status common.VideoStatus `json:"status" gorm:"column:status;default:ACTIVE;"` OldStatus common.VideoStatus `json:"-" gorm:"column:old_status;default:null"` OwnerID uint64 `json:"owner_id" gorm:"column:owner_id;"` }
type VideoCategory ¶
type VideoCategory struct { ID uint64 `json:"id" gorm:"column:id;" db:"id"` VideoID uint64 `json:"video_id" gorm:"column:video_id;"` CategoryID uint64 `json:"category_id" gorm:"column:category_id;"` Category Category `json:"category" gorm:"foreignKey:CategoryID;"` CreatedAt *time.Time `json:"created_at,omitempty" gorm:"column:created_at;" db:"created_at"` }
func (VideoCategory) TableName ¶
func (VideoCategory) TableName() string
type VideoFile ¶
type VideoFile struct { ID uint64 `json:"id" gorm:"column:id;" db:"id"` VideoID uint64 `json:"video_id" gorm:"column:video_id;"` OriginName string `json:"origin_name" gorm:"column:origin_name;"` Name string `json:"name" gorm:"column:name;"` Path string `json:"path" gorm:"column:path;"` Format string `json:"format" gorm:"column:format;"` Provider common.Provider `json:"provider" gorm:"column:provider;default:LOCAL;"` MaxSegment int `json:"max_segment" gorm:"column:max_segment;"` CreatedAt *time.Time `json:"created_at,omitempty" gorm:"column:created_at;" db:"created_at"` DeletedAt *time.Time `json:"deleted_at,omitempty" gorm:"column:deleted_at;" db:"deleted_at"` }
type VideoFilter ¶
Click to show internal directories.
Click to hide internal directories.