新增发帖达人页面
This commit is contained in:
parent
d7ad5d7e25
commit
84c89d95bc
@ -332,6 +332,9 @@ public class AppUserServiceImpl extends ServiceImpl<AppUserDao, AppUserEntity> i
|
|||||||
DateTime month = cn.hutool.core.date.DateUtil.beginOfMonth(new Date());
|
DateTime month = cn.hutool.core.date.DateUtil.beginOfMonth(new Date());
|
||||||
|
|
||||||
List<PostEntity> postList = postService.lambdaQuery().gt(PostEntity::getCreateTime, month).list();
|
List<PostEntity> postList = postService.lambdaQuery().gt(PostEntity::getCreateTime, month).list();
|
||||||
|
if(postList.isEmpty()){
|
||||||
|
return new ArrayList<>();
|
||||||
|
}
|
||||||
Map<Integer, Long> collect = postList.stream().collect(Collectors.groupingBy(PostEntity::getUid, Collectors.counting()));
|
Map<Integer, Long> collect = postList.stream().collect(Collectors.groupingBy(PostEntity::getUid, Collectors.counting()));
|
||||||
Map<Integer, Long> sorted = collect
|
Map<Integer, Long> sorted = collect
|
||||||
.entrySet()
|
.entrySet()
|
||||||
|
@ -117,6 +117,13 @@ public class AppUserInfoController {
|
|||||||
return R.ok().put("result", response);
|
return R.ok().put("result", response);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Login
|
||||||
|
@PostMapping("/cancelFollow")
|
||||||
|
@ApiOperation("取消关注用户")
|
||||||
|
public R cancelFollow(@LoginUser AppUserEntity user, @RequestBody AddFollowForm request) {
|
||||||
|
appUserService.cancelFollow(request, user);
|
||||||
|
return R.ok("取消关注用户成功");
|
||||||
|
}
|
||||||
|
|
||||||
@Login
|
@Login
|
||||||
@PostMapping("/userInfoEdit")
|
@PostMapping("/userInfoEdit")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user