entities

package
v0.3.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 15, 2025 License: MIT Imports: 1 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Avatar added in v0.3.5

type Avatar struct {
	Id        uint      `gorm:"primaryKey"`
	UserId    uint      `gorm:"uniqueIndex;not null"`
	ImageId   uint      `gorm:"not null"`
	Image     Image     `gorm:"constraint:OnDelete:CASCADE;foreignKey:ImageId"`
	CreatedAt time.Time `gorm:"autoCreateTime"`
}

func (Avatar) MarkerEntity added in v0.3.5

func (user Avatar) MarkerEntity()

func (Avatar) TableName added in v0.3.5

func (Avatar) TableName() string

type Ban added in v0.2.7

type Ban struct {
	Id          uint   `gorm:"primaryKey"`
	UserId      uint   `gorm:"not null"`
	User        User   `gorm:"foreignKey:UserId;constraint:OnDelete:CASCADE"`
	Reason      string `gorm:"type:text"`
	IsPermanent bool   `gorm:"not null;default:false"`
	UnbanDate   *time.Time
	IsActive    bool      `gorm:"not null;default:true"`
	CreatedAt   time.Time `gorm:"default:CURRENT_TIMESTAMP"`
	UpdatedAt   time.Time `gorm:"default:CURRENT_TIMESTAMP"`
}

func (Ban) MarkerEntity added in v0.2.10

func (b Ban) MarkerEntity()

type Entity

type Entity interface {
	MarkerEntity()
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL