Documentation ¶
Index ¶
- type SQLClient
- func (t *SQLClient) Create(params map[string]any) (id int64, err error)
- func (t *SQLClient) DeleteByID(id int64) (err error)
- func (t *SQLClient) GetByID(id int64, data any) (err error)
- func (t *SQLClient) Init() (err error)
- func (t *SQLClient) UpdateByID(id int64, setFields []string, params map[string]any) (err error)
- func (t *SQLClient) UpdateDefaultFieldsByID(id int64, params map[string]any) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SQLClient ¶
type SQLClient struct { //DB数据库句柄 DB CoreSQL2.Client //表名称 // eg: base_db_manager TableName string //主表缓冲标识码前缀 // eg: xxx:xxx:xxx CacheName string //默认缓冲时效性 // eg: 3600 CacheTime int //结构映射关系 // eg: &FieldsXXX{} FieldsAny any //是否存在更新时间 HaveUpdateTime bool //是否存在软删除 HaveSoftDelete bool }
func (*SQLClient) DeleteByID ¶
DeleteByID 通过ID删除数据
func (*SQLClient) UpdateByID ¶
UpdateByID 通过ID更新数据
Click to show internal directories.
Click to hide internal directories.