|
@@ -31,16 +31,16 @@ func (l *DocActivityLogic) DocActivity(in *stdlib.DocActivityReq) (*stdlib.DocAc
|
|
|
pageNum = 0
|
|
|
}
|
|
|
res, count := stdlibService.DocActivityList(int(in.PageSize), pageNum)
|
|
|
- docActivityResp := &stdlib.DocActivityResp{Code: 0, Msg: "ok", Total: count}
|
|
|
+ docActivityResp := &stdlib.DocActivityResp{Code: 0, Msg: "ok", Total: int32(count)}
|
|
|
for _, v := range res {
|
|
|
docActivityResp.Docs = append(docActivityResp.Docs, &stdlib.DocActivity{
|
|
|
- DocId: res.DocId,
|
|
|
- DocImg: res.DocImg,
|
|
|
- DocTitle: res.DocTitle,
|
|
|
- DocSummary: res.DocSummary,
|
|
|
- ActivityId: res.ActivityId,
|
|
|
- Price: res.Price,
|
|
|
- CostPrice: res.CostPrice,
|
|
|
+ DocId: v.DocId,
|
|
|
+ DocImg: v.DocImg,
|
|
|
+ DocTitle: v.DocTitle,
|
|
|
+ DocSummary: v.DocSummary,
|
|
|
+ ActivityId: int32(v.ActivityId),
|
|
|
+ Price: int32(v.Price),
|
|
|
+ CostPrice: int32(v.CostPrice),
|
|
|
})
|
|
|
}
|
|
|
return docActivityResp, nil
|