禅道bug修复
This commit is contained in:
parent
ad660eac9c
commit
ad48a195c3
|
|
@ -154,4 +154,15 @@ public class PitfallDelayApprovalVo extends BaseBean {
|
|||
*/
|
||||
private String peoId;
|
||||
|
||||
/**
|
||||
* 当前审批人id
|
||||
*/
|
||||
private String checkUserId;
|
||||
|
||||
private String examineType;
|
||||
|
||||
private Integer auditStatus;
|
||||
|
||||
private String isActive;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -557,7 +557,7 @@ public class FlowTaskUtils extends FlowServiceFactory {
|
|||
.taskAssignee(userId)
|
||||
.singleResult();
|
||||
if (Objects.isNull(task)) {
|
||||
return AjaxResult.error("任务不存在,当前审核流程已结束,请先退出刷新列表!");
|
||||
return AjaxResult.error("不在当前审核节点!");
|
||||
}
|
||||
boolean tf = false;
|
||||
String id = "";
|
||||
|
|
|
|||
|
|
@ -165,7 +165,7 @@ public class OutsourcingProController extends BaseController {
|
|||
}
|
||||
@PostMapping("/exportSupervisorPerson")
|
||||
@SysLog(title = "工程管理", businessType = OperaType.EXPORT,logType = 0,module = "工程管理->外委外包工程",details = "导出监理人员基本信息")
|
||||
public void exportSupervisorPerson(HttpServletResponse response, SupervisorPerson supervisorPerson) {
|
||||
public void exportSupervisorPerson(HttpServletResponse response,@RequestBody SupervisorPerson supervisorPerson) {
|
||||
try{
|
||||
List<SupervisorPerson> list = service.listSupervisorPerson(supervisorPerson);
|
||||
for (SupervisorPerson person : list) {
|
||||
|
|
|
|||
|
|
@ -318,4 +318,10 @@ public interface SecurityCheckMapper {
|
|||
int withdrawalOfExtension(String id);
|
||||
|
||||
int updateHiddenDangerRectification2(NewHiddenDangerDto dto);
|
||||
|
||||
String getThisCheckUser(String taskId);
|
||||
|
||||
List<PitfallDelayApprovalVo> approvalHistoryUser(String taskId);
|
||||
|
||||
List<String> getThisCheckUserStatus(String taskId);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -239,7 +239,8 @@ public class AdmissionRequestServiceImpl implements AdmissionRequestService {
|
|||
}
|
||||
//查询是否在其他工程 已入场
|
||||
AdmissionRequest proUser = arMapper.getUserInToPro(bean);
|
||||
if(proUser!=null){
|
||||
//如果是承包商负责人允许入多个工程
|
||||
if(proUser!=null && !"0".equals(proUser.getPost())){
|
||||
if(!"3".equals(proUser.getOutStatus())){
|
||||
return new AjaxResult(201,"该人员已在其他工程入场,请先出场后再入场");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -782,9 +782,90 @@ public class SecurityCheckServiceImpl implements SecurityCheckService {
|
|||
data.setFinalCheck(checkMaps.get(data.getProcInsId()));
|
||||
}
|
||||
});
|
||||
|
||||
//判断当前节点是谁审批
|
||||
for (PitfallDelayApprovalVo pitfallDelayApprovalVo:list) {
|
||||
if (pitfallDelayApprovalVo.getTaskId()!=null){
|
||||
List<PitfallDelayApprovalVo> pitfallDelayApprovalVoList = mapper.approvalHistoryUser(pitfallDelayApprovalVo.getTaskId());
|
||||
for (PitfallDelayApprovalVo PitfallDelayApprovalVo:pitfallDelayApprovalVoList ) {
|
||||
if ("4".equals(PitfallDelayApprovalVo.getAuditStatus())){
|
||||
pitfallDelayApprovalVo.setCheckUserId(PitfallDelayApprovalVo.getUserId());
|
||||
}
|
||||
}
|
||||
approvalHistoryUser(pitfallDelayApprovalVo);
|
||||
String userId = mapper.getThisCheckUser(pitfallDelayApprovalVo.getTaskId());
|
||||
pitfallDelayApprovalVo.setCheckUserId(userId);
|
||||
}
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
public List<PitfallDelayApprovalVo> approvalHistoryUser(PitfallDelayApprovalVo pitfallDelayApprovalVo) {
|
||||
List<PitfallDelayApprovalVo> pitfallDelayApprovalVoList = mapper.approvalHistoryUser(pitfallDelayApprovalVo.getTaskId());
|
||||
List<PitfallDelayApprovalVo> finalList = new ArrayList<>();
|
||||
for (PitfallDelayApprovalVo bean : pitfallDelayApprovalVoList) {
|
||||
List<String> ss = Arrays.asList(bean.getUserId().split(","));
|
||||
String examineType = bean.getExamineType();
|
||||
if ("0".equals(examineType)) {
|
||||
for (int i = 0; i < ss.size(); i++) {
|
||||
PitfallDelayApprovalVo newBean = new PitfallDelayApprovalVo();
|
||||
newBean.setId(bean.getId());
|
||||
newBean.setAuditStatus(bean.getAuditStatus());
|
||||
newBean.setTaskId(bean.getTaskId());
|
||||
newBean.setExamineType(bean.getExamineType());
|
||||
newBean.setCreateTime(bean.getCreateTime());
|
||||
newBean.setUserId(ss.get(i));
|
||||
finalList.add(newBean);
|
||||
}
|
||||
} else {
|
||||
PitfallDelayApprovalVo newBean = new PitfallDelayApprovalVo();
|
||||
newBean.setId(bean.getId());
|
||||
newBean.setAuditStatus(bean.getAuditStatus());
|
||||
newBean.setTaskId(bean.getTaskId());
|
||||
newBean.setExamineType(bean.getExamineType());
|
||||
newBean.setCreateTime(bean.getCreateTime());
|
||||
newBean.setUserId(bean.getUserId());
|
||||
finalList.add(newBean);
|
||||
}
|
||||
|
||||
}
|
||||
String userId = mapper.getThisCheckUser(pitfallDelayApprovalVo.getTaskId());
|
||||
if (userId != null) {
|
||||
for (PitfallDelayApprovalVo bb : finalList) {
|
||||
String users = bb.getUserId();
|
||||
if (users != null && Arrays.asList(users.split(",")).contains(userId)) {
|
||||
bb.setIsActive("1");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
List<String> types = mapper.getThisCheckUserStatus(pitfallDelayApprovalVo.getTaskId());
|
||||
if (StringUtils.isNotEmpty(types)) {
|
||||
finalList.get(0).setType(types.get(0));
|
||||
}
|
||||
finalList.get(0).setIsActive("10");
|
||||
}
|
||||
|
||||
boolean isBh=true;
|
||||
for (PitfallDelayApprovalVo configurationVo : finalList) {
|
||||
if (configurationVo.getAuditStatus() !=null) {
|
||||
if (configurationVo.getAuditStatus() == 2) {
|
||||
isBh = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if(isBh){
|
||||
for (PitfallDelayApprovalVo configurationVo : finalList) {
|
||||
if(configurationVo.getAuditStatus() ==null){
|
||||
configurationVo.setAuditStatus(4);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return finalList;
|
||||
}
|
||||
|
||||
// @Override
|
||||
// public List<PitfallDelayApprovalVo> getReviewOfDeferredApprovalList(SecurityCheckDto dto) {
|
||||
// List<PitfallDelayApprovalVo> list = mapper.getReviewOfDeferredApprovalList(dto);
|
||||
|
|
|
|||
|
|
@ -543,7 +543,8 @@
|
|||
ypi.delay_reject_reason AS delayRejectReason,
|
||||
ypi.is_delay AS isDelayCheck,
|
||||
ypi.rejection_delay AS rejectionDelay,
|
||||
ypd.delay_reason AS delayReason
|
||||
ypd.delay_reason AS delayReason,
|
||||
ypd.user_id As userId
|
||||
FROM yh_pitfall_info ypi
|
||||
LEFT JOIN yh_pitfall_detaills ypd ON ypi.pitfall_id = ypd.pitfall_id
|
||||
LEFT JOIN sys_dict_data sdd
|
||||
|
|
@ -625,4 +626,20 @@
|
|||
AND is_active = 1) AS total_counts;
|
||||
|
||||
</select>
|
||||
<select id="getThisCheckUser" resultType="java.lang.String">
|
||||
select ASSIGNEE_ as userId from nxdt_flowable.act_ru_task where PROC_INST_ID_ =(
|
||||
select proc_ins_id from pt_check_task where task_id = #{taskId}
|
||||
) LIMIT 1
|
||||
</select>
|
||||
<select id="approvalHistoryUser" resultType="com.bonus.common.safetycheck.PitfallDelayApprovalVo">
|
||||
select distinct a.id ,a.task_id as taskId,a.user_id as userId,a.exam_type as examineType,
|
||||
b.audit_status as auditStatus
|
||||
from pt_check_person a
|
||||
left join pt_check_person_remark b on a.task_id = b.task_id and a.user_id = b.user_id and a.version = b.version
|
||||
where a.type= '2' and a.task_id = #{taskId}
|
||||
</select>
|
||||
<select id="getThisCheckUserStatus" resultType="java.lang.String">
|
||||
select task_type
|
||||
from pt_check_task where task_id = #{taskId}
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
|
|||
|
|
@ -452,6 +452,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
SELECT pcp.cons_name AS consName,
|
||||
pcp.id_card AS idCard,
|
||||
pcp.cons_user_id as id,
|
||||
pcp.post AS post,
|
||||
lcp.uuid,lcp.out_status outStatus
|
||||
FROM pt_cons_person pcp
|
||||
LEFT JOIN lk_cont_person lcp ON lcp.cons_persion_id = pcp.cons_user_id
|
||||
|
|
|
|||
Loading…
Reference in New Issue