作者 yangfu

用户菜单修改

... ... @@ -10,6 +10,10 @@ import (
type UserMenusCommand struct {
//操作人
Operator domain.Operator `json:"-"`
// 菜单类别 web app
MenuCategory string `cname:"菜单类别 web app" json:"menuCategory,omitempty"`
// 返回所有不可以用的菜单
ALLDisableMenu int `cname:"同时返回所有不可以用的菜单 1:包含不可用的菜单 0:过滤不可用的菜单 " json:"allDisableMenu"`
}
func (userMenusCommand *UserMenusCommand) Valid(validation *validation.Validation) {
... ...
... ... @@ -234,7 +234,9 @@ func (svr AuthService) GetUserMenus(userMenusCommand *command.UserMenusCommand)
creationUserGateway := allied_creation_user.NewHttplibAlliedCreationUser(
userMenusCommand.Operator)
resultMenu, err := creationUserGateway.UserAccessMenus(allied_creation_user.ReqUserAccessMenus{
UserId: int(userMenusCommand.Operator.UserId),
UserId: int(userMenusCommand.Operator.UserId),
MenuCategory: userMenusCommand.MenuCategory,
ALLDisableMenu: userMenusCommand.ALLDisableMenu,
})
if err != nil {
return nil, application.ThrowError(application.BUSINESS_ERROR, err.Error())
... ...
... ... @@ -25,8 +25,9 @@ type CooperationApplicationItem struct {
IsCanceled bool `json:"isCanceled"` //是否取消
CooperationApplicationVerifyDescription string `json:"cooperationApplicationVerifyDescription"` //审核描述
CooperationApplicationVerifyTime time.Time `json:"cooperationApplicationVerifyTime"` //审核时间
CooperationApplicationStatus int `json:"cooperationApplicationStatus"` //申请状态
Org struct {
CooperationApplicationStatus int `json:"cooperationApplicationStatus"` //
Org struct {
OrgID int `json:"orgId"`
OrgName string `json:"orgName"`
} `json:"org"` //组织
... ...
... ... @@ -310,6 +310,10 @@ type (
type (
ReqUserAccessMenus struct {
UserId int `json:"userId"`
// 菜单类别 web app
MenuCategory string `cname:"菜单类别 web app" json:"menuCategory,omitempty"`
// 返回所有不可以用的菜单
ALLDisableMenu int `cname:"同时返回所有不可以用的菜单 1:包含不可用的菜单 0:过滤不可用的菜单 " json:"allDisableMenu"`
}
DataUserAccessMenus struct {
Menus []struct {
... ...
... ... @@ -32,7 +32,8 @@ func init() {
web.Router("/v1/app/cooperation-projects/:projectId", &mobile_client.CooperationController{}, "Put:UpdateCooperationProject")
web.Router("/v1/app/cooperation-projects/end", &mobile_client.CooperationController{}, "Post:EndCooperationProject")
web.Router("/v1/app/cooperation-projects/search", &mobile_client.CooperationController{}, "Post:SearchCooperationProject")
web.Router("/v1/app/cooperation-modes/", &web_client.CooperationModeController{}, "Get:ListCooperationMode")
web.Router("/v1/app/cooperation-modes", &web_client.CooperationModeController{}, "Get:ListCooperationMode")
web.Router("/v1/common/cooperation/mode", &web_client.CooperationModeController{}, "Get:ListCooperationMode")
web.Router("/v1/app/cooperation-projects/person/search", &mobile_client.CooperationController{}, "Post:PersonSearchCooperationProject")
... ...