model

package
v1.6.11 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2025 License: MIT, Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DictGetValue

func DictGetValue(db *gorm.DB, typ int, key string) (string, error)

func DictSetValue

func DictSetValue(db *gorm.DB, typ int, key, value string) error

func EndCallback

func EndCallback(db *gorm.DB, typ string)

Types

type Cursor

type Cursor struct {
	model.Cursor
	ModelTime
}

func GetCursor

func GetCursor(db *gorm.DB, typ string) (*Cursor, error)

type Dict

type Dict struct {
	model.Dict
	ModelTime
}

type Enum

type Enum struct {
	model.Enum
	Model
}

type EnumValue

type EnumValue struct {
	model.EnumValue
	Model
}

type Model

type Model struct {
	ID        uint           `json:"id" gorm:"primaryKey"`
	CreatedAt time.Time      `json:"createdAt" gorm:"default:now()"`
	UpdatedAt time.Time      `json:"updatedAt"`
	DeletedAt gorm.DeletedAt `json:"deletedAt,omitzero" gorm:"index"`
}

type ModelTime

type ModelTime struct {
	CreatedAt time.Time      `json:"createdAt" gorm:"default:now()"`
	UpdatedAt time.Time      `json:"updatedAt"`
	DeletedAt gorm.DeletedAt `json:"deletedAt,omitzero" gorm:"index"`
}

Jump to

Keyboard shortcuts

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