package model import "time" type Created struct { CreatedAt time.Time `bun:"type:timestamptz,notnull,default:current_timestamp" json:"createdAt" time_format:"simple_datetime" time_location:"shanghai"` } type CreatedWithUser struct { Created `bun:"extend"` CreatedBy *string `json:"createdBy"` } type Deleted struct { DeletedAt *time.Time `bun:"type:timestamptz,soft_delete,nullzero" json:"deletedAt" time_format:"simple_datetime" time_location:"shanghai"` } type DeletedWithUser struct { Deleted `bun:"extend"` DeletedBy *string `json:"deletedBy"` } type CreatedAndModified struct { Created `bun:"extend"` LastModifiedAt *time.Time `bun:"type:timestamptz,nullzero,default:current_timestamp" json:"lastModifiedAt" time_format:"simple_datetime" time_location:"shanghai"` } type CreatedAndModifiedWithUser struct { CreatedAndModified `bun:"extend"` CreatedBy *string `json:"createdBy"` LastModifiedBy *string `json:"lastModifiedBy"` }