/
account.go
36 lines (30 loc) · 1.2 KB
/
account.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package service
import (
"context"
"github.com/go-kratos/kratos/v2/log"
"github.com/lynndotconfig/gkgo2/internal/biz"
pb "github.com/lynndotconfig/gkgo2/api/admin"
)
type AccountService struct {
pb.UnimplementedAccountServer
uc *biz.AccountUsecase
log *log.Helper
}
func NewAccountService(uc *biz.AccountUsecase, logger log.Logger) *AccountService {
return &AccountService{uc: uc, log: log.NewHelper(logger)}
}
func (s *AccountService) CreateAccount(ctx context.Context, req *pb.CreateAccountRequest) (*pb.CreateAccountReply, error) {
return &pb.CreateAccountReply{}, nil
}
func (s *AccountService) UpdateAccount(ctx context.Context, req *pb.UpdateAccountRequest) (*pb.UpdateAccountReply, error) {
return &pb.UpdateAccountReply{}, nil
}
func (s *AccountService) DeleteAccount(ctx context.Context, req *pb.DeleteAccountRequest) (*pb.DeleteAccountReply, error) {
return &pb.DeleteAccountReply{}, nil
}
func (s *AccountService) GetAccount(ctx context.Context, req *pb.GetAccountRequest) (*pb.GetAccountReply, error) {
return &pb.GetAccountReply{}, nil
}
func (s *AccountService) ListAccount(ctx context.Context, req *pb.ListAccountRequest) (*pb.ListAccountReply, error) {
return &pb.ListAccountReply{}, nil
}