[feat] 开启数据权限
This commit is contained in:
parent
d1de9e8dbc
commit
a486c40a47
@ -149,7 +149,7 @@ func (this Resource) GetAuthDBTable(u contracts.User, params ...any) *db.Builder
|
|||||||
// 数据权限过滤
|
// 数据权限过滤
|
||||||
builder.Before(func(b *db.Builder, t string, data ...map[string]any) {
|
builder.Before(func(b *db.Builder, t string, data ...map[string]any) {
|
||||||
if t == db.TYPE_SELECT || t == db.TYPE_UPDATE || t == db.TYPE_DELETE {
|
if t == db.TYPE_SELECT || t == db.TYPE_UPDATE || t == db.TYPE_DELETE {
|
||||||
// this.WithRolesCondition(b, t, u)
|
this.WithRolesCondition(b, t, u)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user