update readme

master
谢小军 5 years ago
parent 2211c3ca5d
commit 69a5d93269

@ -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) ### [how to use call style>>>](https://github.com/xxjwxc/gormt/blob/master/data/view/genfunc/genfunc_test.go)
## 7. build ## 7. build

@ -33,7 +33,8 @@ func TestFuncGet(t *testing.T) {
fmt.Println(account) fmt.Println(account)
dbs := db.Where("name = ?", "bbbb") dbs := db.Where("name = ?", "bbbb")
accounts, err := model.AccountMgr(dbs).Gets() // 多个获取 accountMgr.UpdateDB(dbs) // 更新数据库
accounts, err := accountMgr.Gets() // 多个获取
fmt.Println(err) fmt.Println(err)
fmt.Println(accounts) fmt.Println(accounts)
} }

@ -16,11 +16,17 @@
- [Index access](#Index-access) - [Index access](#Index-access)
## _BaseMgr ## _BaseMgr
### OpenRelated : open global related
### CloseRelated : close global related
Basic function. All management types inherit this function. This function provides the underlying common function. Basic function. All management types inherit this function. This function provides the underlying common function.
### SetCtx ### SetCtx
Set context, which is used to set context. The current function is not enabled Set context, which is used to set context. The current function is not enabled
### GetDB ### GetDB
Get gorm.db original link Get gorm.db original link
### UpdateDB
Update gorm.db original link
### GetIsRelated ### GetIsRelated
Get whether to query foreign key Association Get whether to query foreign key Association
### SetIsRelated ### SetIsRelated

@ -16,11 +16,15 @@
- [索引方式获取](#索引方式获取) - [索引方式获取](#索引方式获取)
## _BaseMgr ## _BaseMgr
### OpenRelated : 打开全局预加载
### CloseRelated : 关闭全局预加载
基础函数。所有管理类型都是继承此函数。此函数提供基础公共函数。 基础函数。所有管理类型都是继承此函数。此函数提供基础公共函数。
### SetCtx ### SetCtx
设置 context ,用于设置上下文。目前功能未启用 设置 context ,用于设置上下文。目前功能未启用
### GetDB ### GetDB
获取 gorm.DB 原始链接窜 获取 gorm.DB 原始链接窜
### UpdateDB
更新 gorm.DB 原始链接窜
### GetIsRelated ### GetIsRelated
获取是否查询外键关联 获取是否查询外键关联
### SetIsRelated ### SetIsRelated

Loading…
Cancel
Save