数据表视图 代码查询自己写在某个专栏里的博客
serviceImpl:
QueryWrapperwrapper=new QueryWrapper<>(); //从登录令牌中获取用户id String uid = JwtUtil.getAudience(request.getHeader("token")); wrapper.eq("author_id",Long.valueOf(uid)); //查询该用户的所有博客 List list=blogMapper.selectList(wrapper); //查询这个专栏里的所有博客 List blogIdList=blogMapper.filter(columnId); //过滤出符合条件的博客 List newList=list.stream().filter(s->blogIdList.contains(s.getId())).collect(Collectors.toList());
Mapper.xml:



