53d203ee14
CI / changes (push) Successful in 14s
CI / docker-bff (push) Successful in 3s
CI / docker-product (push) Successful in 24s
CI / docker-admin (push) Has been skipped
CI / docker-user (push) Has been skipped
CI / docker-ad (push) Has been skipped
CI / docker-chore (push) Successful in 25s
CI / docker-express (push) Has been skipped
CI / docker-sale (push) Successful in 26s
51 lines
1.3 KiB
Go
51 lines
1.3 KiB
Go
// Code generated by goctl. DO NOT EDIT.
|
|
// goctl 1.10.1
|
|
// Source: chore.proto
|
|
|
|
package server
|
|
|
|
import (
|
|
"context"
|
|
|
|
"lone-services/rpc/chore/pb"
|
|
"lone-services/services/chore/internal/logic"
|
|
"lone-services/services/chore/internal/svc"
|
|
)
|
|
|
|
type ChoreServer struct {
|
|
svcCtx *svc.ServiceContext
|
|
chore.UnimplementedChoreServer
|
|
}
|
|
|
|
func NewChoreServer(svcCtx *svc.ServiceContext) *ChoreServer {
|
|
return &ChoreServer{
|
|
svcCtx: svcCtx,
|
|
}
|
|
}
|
|
|
|
func (s *ChoreServer) Policy(ctx context.Context, in *chore.PolicyReq) (*chore.Response, error) {
|
|
l := logic.NewPolicyLogic(ctx, s.svcCtx)
|
|
return l.Policy(in)
|
|
}
|
|
|
|
func (s *ChoreServer) Test(ctx context.Context, in *chore.TestReq) (*chore.Response, error) {
|
|
l := logic.NewTestLogic(ctx, s.svcCtx)
|
|
return l.Test(in)
|
|
}
|
|
|
|
func (s *ChoreServer) DecryptMobile(ctx context.Context, in *chore.DecryptMobileReq) (*chore.Response, error) {
|
|
l := logic.NewDecryptMobileLogic(ctx, s.svcCtx)
|
|
return l.DecryptMobile(in)
|
|
}
|
|
|
|
func (s *ChoreServer) Regions(ctx context.Context, in *chore.RegionsReq) (*chore.Response, error) {
|
|
l := logic.NewRegionsLogic(ctx, s.svcCtx)
|
|
return l.Regions(in)
|
|
}
|
|
|
|
// 服务间调用:按 id 批量查地区名称
|
|
func (s *ChoreServer) RegionsByIds(ctx context.Context, in *chore.RegionsByIdsReq) (*chore.RegionsByIdsData, error) {
|
|
l := logic.NewRegionsByIdsLogic(ctx, s.svcCtx)
|
|
return l.RegionsByIds(in)
|
|
}
|