mirror of
https://github.com/bufanyun/hotgo.git
synced 2025-11-13 20:53:49 +08:00
feature: 新增设置角色菜单配置
This commit is contained in:
@@ -8,11 +8,13 @@ package adminController
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/gogf/gf/v2/util/gconv"
|
||||
|
||||
"github.com/bufanyun/hotgo/app/com"
|
||||
"github.com/bufanyun/hotgo/app/form/adminForm"
|
||||
"github.com/bufanyun/hotgo/app/form/input"
|
||||
"github.com/bufanyun/hotgo/app/service/adminService"
|
||||
"github.com/gogf/gf/v2/util/gconv"
|
||||
)
|
||||
|
||||
// 角色
|
||||
@@ -94,3 +96,20 @@ func (controller *role) Dynamic(ctx context.Context, req *adminForm.RoleDynamicR
|
||||
}
|
||||
return res, nil
|
||||
}
|
||||
|
||||
//
|
||||
// @Title 修改角色菜单权限
|
||||
// @Description
|
||||
// @Author Ms <133814250@qq.com>
|
||||
// @Param ctx
|
||||
// @Param req
|
||||
// @Return res
|
||||
// @Return err
|
||||
//
|
||||
func (controller *role) Edit(ctx context.Context, req *adminForm.RoleMenuEditReq) (res *adminForm.RoleMenuEditRes, err error) {
|
||||
err = adminService.Role.EditRoleMenu(ctx, req)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return res, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user