Compare commits

..

No commits in common. "f29c01640536a60b59d62ddd2e6a0bc74b6b3052" and "f5259a3526289b5aef5e57a3d06feccd522e84cf" have entirely different histories.

4 changed files with 9 additions and 10 deletions

View File

@ -109,10 +109,10 @@ public class ProjectDAO {
log.info("\t> 执行 DAO 层 ProjectDAO.get 方法");
log.info("\t\t> 从 MySQL 获取数据");
if(isFinish != null){
return projectMapper.getByIsfinish(userId,isFinish);
return projectMapper.getByIsfinish(isFinish);
}
if(tags != null && !tags.isEmpty()){
return projectMapper.getByTags(userId,tags);
return projectMapper.getByTags(tags);
}
if(listAll == 0) {
return projectMapper.get(userId);

View File

@ -43,15 +43,15 @@ public interface ProjectMapper {
//@Select("select * from organize_oa.oa_project where json_extract(tags,'$.tags')" +
//"like concat('%',#{tags},'%')")
@Select("select * from organize_oa.oa_project where is_finish=#{isFinish} and is_delete=false and principal_id =#{userId}")
List<ProjectDO>getByIsfinish(Long userId,Integer isFinish);
@Select("select * from organize_oa.oa_project where is_finish=#{isFinish} and is_delete=false")
List<ProjectDO>getByIsfinish(Integer isFinish);
List<ProjectDO>getByTags(Long userId,List<String> tags);
List<ProjectDO>getByTags(List<String> tags);
@Select("select * from organize_oa.oa_project where is_delete=false and status =1 and principal_id=#{userId}")
@Select("select * from organize_oa.oa_project where is_delete=false and status =1")
List<ProjectDO> get(Long userId);
@Select("select * from organize_oa.oa_project where status =1 and status=1 and principal_id=#{userId}")
@Select("select * from organize_oa.oa_project where status =1 and status=1")
List<ProjectDO> get1(Long userId);
@Select("select * from organize_oa.oa_project where name=#{name}")

View File

@ -204,8 +204,7 @@ public class ProjectServiceImpl implements ProjectService {
List<ProjectDO> projectDOList = projectDAO.get(userId,listAll,tags,isFinish);
return ResultUtil.success(projectDOList);
}else {
listAll = 0;
List<ProjectDO> projectDOList = projectDAO.get(userId,listAll,tags,isFinish);
List<ProjectDO> projectDOList = projectDAO.get(userId,0,tags,isFinish);
return ResultUtil.success(projectDOList);
}

View File

@ -51,7 +51,7 @@
select * from organize_oa.oa_project where
<foreach collection="tags" item="tag" separator=",'%') and json_extract(tags,'$.tags')like concat('%',"
open="json_extract(tags,'$.tags')like concat('%',"
close=",'%') and is_delete=false and principal_id=#{userId}">
close=",'%') and is_delete=false">
#{tag}
</foreach>
</select>