add admin
This commit is contained in:
@@ -23,17 +23,42 @@ func NewAdminServer(svcCtx *svc.ServiceContext) *AdminServer {
|
||||
}
|
||||
}
|
||||
|
||||
func (s *AdminServer) Add(ctx context.Context, in *admin.AddRequest) (*admin.Response, error) {
|
||||
l := logic.NewAddLogic(ctx, s.svcCtx)
|
||||
return l.Add(in)
|
||||
func (s *AdminServer) AdminAdd(ctx context.Context, in *admin.AdminEditRequest) (*admin.Response, error) {
|
||||
l := logic.NewAdminAddLogic(ctx, s.svcCtx)
|
||||
return l.AdminAdd(in)
|
||||
}
|
||||
|
||||
func (s *AdminServer) Edit(ctx context.Context, in *admin.EditRequest) (*admin.Response, error) {
|
||||
l := logic.NewEditLogic(ctx, s.svcCtx)
|
||||
return l.Edit(in)
|
||||
func (s *AdminServer) AdminEdit(ctx context.Context, in *admin.AdminEditRequest) (*admin.Response, error) {
|
||||
l := logic.NewAdminEditLogic(ctx, s.svcCtx)
|
||||
return l.AdminEdit(in)
|
||||
}
|
||||
|
||||
func (s *AdminServer) Status(ctx context.Context, in *admin.StatusRequest) (*admin.Response, error) {
|
||||
l := logic.NewStatusLogic(ctx, s.svcCtx)
|
||||
return l.Status(in)
|
||||
func (s *AdminServer) AdminStatus(ctx context.Context, in *admin.StatusRequest) (*admin.Response, error) {
|
||||
l := logic.NewAdminStatusLogic(ctx, s.svcCtx)
|
||||
return l.AdminStatus(in)
|
||||
}
|
||||
|
||||
func (s *AdminServer) Password(ctx context.Context, in *admin.PasswordRequest) (*admin.Response, error) {
|
||||
l := logic.NewPasswordLogic(ctx, s.svcCtx)
|
||||
return l.Password(in)
|
||||
}
|
||||
|
||||
func (s *AdminServer) OwnPassword(ctx context.Context, in *admin.OwnPasswordRequest) (*admin.Response, error) {
|
||||
l := logic.NewOwnPasswordLogic(ctx, s.svcCtx)
|
||||
return l.OwnPassword(in)
|
||||
}
|
||||
|
||||
func (s *AdminServer) AdminInfo(ctx context.Context, in *admin.AdminInfoRequest) (*admin.Response, error) {
|
||||
l := logic.NewAdminInfoLogic(ctx, s.svcCtx)
|
||||
return l.AdminInfo(in)
|
||||
}
|
||||
|
||||
func (s *AdminServer) AdminItems(ctx context.Context, in *admin.AdminItemsRequest) (*admin.Response, error) {
|
||||
l := logic.NewAdminItemsLogic(ctx, s.svcCtx)
|
||||
return l.AdminItems(in)
|
||||
}
|
||||
|
||||
func (s *AdminServer) AdminLogin(ctx context.Context, in *admin.AdminLoginRequest) (*admin.Response, error) {
|
||||
l := logic.NewAdminLoginLogic(ctx, s.svcCtx)
|
||||
return l.AdminLogin(in)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user