feat(ui): 增加角色管理,管理员方法新增角色关联

This commit is contained in:
吴汉强
2024-03-13 17:24:30 +08:00
parent c700b32670
commit 6cf91a84ca
8 changed files with 263 additions and 17 deletions

View File

@@ -392,6 +392,7 @@ func main() {
group.POST("remove", h.Remove)
group.POST("resetPass", h.ResetPass)
}),
// 权限
fx.Provide(admin.NewSysPermissionHandler),
fx.Invoke(func(s *core.AppServer, h *admin.SysPermissionHandler) {
group := s.Engine.Group("/api/admin/sysPermission/")
@@ -399,6 +400,14 @@ func main() {
group.POST("save", h.Save)
group.POST("remove", h.Remove)
}),
// 角色
fx.Provide(admin.NewSysRoleHandler),
fx.Invoke(func(s *core.AppServer, h *admin.SysRoleHandler) {
group := s.Engine.Group("/api/admin/sysRole/")
group.GET("list", h.List)
group.POST("save", h.Save)
group.POST("remove", h.Remove)
}),
fx.Provide(handler.NewFunctionHandler),
fx.Invoke(func(s *core.AppServer, h *handler.FunctionHandler) {