v1

package
v1.0.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 30, 2024 License: MIT Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Service_GetRoleMenuIds_FullMethodName  = "/manager_role.Service/GetRoleMenuIds"
	Service_UpdateRoleMenus_FullMethodName = "/manager_role.Service/UpdateRoleMenus"
	Service_GetRoleTree_FullMethodName     = "/manager_role.Service/GetRoleTree"
	Service_AddRole_FullMethodName         = "/manager_role.Service/AddRole"
	Service_UpdateRole_FullMethodName      = "/manager_role.Service/UpdateRole"
	Service_DeleteRole_FullMethodName      = "/manager_role.Service/DeleteRole"
)
View Source
const OperationServiceAddRole = "/manager_role.Service/AddRole"
View Source
const OperationServiceDeleteRole = "/manager_role.Service/DeleteRole"
View Source
const OperationServiceGetRoleMenuIds = "/manager_role.Service/GetRoleMenuIds"
View Source
const OperationServiceGetRoleTree = "/manager_role.Service/GetRoleTree"
View Source
const OperationServiceUpdateRole = "/manager_role.Service/UpdateRole"
View Source
const OperationServiceUpdateRoleMenus = "/manager_role.Service/UpdateRoleMenus"

Variables

View Source
var File_manager_role_proto protoreflect.FileDescriptor
View Source
var File_manager_role_service_proto protoreflect.FileDescriptor
View Source
var Service_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "manager_role.Service",
	HandlerType: (*ServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetRoleMenuIds",
			Handler:    _Service_GetRoleMenuIds_Handler,
		},
		{
			MethodName: "UpdateRoleMenus",
			Handler:    _Service_UpdateRoleMenus_Handler,
		},
		{
			MethodName: "GetRoleTree",
			Handler:    _Service_GetRoleTree_Handler,
		},
		{
			MethodName: "AddRole",
			Handler:    _Service_AddRole_Handler,
		},
		{
			MethodName: "UpdateRole",
			Handler:    _Service_UpdateRole_Handler,
		},
		{
			MethodName: "DeleteRole",
			Handler:    _Service_DeleteRole_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "manager_role_service.proto",
}

Service_ServiceDesc is the grpc.ServiceDesc for Service service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterServiceHTTPServer

func RegisterServiceHTTPServer(s *http.Server, srv ServiceHTTPServer)

func RegisterServiceServer

func RegisterServiceServer(s grpc.ServiceRegistrar, srv ServiceServer)

Types

type AddRoleReply

type AddRoleReply struct {
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*AddRoleReply) Descriptor deprecated

func (*AddRoleReply) Descriptor() ([]byte, []int)

Deprecated: Use AddRoleReply.ProtoReflect.Descriptor instead.

func (*AddRoleReply) GetId

func (x *AddRoleReply) GetId() uint32

func (*AddRoleReply) ProtoMessage

func (*AddRoleReply) ProtoMessage()

func (*AddRoleReply) ProtoReflect

func (x *AddRoleReply) ProtoReflect() protoreflect.Message

func (*AddRoleReply) Reset

func (x *AddRoleReply) Reset()

func (*AddRoleReply) String

func (x *AddRoleReply) String() string

func (*AddRoleReply) Validate

func (m *AddRoleReply) Validate() error

Validate checks the field values on AddRoleReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*AddRoleReply) ValidateAll

func (m *AddRoleReply) ValidateAll() error

ValidateAll checks the field values on AddRoleReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in AddRoleReplyMultiError, or nil if none found.

type AddRoleReplyMultiError

type AddRoleReplyMultiError []error

AddRoleReplyMultiError is an error wrapping multiple validation errors returned by AddRoleReply.ValidateAll() if the designated constraints aren't met.

func (AddRoleReplyMultiError) AllErrors

func (m AddRoleReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AddRoleReplyMultiError) Error

