Commit 4ecafe1b by hzc

增加下发人查询条件

parent 3dbb0ca3
...@@ -43,23 +43,20 @@ public class ShortboardTaskCtrl { ...@@ -43,23 +43,20 @@ public class ShortboardTaskCtrl {
PageRequest request= PageRequest.of(shortboardParam.getPage()-1,shortboardParam.getSize()); PageRequest request= PageRequest.of(shortboardParam.getPage()-1,shortboardParam.getSize());
shortboardParam.setOffset(request.getOffset()); shortboardParam.setOffset(request.getOffset());
List<ShortBoardTask> lists = new ArrayList<>(); List<ShortBoardTask> lists = new ArrayList<>();
if(StringUtils.isNotBlank(shortboardParam.getUserId())){ if(StringUtils.isNotBlank(shortboardParam.getUserId())){
//userId不为空 //userId不为空
String currentUserId = SystemUserUtil.getCurrentUserId(); String currentUserId = SystemUserUtil.getCurrentUserId();
shortboardParam.setUserId(currentUserId); shortboardParam.setUserId(currentUserId);
} }
long count = shortboardTaskService.selectCountByParam(shortboardParam); long count = shortboardTaskService.selectCountByParam(shortboardParam);
if(count>0){ if(count>0){
lists= shortboardTaskService.selectPageByParam(shortboardParam); lists= shortboardTaskService.selectPageByParam(shortboardParam);
} }
String message = SystemUserUtil.getCurrentUser()+"查找了我的检查改善措施 "; // String message = SystemUserUtil.getCurrentUser()+"查找了我的检查改善措施 ";
if(shortboardParam.getStatusArr().length==2){ // if(shortboardParam.getStatusArr().length==2){
message = SystemUserUtil.getCurrentUser()+"查找了我的短板任务清单 "; // message = SystemUserUtil.getCurrentUser()+"查找了我的短板任务清单或者检查改善措施 ";
} // }
// LogManager.logInfo(Constants.LOG_INDICATOR_SHORTBOARD_TASK_API,message);
LogManager.logInfo(Constants.LOG_INDICATOR_SHORTBOARD_TASK_API,message);
return new PageImpl<>(lists,request,count); return new PageImpl<>(lists,request,count);
} }
......
...@@ -24,4 +24,6 @@ public class ShortboardParam { ...@@ -24,4 +24,6 @@ public class ShortboardParam {
private Integer unitId; private Integer unitId;
@ApiModelProperty("用户id") @ApiModelProperty("用户id")
private String userId; private String userId;
@ApiModelProperty("下发人id")
private String createUserId;
} }
...@@ -70,6 +70,9 @@ ...@@ -70,6 +70,9 @@
<if test="userId !=null and userId != ''"> <if test="userId !=null and userId != ''">
and sbt.enter_user_id like concat('%,',#{userId},',%') and sbt.enter_user_id like concat('%,',#{userId},',%')
</if> </if>
<if test="createUserId !=null and createUserId!=''">
and sbt.createUser_id = #{createUserId}
</if>
</sql> </sql>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment