Documentation
¶
Index ¶
- type DB
- func (db *DB) Count(tableName string) (int, error)
- func (db *DB) Delete(model *model.Model, id interface{}) error
- func (db *DB) Exec(query string, args ...interface{}) (sql.Result, error)
- func (db *DB) GetByID(model *model.Model, id interface{}) (map[string]interface{}, error)
- func (db *DB) Insert(model *model.Model, data map[string]interface{}) error
- func (db *DB) Query(query string, args ...interface{}) ([]map[string]interface{}, error)
- func (db *DB) Update(model *model.Model, id interface{}, data map[string]interface{}) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DB ¶
DB wraps the sql.DB object and provides custom methods
Click to show internal directories.
Click to hide internal directories.