package logic import ( "context" "app.yhyue.com/moapp/jyPoints/rpc/integral" "app.yhyue.com/moapp/jyPoints/api/internal/svc" "app.yhyue.com/moapp/jyPoints/api/internal/types" "github.com/tal-tech/go-zero/core/logx" ) type IntegralExpireCheckLogic struct { logx.Logger ctx context.Context svcCtx *svc.ServiceContext } func NewIntegralExpireCheckLogic(ctx context.Context, svcCtx *svc.ServiceContext) IntegralExpireCheckLogic { return IntegralExpireCheckLogic{ Logger: logx.WithContext(ctx), ctx: ctx, svcCtx: svcCtx, } } func (l *IntegralExpireCheckLogic) IntegralExpireCheck(req types.ExpireReq) (*types.Response, error) { // todo: add your logic here and delete this line result := &types.Response{} lsi := l.svcCtx.Integral resp, err := lsi.IntegralExpireCheck(l.ctx, &integral.Req{ UserId: req.UserId, AppId: req.AppId, EndDate: req.EndDate, }) if err != nil { return nil, err } result.Code = resp.Code result.Data = resp.Data result.Message = resp.Message return result, nil }