func (m AddRoleReplyMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type AddRoleReplyValidationError

type AddRoleReplyValidationError struct {
	// contains filtered or unexported fields
}

AddRoleReplyValidationError is the validation error returned by AddRoleReply.Validate if the designated constraints aren't met.

func (AddRoleReplyValidationError) Cause

Cause function returns cause value.

func (AddRoleReplyValidationError) Error

Error satisfies the builtin error interface

func (AddRoleReplyValidationError) ErrorName

func (e AddRoleReplyValidationError) ErrorName() string

ErrorName returns error name.

func (AddRoleReplyValidationError) Field

Field function returns field value.

func (AddRoleReplyValidationError) Key

Key function returns key value.

func (AddRoleReplyValidationError) Reason

Reason function returns reason value.

type AddRoleRequest

type AddRoleRequest struct {
	ParentId      uint32 `protobuf:"varint,1,opt,name=parent_id,json=parentId,proto3" json:"parent_id,omitempty"`
	Name          string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Keyword       string `protobuf:"bytes,3,opt,name=keyword,proto3" json:"keyword,omitempty"`
	Status        *bool  `protobuf:"varint,4,opt,name=status,proto3,oneof" json:"status,omitempty"`
	Description   string `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty"`
	DepartmentIds string `protobuf:"bytes,6,opt,name=department_ids,json=departmentIds,proto3" json:"department_ids,omitempty"`
	DataScope     string `protobuf:"bytes,7,opt,name=data_scope,json=dataScope,proto3" json:"data_scope,omitempty"`
	// contains filtered or unexported fields
}

func (*AddRoleRequest) Descriptor deprecated

func (*AddRoleRequest) Descriptor() ([]byte, []int)

Deprecated: Use AddRoleRequest.ProtoReflect.Descriptor instead.

func (*AddRoleRequest) GetDataScope

func (x *AddRoleRequest) GetDataScope() string

func (*AddRoleRequest) GetDepartmentIds

func (x *AddRoleRequest) GetDepartmentIds() string

func (*AddRoleRequest) GetDescription

func (x *AddRoleRequest) GetDescription() string

func (*AddRoleRequest) GetKeyword

func (x *AddRoleRequest) GetKeyword() string

func (*AddRoleRequest) GetName

func (x *AddRoleRequest) GetName() string

func (*AddRoleRequest) GetParentId

func (x *AddRoleRequest) GetParentId() uint32

func (*AddRoleRequest) GetStatus

func (x *AddRoleRequest) GetStatus() bool

func (*AddRoleRequest) ProtoMessage

func (*AddRoleRequest) ProtoMessage()

func (*AddRoleRequest) ProtoReflect

func (x *AddRoleRequest) ProtoReflect() protoreflect.Message

func (*AddRoleRequest) Reset

func (x *AddRoleRequest) Reset()

func (*AddRoleRequest) String

func (x *AddRoleRequest) String() string

func (*AddRoleRequest) Validate

func (m *AddRoleRequest) Validate() error

Validate checks the field values on AddRoleRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*AddRoleRequest) ValidateAll

func (m *AddRoleRequest) ValidateAll() error

ValidateAll checks the field values on AddRoleRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in AddRoleRequestMultiError, or nil if none found.

type AddRoleRequestMultiError

type AddRoleRequestMultiError []error

AddRoleRequestMultiError is an error wrapping multiple validation errors returned by AddRoleRequest.ValidateAll() if the designated constraints aren't met.

func (AddRoleRequestMultiError) AllErrors

func (m AddRoleRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AddRoleRequestMultiError) Error

func (m AddRoleRequestMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type AddRoleRequestValidationError

type AddRoleRequestValidationError struct {
	// contains filtered or unexported fields
}

AddRoleRequestValidationError is the validation error returned by AddRoleRequest.Validate if the designated constraints aren't met.

func (AddRoleRequestValidationError) Cause

Cause function returns cause value.

func (AddRoleRequestValidationError) Error

Error satisfies the builtin error interface

func (AddRoleRequestValidationError) ErrorName

func (e AddRoleRequestValidationError) ErrorName() string

ErrorName returns error name.

func (AddRoleRequestValidationError) Field

Field function returns field value.

func (AddRoleRequestValidationError) Key

Key function returns key value.

func (AddRoleRequestValidationError) Reason

Reason function returns reason value.

type DeleteRoleRequest

type DeleteRoleRequest struct {
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteRoleRequest) Descriptor deprecated

func (*DeleteRoleRequest) Descriptor() ([]byte, []int)

Deprecated: Use DeleteRoleRequest.ProtoReflect.Descriptor instead.

func (*DeleteRoleRequest) GetId

func (x *DeleteRoleRequest) GetId() uint32

func (*DeleteRoleRequest) ProtoMessage

func (*DeleteRoleRequest) ProtoMessage()

func (*DeleteRoleRequest) ProtoReflect

func (x *DeleteRoleRequest) ProtoReflect() protoreflect.Message

func (*DeleteRoleRequest) Reset

func (x *DeleteRoleRequest) Reset()

func (*DeleteRoleRequest) String

func (x *DeleteRoleRequest) String() string

func (*DeleteRoleRequest) Validate

func (m *DeleteRoleRequest) Validate() error

Validate checks the field values on DeleteRoleRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*DeleteRoleRequest) ValidateAll

