Documentation ¶
Index ¶
- Variables
- type CreateRoleRequest
- func (*CreateRoleRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateRoleRequest) GetDescription() string
- func (x *CreateRoleRequest) GetMeta() map[string]string
- func (x *CreateRoleRequest) GetName() string
- func (x *CreateRoleRequest) GetPermissions() []*Permission
- func (*CreateRoleRequest) ProtoMessage()
- func (x *CreateRoleRequest) ProtoReflect() protoreflect.Message
- func (x *CreateRoleRequest) Reset()
- func (x *CreateRoleRequest) String() string
- type Featrue
- type Permission
- func (*Permission) Descriptor() ([]byte, []int)deprecated
- func (x *Permission) GetFeatrues() []*Featrue
- func (x *Permission) GetService() string
- func (*Permission) ProtoMessage()
- func (x *Permission) ProtoReflect() protoreflect.Message
- func (x *Permission) Reset()
- func (x *Permission) String() string
- type Role
Constants ¶
This section is empty.
Variables ¶
View Source
var File_apps_role_pb_role_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type CreateRoleRequest ¶
type CreateRoleRequest struct { // 角色名称 // @gotags: json:"name" bson:"name" Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name" bson:"name"` // 角色标识 // @gotags: json:"description" bson:"description" Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description" bson:"description"` // 角色的权限 // @gotags: json:"permissions" bson:"permissions" Permissions []*Permission `protobuf:"bytes,3,rep,name=permissions,proto3" json:"permissions" bson:"permissions"` // 角色的一些额外属性 // @gotags: json:"meta" bson:"meta" Meta map[string]string `` /* 151-byte string literal not displayed */ // contains filtered or unexported fields }
func (*CreateRoleRequest) Descriptor
deprecated
func (*CreateRoleRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateRoleRequest.ProtoReflect.Descriptor instead.
func (*CreateRoleRequest) GetDescription ¶
func (x *CreateRoleRequest) GetDescription() string
func (*CreateRoleRequest) GetMeta ¶
func (x *CreateRoleRequest) GetMeta() map[string]string
func (*CreateRoleRequest) GetName ¶
func (x *CreateRoleRequest) GetName() string
func (*CreateRoleRequest) GetPermissions ¶
func (x *CreateRoleRequest) GetPermissions() []*Permission
func (*CreateRoleRequest) ProtoMessage ¶
func (*CreateRoleRequest) ProtoMessage()
func (*CreateRoleRequest) ProtoReflect ¶
func (x *CreateRoleRequest) ProtoReflect() protoreflect.Message
func (*CreateRoleRequest) Reset ¶
func (x *CreateRoleRequest) Reset()
func (*CreateRoleRequest) String ¶
func (x *CreateRoleRequest) String() string
type Featrue ¶
type Featrue struct { // 资源名称 // @gotags: json:"resource" bson:"resource" Resource string `protobuf:"bytes,3,opt,name=resource,proto3" json:"resource" bson:"resource"` // 资源操作 // @gotags: json:"action" bson:"action" Action string `protobuf:"bytes,4,opt,name=action,proto3" json:"action" bson:"action"` // contains filtered or unexported fields }
func (*Featrue) Descriptor
deprecated
func (*Featrue) GetResource ¶
func (*Featrue) ProtoMessage ¶
func (*Featrue) ProtoMessage()
func (*Featrue) ProtoReflect ¶
func (x *Featrue) ProtoReflect() protoreflect.Message
type Permission ¶
type Permission struct { // 服务名称 // @gotags: json:"service" bson:"service" Service string `protobuf:"bytes,1,opt,name=service,proto3" json:"service" bson:"service"` // 服务功能 // @gotags: json:"featrues" bson:"featrues" Featrues []*Featrue `protobuf:"bytes,2,rep,name=featrues,proto3" json:"featrues" bson:"featrues"` // contains filtered or unexported fields }
那个服务 的哪些权限
func (*Permission) Descriptor
deprecated
func (*Permission) Descriptor() ([]byte, []int)
Deprecated: Use Permission.ProtoReflect.Descriptor instead.
func (*Permission) GetFeatrues ¶
func (x *Permission) GetFeatrues() []*Featrue
func (*Permission) GetService ¶
func (x *Permission) GetService() string
func (*Permission) ProtoMessage ¶
func (*Permission) ProtoMessage()
func (*Permission) ProtoReflect ¶
func (x *Permission) ProtoReflect() protoreflect.Message
func (*Permission) Reset ¶
func (x *Permission) Reset()
func (*Permission) String ¶
func (x *Permission) String() string
type Role ¶
type Role struct { // 角色id // @gotags: json:"id" bson:"_id" Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id" bson:"_id"` // 角色创建时间 // @gotags: json:"name" bson:"create_at" CreateAt int64 `protobuf:"varint,2,opt,name=create_at,json=createAt,proto3" json:"name" bson:"create_at"` // 角色名称 // @gotags: json:"spec" bson:"spec" Spec *CreateRoleRequest `protobuf:"bytes,3,opt,name=spec,proto3" json:"spec" bson:"spec"` // contains filtered or unexported fields }
func (*Role) Descriptor
deprecated
func (*Role) GetCreateAt ¶
func (*Role) GetSpec ¶
func (x *Role) GetSpec() *CreateRoleRequest
func (*Role) ProtoMessage ¶
func (*Role) ProtoMessage()
func (*Role) ProtoReflect ¶
func (x *Role) ProtoReflect() protoreflect.Message
Click to show internal directories.
Click to hide internal directories.