mirror of
https://gitee.com/xiangheng/x_admin.git
synced 2025-12-24 08:12:55 +08:00
更新角色的事务还没提交,就去redis缓存角色导致角色权限不对
This commit is contained in:
@@ -154,9 +154,12 @@ func (roleSrv systemAuthRoleService) Edit(editReq SystemAuthRoleEditReq) (e erro
|
||||
if te = PermService.BatchSaveByMenuIds(editReq.ID, editReq.MenuIds, tx); te != nil {
|
||||
return te
|
||||
}
|
||||
te = PermService.CacheRoleMenusByRoleId(editReq.ID)
|
||||
return te
|
||||
return nil
|
||||
})
|
||||
e = PermService.CacheRoleMenusByRoleId(editReq.ID)
|
||||
if e != nil {
|
||||
return e
|
||||
}
|
||||
e = response.CheckErr(err, "Edit Transaction err")
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user