func (m *DeleteRoleRequest) ValidateAll() error

ValidateAll checks the field values on DeleteRoleRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DeleteRoleRequestMultiError, or nil if none found.

type DeleteRoleRequestMultiError

type DeleteRoleRequestMultiError []error

DeleteRoleRequestMultiError is an error wrapping multiple validation errors returned by DeleteRoleRequest.ValidateAll() if the designated constraints aren't met.

func (DeleteRoleRequestMultiError) AllErrors

func (m DeleteRoleRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DeleteRoleRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type DeleteRoleRequestValidationError

type DeleteRoleRequestValidationError struct {
	// contains filtered or unexported fields
}

DeleteRoleRequestValidationError is the validation error returned by DeleteRoleRequest.Validate if the designated constraints aren't met.

func (DeleteRoleRequestValidationError) Cause

Cause function returns cause value.

func (DeleteRoleRequestValidationError) Error

Error satisfies the builtin error interface

func (DeleteRoleRequestValidationError) ErrorName

ErrorName returns error name.

func (DeleteRoleRequestValidationError) Field

Field function returns field value.

func (DeleteRoleRequestValidationError) Key

Key function returns key value.

func (DeleteRoleRequestValidationError) Reason

Reason function returns reason value.

type GetRoleMenuIdsReply

type GetRoleMenuIdsReply struct {
	List []uint32 `protobuf:"varint,1,rep,packed,name=list,proto3" json:"list,omitempty"`
	// contains filtered or unexported fields
}

func (*GetRoleMenuIdsReply) Descriptor deprecated

func (*GetRoleMenuIdsReply) Descriptor() ([]byte, []int)

Deprecated: Use GetRoleMenuIdsReply.ProtoReflect.Descriptor instead.

func (*GetRoleMenuIdsReply) GetList

func (x *GetRoleMenuIdsReply) GetList() []uint32

func (*GetRoleMenuIdsReply) ProtoMessage

func (*GetRoleMenuIdsReply) ProtoMessage()

func (*GetRoleMenuIdsReply) ProtoReflect

func (x *GetRoleMenuIdsReply) ProtoReflect() protoreflect.Message

func (*GetRoleMenuIdsReply) Reset

func (x *GetRoleMenuIdsReply) Reset()

func (*GetRoleMenuIdsReply) String

func (x *GetRoleMenuIdsReply) String() string

func (*GetRoleMenuIdsReply) Validate

func (m *GetRoleMenuIdsReply) Validate() error

Validate checks the field values on GetRoleMenuIdsReply with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*GetRoleMenuIdsReply) ValidateAll

func (m *GetRoleMenuIdsReply) ValidateAll() error

ValidateAll checks the field values on GetRoleMenuIdsReply with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in GetRoleMenuIdsReplyMultiError, or nil if none found.

type GetRoleMenuIdsReplyMultiError

type GetRoleMenuIdsReplyMultiError []error

GetRoleMenuIdsReplyMultiError is an error wrapping multiple validation errors returned by GetRoleMenuIdsReply.ValidateAll() if the designated constraints aren't met.

func (GetRoleMenuIdsReplyMultiError) AllErrors

func (m GetRoleMenuIdsReplyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (GetRoleMenuIdsReplyMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type GetRoleMenuIdsReplyValidationError

type GetRoleMenuIdsReplyValidationError struct {
	// contains filtered or unexported fields
}

GetRoleMenuIdsReplyValidationError is the validation error returned by GetRoleMenuIdsReply.Validate if the designated constraints aren't met.

func (GetRoleMenuIdsReplyValidationError) Cause

Cause function returns cause value.

func (GetRoleMenuIdsReplyValidationError) Error

Error satisfies the builtin error interface

func (GetRoleMenuIdsReplyValidationError) ErrorName

ErrorName returns error name.

func (GetRoleMenuIdsReplyValidationError) Field

Field function returns field value.

func (GetRoleMenuIdsReplyValidationError) Key

Key function returns key value.

func (GetRoleMenuIdsReplyValidationError) Reason

Reason function returns reason value.

type GetRoleMenuIdsRequest

type GetRoleMenuIdsRequest struct {
	RoleId uint32 `protobuf:"varint,1,opt,name=role_id,json=roleId,proto3" json:"role_id,omitempty"`
	// contains filtered or unexported fields
}

func (*GetRoleMenuIdsRequest) Descriptor deprecated

func (*GetRoleMenuIdsRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetRoleMenuIdsRequest.ProtoReflect.Descriptor instead.

func (*GetRoleMenuIdsRequest) GetRoleId

func (x *GetRoleMenuIdsRequest) GetRoleId() uint32

func (*GetRoleMenuIdsRequest) ProtoMessage

func (*GetRoleMenuIdsRequest) ProtoMessage()

func (*GetRoleMenuIdsRequest) ProtoReflect

func (x *GetRoleMenuIdsRequest) ProtoReflect() protoreflect.Message

func (*GetRoleMenuIdsRequest) Reset

func (x *GetRoleMenuIdsRequest) Reset()

func (*GetRoleMenuIdsRequest) String

func (x *GetRoleMenuIdsRequest) String() string

func (*GetRoleMenuIdsRequest) Validate

func (m *GetRoleMenuIdsRequest) Validate() error

Validate checks the field values on GetRoleMenuIdsRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*GetRoleMenuIdsRequest) ValidateAll

func (m *GetRoleMenuIdsRequest) ValidateAll() error

ValidateAll checks the field values on GetRoleMenuIdsRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in GetRoleMenuIdsRequestMultiError, or nil if none found.

type GetRoleMenuIdsRequestMultiError

type GetRoleMenuIdsRequestMultiError []error

GetRoleMenuIdsRequestMultiError is an error wrapping multiple validation errors returned by GetRoleMenuIdsRequest.ValidateAll() if the designated constraints aren't met.

func (GetRoleMenuIdsRequestMultiError) AllErrors

func (m GetRoleMenuIdsRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (GetRoleMenuIdsRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type GetRoleMenuIdsRequestValidationError

type GetRoleMenuIdsRequestValidationError struct {
	// contains filtered or unexported fields
}

GetRoleMenuIdsRequestValidationError is the validation error returned by GetRoleMenuIdsRequest.Validate if the designated constraints aren't met.

func (GetRoleMenuIdsRequestValidationError) Cause

Cause function returns cause value.

func (GetRoleMenuIdsRequestValidationError) Error

Error satisfies the builtin error interface

func (GetRoleMenuIdsRequestValidationError) ErrorName

ErrorName returns error name.

func (GetRoleMenuIdsRequestValidationError) Field

Field function returns field value.

func (GetRoleMenuIdsRequestValidationError) Key

Key function returns key value.

func (GetRoleMenuIdsRequestValidationError) Reason

Reason function returns reason value.

type GetRoleRequest

type GetRoleRequest struct {
	Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

获取指定的角色

func (*GetRoleRequest) Descriptor deprecated

func (*GetRoleRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetRoleRequest.ProtoReflect.Descriptor instead.

func (*GetRoleRequest) GetId

func (x *GetRoleRequest) GetId() uint32

func (*GetRoleRequest) ProtoMessage

func (*GetRoleRequest) ProtoMessage()

func (*GetRoleRequest) ProtoReflect

func (x *GetRoleRequest) ProtoReflect() protoreflect.Message

func (*GetRoleRequest) Reset

func (x *GetRoleRequest) Reset()

func (*GetRoleRequest) String

func (x *GetRoleRequest) String() string

func (*GetRoleRequest) Validate

func (m *GetRoleRequest) Validate() error

Validate checks the field values on GetRoleRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*GetRoleRequest) ValidateAll

func (m *GetRoleRequest) ValidateAll() error

ValidateAll checks the field values on GetRoleRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in GetRoleRequestMultiError, or nil if none found.

type GetRoleRequestMultiError

type GetRoleRequestMultiError []error

GetRoleRequestMultiError is an error wrapping multiple validation errors returned by GetRoleRequest.ValidateAll() if the designated constraints aren't met.

func (GetRoleRequestMultiError) AllErrors

func (m GetRoleRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (GetRoleRequestMultiError) Error

func (m GetRoleRequestMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type GetRoleRequestValidationError

type GetRoleRequestValidationError struct {
	// contains filtered or unexported fields
}

GetRoleRequestValidationError is the validation error returned by GetRoleRequest.Validate if the designated constraints aren't met.

func (GetRoleRequestValidationError) Cause

Cause function returns cause value.

func (GetRoleRequestValidationError) Error

Error satisfies the builtin error interface

func (GetRoleRequestValidationError) ErrorName

func (e GetRoleRequestValidationError) ErrorName() string

ErrorName returns error name.

func (GetRoleRequestValidationError) Field

Field function returns field value.

func (GetRoleRequestValidationError) Key

Key function returns key value.

func (GetRoleRequestValidationError) Reason

Reason function returns reason value.

type Role

type Role struct {
	Id            uint32  `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	ParentId      uint32  `protobuf:"varint,2,opt,name=parent_id,json=parentId,proto3" json:"parent_id,omitempty"`
	Name          string  `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
	Keyword       string  `protobuf:"bytes,4,opt,name=keyword,proto3" json:"keyword,omitempty"`
	Status        bool    `protobuf:"varint,5,opt,name=status,proto3" json:"status,omitempty"`
	Description   string  `protobuf:"bytes,6,opt,name=description,proto3" json:"description,omitempty"`
	DepartmentIds string  `protobuf:"bytes,7,opt,name=department_ids,json=departmentIds,proto3" json:"department_ids,omitempty"`
	DataScope     string  `protobuf:"bytes,8,opt,name=data_scope,json=dataScope,proto3" json:"data_scope,omitempty"`
	CreatedAt     uint32  `protobuf:"varint,9,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
	UpdatedAt     uint32  `protobuf:"varint,10,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
	Children      []*Role `protobuf:"bytes,11,rep,name=children,proto3" json:"children,omitempty"`
	// contains filtered or unexported fields
}

func (*Role) Descriptor deprecated

func (*Role) Descriptor() ([]byte, []int)

Deprecated: Use Role.ProtoReflect.Descriptor instead.

func (*Role) GetChildren

func (x *Role) GetChildren() []*Role

func (*Role) GetCreatedAt

func (x *Role) GetCreatedAt() uint32

func (*Role) GetDataScope

func (x *Role) GetDataScope() string

func (*Role) GetDepartmentIds

func (x *Role) GetDepartmentIds() string

func (*Role) GetDescription

func (x *Role) GetDescription() string

func (*Role) GetId

func (x *Role) GetId() uint32

func (*Role) GetKeyword

func (x *Role) GetKeyword() string

func (*Role) GetName

func (x *Role) GetName() string

func (*Role) GetParentId

func (x *Role) GetParentId() uint32

func (*Role) GetStatus

func (x *Role) GetStatus() bool

func (*Role) GetUpdatedAt

func (x *Role) GetUpdatedAt() uint32

func (*Role) ProtoMessage

func (*Role) ProtoMessage()

func (*Role) ProtoReflect

func (x *Role) ProtoReflect() protoreflect.Message

func (*Role) Reset

func (x *Role) Reset()

func (*Role) String

func (x *Role) String() string

func (*Role) Validate

func (m *Role) Validate() error

Validate checks the field values on Role with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Role) ValidateAll

func (m *Role) ValidateAll() error

ValidateAll checks the field values on Role with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in RoleMultiError, or nil if none found.

type RoleMultiError

type RoleMultiError []error

RoleMultiError is an error wrapping multiple validation errors returned by Role.ValidateAll() if the designated constraints aren't met.

func (RoleMultiError) AllErrors

func (m RoleMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (RoleMultiError) Error

func (m RoleMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type RoleValidationError

type RoleValidationError struct {
	// contains filtered or unexported fields
}

RoleValidationError is the validation error returned by Role.Validate if the designated constraints aren't met.

func (RoleValidationError) Cause

func (e RoleValidationError) Cause() error

Cause function returns cause value.

func (RoleValidationError) Error

func (e RoleValidationError) Error() string

Error satisfies the builtin error interface

func (RoleValidationError) ErrorName

func (e RoleValidationError) ErrorName() string

ErrorName returns error name.

func (RoleValidationError) Field

func (e RoleValidationError) Field() string

Field function returns field value.

func (RoleValidationError) Key

func (e RoleValidationError) Key() bool

Key function returns key value.

func (RoleValidationError) Reason

func (e RoleValidationError) Reason() string

Reason function returns reason value.

type ServiceClient

type ServiceClient interface {
	// CurrentRoleMenus 获取当前用户的角色列表
	GetRoleMenuIds(ctx context.Context, in *GetRoleMenuIdsRequest, opts ...grpc.CallOption) (*GetRoleMenuIdsReply, error)
	// AddRoleMenus 更新角色菜单
	UpdateRoleMenus(ctx context.Context, in *UpdateRoleMenuRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	// GetRoleTree 获取能管理的角色树
	GetRoleTree(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*Role, error)
	// AddRole 新增角色
	AddRole(ctx context.Context, in *AddRoleRequest, opts ...grpc.CallOption) (*AddRoleReply, error)
	// UpdateRole 更新角色
	UpdateRole(ctx context.Context, in *UpdateRoleRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	// DeleteRole 删除角色
	DeleteRole(ctx context.Context, in *DeleteRoleRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
}

ServiceClient is the client API for Service service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewServiceClient

func NewServiceClient(cc grpc.ClientConnInterface) ServiceClient

type ServiceHTTPClient

type ServiceHTTPClient interface {
	AddRole(ctx context.Context, req *AddRoleRequest, opts ...http.CallOption) (rsp *AddRoleReply, err error)
	DeleteRole(ctx context.Context, req *DeleteRoleRequest, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	GetRoleMenuIds(ctx context.Context, req *GetRoleMenuIdsRequest, opts ...http.CallOption) (rsp *GetRoleMenuIdsReply, err error)
	GetRoleTree(ctx context.Context, req *emptypb.Empty, opts ...http.CallOption) (rsp *Role, err error)
	UpdateRole(ctx context.Context, req *UpdateRoleRequest, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	UpdateRoleMenus(ctx context.Context, req *UpdateRoleMenuRequest, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
}

func NewServiceHTTPClient

func NewServiceHTTPClient(client *http.Client) ServiceHTTPClient

type ServiceHTTPClientImpl

type ServiceHTTPClientImpl struct {
	// contains filtered or unexported fields
}

func (*ServiceHTTPClientImpl) AddRole

func (*ServiceHTTPClientImpl) DeleteRole

func (*ServiceHTTPClientImpl) GetRoleMenuIds

func (*ServiceHTTPClientImpl) GetRoleTree

func (c *ServiceHTTPClientImpl) GetRoleTree(ctx context.Context, in *emptypb.Empty, opts ...http.CallOption) (*Role, error)

func (*ServiceHTTPClientImpl) UpdateRole

func (*ServiceHTTPClientImpl) UpdateRoleMenus

func (c *ServiceHTTPClientImpl) UpdateRoleMenus(ctx context.Context, in *UpdateRoleMenuRequest, opts ...http.CallOption) (*emptypb.Empty, error)

type ServiceHTTPServer

type ServiceHTTPServer interface {
	// AddRole AddRole 新增角色
	AddRole(context.Context, *AddRoleRequest) (*AddRoleReply, error)
	// DeleteRole DeleteRole 删除角色
	DeleteRole(context.Context, *DeleteRoleRequest) (*emptypb.Empty, error)
	// GetRoleMenuIds CurrentRoleMenus 获取当前用户的角色列表
	GetRoleMenuIds(context.Context, *GetRoleMenuIdsRequest) (*GetRoleMenuIdsReply, error)
	// GetRoleTree GetRoleTree 获取能管理的角色树
	GetRoleTree(context.Context, *emptypb.Empty) (*Role, error)
	// UpdateRole UpdateRole 更新角色
	UpdateRole(context.Context, *UpdateRoleRequest) (*emptypb.Empty, error)
	// UpdateRoleMenus AddRoleMenus 更新角色菜单
	UpdateRoleMenus(context.Context, *UpdateRoleMenuRequest) (*emptypb.Empty, error)
}

type ServiceServer

type ServiceServer interface {
	// CurrentRoleMenus 获取当前用户的角色列表
	GetRoleMenuIds(context.Context, *GetRoleMenuIdsRequest) (*GetRoleMenuIdsReply, error)
	// AddRoleMenus 更新角色菜单
	UpdateRoleMenus(context.Context, *UpdateRoleMenuRequest) (*emptypb.Empty, error)
	// GetRoleTree 获取能管理的角色树
	GetRoleTree(context.Context, *emptypb.Empty) (*Role, error)
	// AddRole 新增角色
	AddRole(context.Context, *AddRoleRequest) (*AddRoleReply, error)
	// UpdateRole 更新角色
	UpdateRole(context.Context, *UpdateRoleRequest) (*emptypb.Empty, error)
	// DeleteRole 删除角色
	DeleteRole(context.Context, *DeleteRoleRequest) (*emptypb.Empty, error)
	// contains filtered or unexported methods
}

ServiceServer is the server API for Service service. All implementations must embed UnimplementedServiceServer for forward compatibility

type UnimplementedServiceServer

type UnimplementedServiceServer struct {
}

UnimplementedServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedServiceServer) AddRole

func (UnimplementedServiceServer) DeleteRole

func (UnimplementedServiceServer) GetRoleMenuIds

func (UnimplementedServiceServer) GetRoleTree

func (UnimplementedServiceServer) UpdateRole

func (UnimplementedServiceServer) UpdateRoleMenus

type UnsafeServiceServer

type UnsafeServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ServiceServer will result in compilation errors.

type UpdateRoleMenuRequest

type UpdateRoleMenuRequest struct {
	RoleId  uint32   `protobuf:"varint,1,opt,name=role_id,json=roleId,proto3" json:"role_id,omitempty"`
	MenuIds []uint32 `protobuf:"varint,2,rep,packed,name=menu_ids,json=menuIds,proto3" json:"menu_ids,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateRoleMenuRequest) Descriptor deprecated

func (*UpdateRoleMenuRequest) Descriptor() ([]byte, []int)

Deprecated: Use UpdateRoleMenuRequest.ProtoReflect.Descriptor instead.

func (*UpdateRoleMenuRequest) GetMenuIds

func (x *UpdateRoleMenuRequest) GetMenuIds() []uint32

func (*UpdateRoleMenuRequest) GetRoleId

func (x *UpdateRoleMenuRequest) GetRoleId() uint32

func (*UpdateRoleMenuRequest) ProtoMessage

func (*UpdateRoleMenuRequest) ProtoMessage()

func (*UpdateRoleMenuRequest) ProtoReflect

func (x *UpdateRoleMenuRequest) ProtoReflect() protoreflect.Message

func (*UpdateRoleMenuRequest) Reset

func (x *UpdateRoleMenuRequest) Reset()

func (*UpdateRoleMenuRequest) String

func (x *UpdateRoleMenuRequest) String() string

func (*UpdateRoleMenuRequest) Validate

func (m *UpdateRoleMenuRequest) Validate() error

Validate checks the field values on UpdateRoleMenuRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*UpdateRoleMenuRequest) ValidateAll

func (m *UpdateRoleMenuRequest) ValidateAll() error

ValidateAll checks the field values on UpdateRoleMenuRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in UpdateRoleMenuRequestMultiError, or nil if none found.

type UpdateRoleMenuRequestMultiError

type UpdateRoleMenuRequestMultiError []error

UpdateRoleMenuRequestMultiError is an error wrapping multiple validation errors returned by UpdateRoleMenuRequest.ValidateAll() if the designated constraints aren't met.

func (UpdateRoleMenuRequestMultiError) AllErrors

func (m UpdateRoleMenuRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (UpdateRoleMenuRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type UpdateRoleMenuRequestValidationError

type UpdateRoleMenuRequestValidationError struct {
	// contains filtered or unexported fields
}

UpdateRoleMenuRequestValidationError is the validation error returned by UpdateRoleMenuRequest.Validate if the designated constraints aren't met.

func (UpdateRoleMenuRequestValidationError) Cause

Cause function returns cause value.

func (UpdateRoleMenuRequestValidationError) Error

Error satisfies the builtin error interface

func (UpdateRoleMenuRequestValidationError) ErrorName

ErrorName returns error name.

func (UpdateRoleMenuRequestValidationError) Field

Field function returns field value.

func (UpdateRoleMenuRequestValidationError) Key

Key function returns key value.

func (UpdateRoleMenuRequestValidationError) Reason

Reason function returns reason value.

type UpdateRoleRequest

type UpdateRoleRequest struct {
	Id            uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	ParentId      uint32 `protobuf:"varint,2,opt,name=parent_id,json=parentId,proto3" json:"parent_id,omitempty"`
	Name          string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
	Status        *bool  `protobuf:"varint,4,opt,name=status,proto3,oneof" json:"status,omitempty"`
	Description   string `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty"`
	DepartmentIds string `protobuf:"bytes,6,opt,name=department_ids,json=departmentIds,proto3" json:"department_ids,omitempty"`
	DataScope     string `protobuf:"bytes,7,opt,name=data_scope,json=dataScope,proto3" json:"data_scope,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateRoleRequest) Descriptor deprecated

func (*UpdateRoleRequest) Descriptor() ([]byte, []int)

Deprecated: Use UpdateRoleRequest.ProtoReflect.Descriptor instead.

func (*UpdateRoleRequest) GetDataScope

func (x *UpdateRoleRequest) GetDataScope() string

func (*UpdateRoleRequest) GetDepartmentIds

func (x *UpdateRoleRequest) GetDepartmentIds() string

func (*UpdateRoleRequest) GetDescription

func (x *UpdateRoleRequest) GetDescription() string

func (*UpdateRoleRequest) GetId

func (x *UpdateRoleRequest) GetId() uint32

func (*UpdateRoleRequest) GetName

func (x *UpdateRoleRequest) GetName() string

func (*UpdateRoleRequest) GetParentId

func (x *UpdateRoleRequest) GetParentId() uint32

func (*UpdateRoleRequest) GetStatus

func (x *UpdateRoleRequest) GetStatus() bool

func (*UpdateRoleRequest) ProtoMessage

func (*UpdateRoleRequest) ProtoMessage()

func (*UpdateRoleRequest) ProtoReflect

func (x *UpdateRoleRequest) ProtoReflect() protoreflect.Message

func (*UpdateRoleRequest) Reset

func (x *UpdateRoleRequest) Reset()

func (*UpdateRoleRequest) String

func (x *UpdateRoleRequest) String() string

func (*UpdateRoleRequest) Validate

func (m *UpdateRoleRequest) Validate() error

Validate checks the field values on UpdateRoleRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*UpdateRoleRequest) ValidateAll

func (m *UpdateRoleRequest) ValidateAll() error

ValidateAll checks the field values on UpdateRoleRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in UpdateRoleRequestMultiError, or nil if none found.

type UpdateRoleRequestMultiError

type UpdateRoleRequestMultiError []error

UpdateRoleRequestMultiError is an error wrapping multiple validation errors returned by UpdateRoleRequest.ValidateAll() if the designated constraints aren't met.

func (UpdateRoleRequestMultiError) AllErrors

func (m UpdateRoleRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (UpdateRoleRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type UpdateRoleRequestValidationError

type UpdateRoleRequestValidationError struct {
	// contains filtered or unexported fields
}

UpdateRoleRequestValidationError is the validation error returned by UpdateRoleRequest.Validate if the designated constraints aren't met.

func (UpdateRoleRequestValidationError) Cause

Cause function returns cause value.

func (UpdateRoleRequestValidationError) Error

Error satisfies the builtin error interface

func (UpdateRoleRequestValidationError) ErrorName

ErrorName returns error name.

func (UpdateRoleRequestValidationError) Field

Field function returns field value.

func (UpdateRoleRequestValidationError) Key

Key function returns key value.

func (UpdateRoleRequestValidationError) Reason

Reason function returns reason value.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL