integralserver.go 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. // Code generated by goctl. DO NOT EDIT.
  2. // Source: integral.proto
  3. package server
  4. import (
  5. "context"
  6. "app.yhyue.com/moapp/jyPoints/rpc/integral"
  7. "app.yhyue.com/moapp/jyPoints/rpc/internal/logic"
  8. "app.yhyue.com/moapp/jyPoints/rpc/internal/svc"
  9. )
  10. type IntegralServer struct {
  11. svcCtx *svc.ServiceContext
  12. integral.UnimplementedIntegralServer
  13. }
  14. func NewIntegralServer(svcCtx *svc.ServiceContext) *IntegralServer {
  15. return &IntegralServer{
  16. svcCtx: svcCtx,
  17. }
  18. }
  19. // 收获积分
  20. func (s *IntegralServer) IntegralHarvest(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  21. l := logic.NewIntegralHarvestLogic(ctx, s.svcCtx)
  22. return l.IntegralHarvest(in)
  23. }
  24. // 消耗积分
  25. func (s *IntegralServer) IntegralConsume(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  26. l := logic.NewIntegralConsumeLogic(ctx, s.svcCtx)
  27. return l.IntegralConsume(in)
  28. }
  29. // 积分余额查询
  30. func (s *IntegralServer) IntegralBalanceCheck(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  31. l := logic.NewIntegralBalanceCheckLogic(ctx, s.svcCtx)
  32. return l.IntegralBalanceCheck(in)
  33. }
  34. // 积分明细查询
  35. func (s *IntegralServer) IntegralDetailedCheck(ctx context.Context, in *integral.Req) (*integral.RespList, error) {
  36. l := logic.NewIntegralDetailedCheckLogic(ctx, s.svcCtx)
  37. return l.IntegralDetailedCheck(in)
  38. }
  39. // 积分守护
  40. func (s *IntegralServer) IntegralGuard(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  41. l := logic.NewIntegralGuardLogic(ctx, s.svcCtx)
  42. return l.IntegralGuard(in)
  43. }
  44. // 到期积分查询
  45. func (s *IntegralServer) IntegralExpireCheck(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  46. l := logic.NewIntegralExpireCheckLogic(ctx, s.svcCtx)
  47. return l.IntegralExpireCheck(in)
  48. }
  49. // 合并账号
  50. func (s *IntegralServer) UserMerge(ctx context.Context, in *integral.MergeInfo) (*integral.Resp, error) {
  51. l := logic.NewUserMergeLogic(ctx, s.svcCtx)
  52. return l.UserMerge(in)
  53. }