entity

package
v0.0.0-...-0ae98b0 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2024 License: BSD-2-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEntityActor

func GetEntityActor(tx *gorm.DB) string

Types

type BaseModel

type BaseModel struct {
	Id        string         `gorm:"primary_key;column:id;" json:"id"`
	CreatedAt time.Time      `gorm:"column:created_at" json:"createdAt"`
	UpdatedAt time.Time      `gorm:"column:updated_at" json:"updatedAt"`
	DeletedAt gorm.DeletedAt `gorm:"column:deleted_at" json:"-"`
	CreatedBy string         `gorm:"column:created_by" json:"createdBy"`
	UpdatedBy string         `gorm:"column:updated_by" json:"updatedBy"`
	DeletedBy string         `gorm:"column:deleted_by" json:"deletedBy"`
}

func (*BaseModel) BeforeCreate

func (bm *BaseModel) BeforeCreate(tx *gorm.DB) (err error)

func (*BaseModel) BeforeUpdate

func (bm *BaseModel) BeforeUpdate(tx *gorm.DB) (err error)

Jump to

Keyboard shortcuts

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