|
@@ -1,6 +1,7 @@
|
|
|
package logic
|
|
|
|
|
|
import (
|
|
|
+ "app.yhyue.com/moapp/jyMarketing/rpc/activity"
|
|
|
"context"
|
|
|
|
|
|
"app.yhyue.com/moapp/jyMarketing/api/internal/svc"
|
|
@@ -25,6 +26,18 @@ func NewAdvertisingClickLogic(ctx context.Context, svcCtx *svc.ServiceContext) A
|
|
|
|
|
|
func (l *AdvertisingClickLogic) AdvertisingClick(req types.AdvertisingReq) (*types.Response, error) {
|
|
|
// todo: add your logic here and delete this line
|
|
|
-
|
|
|
- return &types.Response{}, nil
|
|
|
+ result := &types.Response{}
|
|
|
+ lsi := l.svcCtx.Activity
|
|
|
+ resp, err := lsi.AdvertisingClick(l.ctx, &activity.AdvertisingReq{
|
|
|
+ UserID: req.UserID,
|
|
|
+ Client: req.Client,
|
|
|
+ AdvertisingID: req.AdvertisingID,
|
|
|
+ AdvertisingUrl: req.AdvertisingUrl,
|
|
|
+ })
|
|
|
+ if err != nil {
|
|
|
+ return nil, err
|
|
|
+ }
|
|
|
+ result.Code = resp.Code
|
|
|
+ result.Message = resp.Message
|
|
|
+ return result, nil
|
|
|
}
|