update readme
This commit is contained in:
@@ -144,7 +144,7 @@ func (obj *_UserAccountTblMgr) FetchByPrimaryKey(ID int) (result UserAccountTbl,
|
||||
|
||||
```
|
||||
|
||||
### [more多>>>](https://github.com/xxjwxc/gormt/tree/master/doc/func.md)
|
||||
### [more>>>](https://github.com/xxjwxc/gormt/tree/master/doc/func.md)
|
||||
### [how to use call style>>>](https://github.com/xxjwxc/gormt/blob/master/data/view/genfunc/genfunc_test.go)
|
||||
|
||||
## 7. build
|
||||
|
||||
@@ -33,7 +33,8 @@ func TestFuncGet(t *testing.T) {
|
||||
fmt.Println(account)
|
||||
|
||||
dbs := db.Where("name = ?", "bbbb")
|
||||
accounts, err := model.AccountMgr(dbs).Gets() // 多个获取
|
||||
accountMgr.UpdateDB(dbs) // 更新数据库
|
||||
accounts, err := accountMgr.Gets() // 多个获取
|
||||
fmt.Println(err)
|
||||
fmt.Println(accounts)
|
||||
}
|
||||
|
||||
@@ -16,11 +16,17 @@
|
||||
- [Index access](#Index-access)
|
||||
|
||||
## _BaseMgr
|
||||
|
||||
### OpenRelated : open global related
|
||||
### CloseRelated : close global related
|
||||
|
||||
Basic function. All management types inherit this function. This function provides the underlying common function.
|
||||
### SetCtx
|
||||
Set context, which is used to set context. The current function is not enabled
|
||||
### GetDB
|
||||
Get gorm.db original link
|
||||
### UpdateDB
|
||||
Update gorm.db original link
|
||||
### GetIsRelated
|
||||
Get whether to query foreign key Association
|
||||
### SetIsRelated
|
||||
|
||||
@@ -16,11 +16,15 @@
|
||||
- [索引方式获取](#索引方式获取)
|
||||
|
||||
## _BaseMgr
|
||||
### OpenRelated : 打开全局预加载
|
||||
### CloseRelated : 关闭全局预加载
|
||||
基础函数。所有管理类型都是继承此函数。此函数提供基础公共函数。
|
||||
### SetCtx
|
||||
设置 context ,用于设置上下文。目前功能未启用
|
||||
### GetDB
|
||||
获取 gorm.DB 原始链接窜
|
||||
### UpdateDB
|
||||
更新 gorm.DB 原始链接窜
|
||||
### GetIsRelated
|
||||
获取是否查询外键关联
|
||||
### SetIsRelated
|
||||
|
||||
Reference in New Issue
Block a user