init: init refactor

This commit is contained in:
Blizzard
2026-04-27 00:02:18 +08:00
commit e515f6a287
360 changed files with 30713 additions and 0 deletions
@@ -0,0 +1,42 @@
// Code generated by goctl. DO NOT EDIT.
// goctl 1.10.1
// Source: system.proto
package server
import (
"context"
"sundynix-micro-go/app/system/rpc/internal/logic"
"sundynix-micro-go/app/system/rpc/internal/svc"
"sundynix-micro-go/app/system/rpc/system"
)
type SystemServiceServer struct {
svcCtx *svc.ServiceContext
system.UnimplementedSystemServiceServer
}
func NewSystemServiceServer(svcCtx *svc.ServiceContext) *SystemServiceServer {
return &SystemServiceServer{
svcCtx: svcCtx,
}
}
// 获取用户角色列表
func (s *SystemServiceServer) GetRolesByUserId(ctx context.Context, in *system.GetRolesByUserIdReq) (*system.GetRolesByUserIdResp, error) {
l := logic.NewGetRolesByUserIdLogic(ctx, s.svcCtx)
return l.GetRolesByUserId(in)
}
// 获取角色菜单列表
func (s *SystemServiceServer) GetMenusByRoleId(ctx context.Context, in *system.GetMenusByRoleIdReq) (*system.GetMenusByRoleIdResp, error) {
l := logic.NewGetMenusByRoleIdLogic(ctx, s.svcCtx)
return l.GetMenusByRoleId(in)
}
// 获取客户端信息
func (s *SystemServiceServer) GetClientById(ctx context.Context, in *system.GetClientByIdReq) (*system.GetClientByIdResp, error) {
l := logic.NewGetClientByIdLogic(ctx, s.svcCtx)
return l.GetClientById(in)
}