|
@@ -11,6 +11,7 @@ import com.huaxu.process.entity.ProcessDefinition;
|
|
import com.huaxu.process.service.WorkFlowService;
|
|
import com.huaxu.process.service.WorkFlowService;
|
|
import com.huaxu.task.dto.PlanManageDto;
|
|
import com.huaxu.task.dto.PlanManageDto;
|
|
import com.huaxu.task.entity.PlanManage;
|
|
import com.huaxu.task.entity.PlanManage;
|
|
|
|
+import com.huaxu.task.entity.UserEntity;
|
|
import com.huaxu.task.service.PlanManageService;
|
|
import com.huaxu.task.service.PlanManageService;
|
|
import com.huaxu.util.DatesUtil;
|
|
import com.huaxu.util.DatesUtil;
|
|
import com.huaxu.util.UserUtil;
|
|
import com.huaxu.util.UserUtil;
|
|
@@ -119,7 +120,7 @@ public class PlanManageController {
|
|
IPage<PlanManageDto> iPage = new Page<>(pageNum, pageSize);
|
|
IPage<PlanManageDto> iPage = new Page<>(pageNum, pageSize);
|
|
iPage = planManageService.selectPage(iPage, planManageDto);
|
|
iPage = planManageService.selectPage(iPage, planManageDto);
|
|
Pagination<PlanManageDto> pages = new Pagination<>(iPage);
|
|
Pagination<PlanManageDto> pages = new Pagination<>(iPage);
|
|
- setUserName(pages);
|
|
|
|
|
|
+ //setUserName(pages);
|
|
return new AjaxMessage<>(ResultStatus.OK, pages);
|
|
return new AjaxMessage<>(ResultStatus.OK, pages);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -147,10 +148,28 @@ public class PlanManageController {
|
|
IPage<PlanManageDto> iPage = new Page<>(pageNum, pageSize);
|
|
IPage<PlanManageDto> iPage = new Page<>(pageNum, pageSize);
|
|
iPage = planManageService.selectPage(iPage, planManageDto);
|
|
iPage = planManageService.selectPage(iPage, planManageDto);
|
|
Pagination<PlanManageDto> pages = new Pagination<>(iPage);
|
|
Pagination<PlanManageDto> pages = new Pagination<>(iPage);
|
|
- setUserName(pages);
|
|
|
|
|
|
+ //setUserName(pages);
|
|
return new AjaxMessage<>(ResultStatus.OK, pages);
|
|
return new AjaxMessage<>(ResultStatus.OK, pages);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ @GetMapping("/plan/pending/power")
|
|
|
|
+ @ApiOperation(value = "待处理权限")
|
|
|
|
+ public AjaxMessage<Boolean> selectPendingPower(
|
|
|
|
+ @ApiParam(value = "任务ID", required = true) @RequestParam(required = true) Integer id){
|
|
|
|
+ String currentUsers = null;
|
|
|
|
+ LoginUser loginUser = UserUtil.getCurrentUser();
|
|
|
|
+ if(loginUser.getId() != null) {
|
|
|
|
+ currentUsers = String.format("%s,", loginUser.getId());
|
|
|
|
+ }
|
|
|
|
+ Map<String,Object> map = new HashMap<String,Object>();
|
|
|
|
+ map.put("id",id);
|
|
|
|
+ map.put("currentUsers",currentUsers);
|
|
|
|
+ int rows = planManageService.selectPendingPower(map);
|
|
|
|
+ if(rows>0){
|
|
|
|
+ new AjaxMessage<Boolean>(ResultStatus.OK, true);
|
|
|
|
+ }
|
|
|
|
+ return new AjaxMessage<Boolean>(ResultStatus.OK, false);
|
|
|
|
+ }
|
|
|
|
|
|
/**
|
|
/**
|
|
* APP查询任务详情
|
|
* APP查询任务详情
|
|
@@ -276,9 +295,9 @@ public class PlanManageController {
|
|
for( int i =0 ;i<idList.size(); i++){
|
|
for( int i =0 ;i<idList.size(); i++){
|
|
ids[i] = idList.get(i);
|
|
ids[i] = idList.get(i);
|
|
}
|
|
}
|
|
- Map<Long, String> userMap = userCenterClient.findUserIdsByUserIds(ids);
|
|
|
|
|
|
+ List<UserEntity> userMap = userCenterClient.findUserIdsByUserIds(ids);
|
|
for (PlanManage plan : pages.getList()) {
|
|
for (PlanManage plan : pages.getList()) {
|
|
- for (Map.Entry<Long, String> entry : userMap.entrySet()) {
|
|
|
|
|
|
+ /* for (Map.Entry<Long, String> entry : userMap.entrySet()) {
|
|
if(plan.getUserId() != null) {
|
|
if(plan.getUserId() != null) {
|
|
if(entry.getKey()== Long.parseLong(plan.getUserId())){
|
|
if(entry.getKey()== Long.parseLong(plan.getUserId())){
|
|
plan.setUserName(entry.getValue());
|
|
plan.setUserName(entry.getValue());
|
|
@@ -298,8 +317,8 @@ public class PlanManageController {
|
|
if(entry.getKey()== Long.parseLong(plan.getUpdateBy())){
|
|
if(entry.getKey()== Long.parseLong(plan.getUpdateBy())){
|
|
plan.setUpdateByName(entry.getValue());
|
|
plan.setUpdateByName(entry.getValue());
|
|
}
|
|
}
|
|
- }
|
|
|
|
- }
|
|
|
|
|
|
+ }*/
|
|
|
|
+ // }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|