integralserver.go 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  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. }
  13. func NewIntegralServer(svcCtx *svc.ServiceContext) *IntegralServer {
  14. return &IntegralServer{
  15. svcCtx: svcCtx,
  16. }
  17. }
  18. // 收获积分
  19. func (s *IntegralServer) IntegralHarvest(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  20. l := logic.NewIntegralHarvestLogic(ctx, s.svcCtx)
  21. return l.IntegralHarvest(in)
  22. }
  23. // 消耗积分
  24. func (s *IntegralServer) IntegralConsume(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  25. l := logic.NewIntegralConsumeLogic(ctx, s.svcCtx)
  26. return l.IntegralConsume(in)
  27. }
  28. // 积分余额查询
  29. func (s *IntegralServer) IntegralBalanceCheck(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  30. l := logic.NewIntegralBalanceCheckLogic(ctx, s.svcCtx)
  31. return l.IntegralBalanceCheck(in)
  32. }
  33. // 积分明细查询
  34. func (s *IntegralServer) IntegralDetailedCheck(ctx context.Context, in *integral.Req) (*integral.RespList, error) {
  35. l := logic.NewIntegralDetailedCheckLogic(ctx, s.svcCtx)
  36. return l.IntegralDetailedCheck(in)
  37. }
  38. // 积分守护
  39. func (s *IntegralServer) IntegralGuard(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  40. l := logic.NewIntegralGuardLogic(ctx, s.svcCtx)
  41. return l.IntegralGuard(in)
  42. }
  43. // 到期积分查询
  44. func (s *IntegralServer) IntegralExpireCheck(ctx context.Context, in *integral.Req) (*integral.Resp, error) {
  45. l := logic.NewIntegralExpireCheckLogic(ctx, s.svcCtx)
  46. return l.IntegralExpireCheck(in)
  47. }