|
@@ -152,6 +152,7 @@ public class TaBuildingDynamicServiceImpl extends ServiceImpl<TaBuildingDynamicM
|
152
|
152
|
|
153
|
153
|
// 活动海报
|
154
|
154
|
buildingDynamic.setPosters(taPosterService.getPostersForTarget(buildingDynamic.getDynamicId(), CommConstant.POSTER_CONTENT_TYPE_ACTIVITY));
|
|
155
|
+ buildingDynamic.setShareContents(taShareContentService.getPostersForTarget(buildingDynamic.getDynamicId(), CommConstant.POSTER_CONTENT_TYPE_ACTIVITY));
|
155
|
156
|
|
156
|
157
|
return ResponseBean.success(buildingDynamic);
|
157
|
158
|
}
|
|
@@ -338,21 +339,28 @@ public class TaBuildingDynamicServiceImpl extends ServiceImpl<TaBuildingDynamicM
|
338
|
339
|
empty.orderBy(true,false,"start_date");
|
339
|
340
|
IPage<TaBuildingDynamic> result = buildingDynamicMapper.selectPage(page,empty);
|
340
|
341
|
for(int i=0;i<result.getRecords().size();i++){
|
341
|
|
- result.getRecords().get(i).setIsSign(CommConstant.STATUS_NORMAL);
|
|
342
|
+ TaBuildingDynamic taBuildingDynamic = result.getRecords().get(i);
|
|
343
|
+ taBuildingDynamic.setIsSign(CommConstant.STATUS_NORMAL);
|
342
|
344
|
// 获取报名总数
|
343
|
345
|
QueryWrapper<TaActivityDynamicEnlist> taActivityDynamicEnlist = new QueryWrapper<>();
|
344
|
346
|
taActivityDynamicEnlist.eq("dynamic_id", result.getRecords().get(i).getDynamicId());
|
345
|
347
|
taActivityDynamicEnlist.eq("building_id", result.getRecords().get(i).getBuildingId());
|
346
|
348
|
int applyCount= taActivityDynamicEnlistMapper.selectCount(taActivityDynamicEnlist);
|
347
|
|
- result.getRecords().get(i).setCount(applyCount);
|
|
349
|
+ taBuildingDynamic.setCount(applyCount);
|
348
|
350
|
|
349
|
351
|
// 是否收藏
|
350
|
352
|
TaSave taSave = iTaSaveService.getInfoBy(person.getPersonId(), CommConstant.FAVOR_ACTIVITY, result.getRecords().get(i).getDynamicId());
|
351
|
353
|
if (null == taSave) {
|
352
|
|
- result.getRecords().get(i).setIsSaved(0);
|
|
354
|
+ taBuildingDynamic.setIsSaved(0);
|
353
|
355
|
} else {
|
354
|
|
- result.getRecords().get(i).setIsSaved(1);
|
|
356
|
+ taBuildingDynamic.setIsSaved(1);
|
355
|
357
|
}
|
|
358
|
+
|
|
359
|
+ // 获取海报图 和 分享图
|
|
360
|
+ taBuildingDynamic.setPosters(taPosterService.getPostersForTarget(taBuildingDynamic.getDynamicId(), CommConstant.POSTER_CONTENT_TYPE_ACTIVITY));
|
|
361
|
+ taBuildingDynamic.setShareContents(taShareContentService.getPostersForTarget(taBuildingDynamic.getDynamicId(), CommConstant.POSTER_CONTENT_TYPE_ACTIVITY));
|
|
362
|
+
|
|
363
|
+
|
356
|
364
|
}
|
357
|
365
|
return result;
|
358
|
366
|
}else {
|