bug修改
This commit is contained in:
parent
a3b788d1a9
commit
870c277a9e
|
|
@ -87,6 +87,8 @@ public class RequestEntity implements Serializable {
|
|||
*/
|
||||
private String sort;
|
||||
|
||||
private String dataType;
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -12,16 +12,31 @@ import javax.naming.ldap.PagedResultsControl;
|
|||
public class CheckComment {
|
||||
|
||||
private String id;
|
||||
|
||||
private String userId;
|
||||
|
||||
private String name;
|
||||
|
||||
private String section;
|
||||
|
||||
private String turnDownReason;
|
||||
|
||||
private String reason;
|
||||
|
||||
private String time;
|
||||
|
||||
private String taskId;
|
||||
|
||||
private String status;
|
||||
|
||||
private String examType;
|
||||
|
||||
private String sort;
|
||||
|
||||
private Integer agree;
|
||||
|
||||
private String version;
|
||||
|
||||
private String auditStatus;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -498,4 +498,11 @@ public interface BusinessMapper {
|
|||
void deleteCheckRemark(String taskId);
|
||||
|
||||
List<CheckComment> checkHistory(RequestEntity entity);
|
||||
|
||||
/**
|
||||
* 查询树结构数据
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
List<CheckComment> getTreeList(RequestEntity entity);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,6 +18,7 @@ import com.bonus.flowable.service.BusinessService;
|
|||
import com.bonus.system.api.RemoteUserService;
|
||||
import com.bonus.system.api.domain.SysUser;
|
||||
import com.bonus.system.api.model.LoginUser;
|
||||
import liquibase.pro.packaged.C;
|
||||
import liquibase.pro.packaged.E;
|
||||
import liquibase.pro.packaged.M;
|
||||
import liquibase.pro.packaged.S;
|
||||
|
|
@ -52,7 +53,7 @@ public class BusinessServiceImpl implements BusinessService {
|
|||
@Override
|
||||
public AjaxResult submitApproval(AuditTask auditTask) {
|
||||
String taskId = null;
|
||||
if (StringUtils.isBlank(auditTask.getTaskId())) {
|
||||
if (StringUtils.isNotEmpty(auditTask.getTaskId())) {
|
||||
//任务id
|
||||
taskId = auditTask.getTaskId();
|
||||
}
|
||||
|
|
@ -826,6 +827,7 @@ public class BusinessServiceImpl implements BusinessService {
|
|||
for (int i = 0; i < stringArray.length; i++) {
|
||||
ConfigurationVo newBean = new ConfigurationVo();
|
||||
newBean.setId(bean.getId());
|
||||
newBean.setAuditStatus(bean.getAuditStatus());
|
||||
newBean.setExamineId(bean.getExamineId());
|
||||
newBean.setTaskId(bean.getTaskId());
|
||||
newBean.setNodeName(bean.getNodeName());
|
||||
|
|
@ -960,7 +962,59 @@ public class BusinessServiceImpl implements BusinessService {
|
|||
|
||||
@Override
|
||||
public List<CheckComment> checkHistory(RequestEntity entity) {
|
||||
return mapper.checkHistory(entity);
|
||||
List<CheckComment> list=new ArrayList<>();
|
||||
try{
|
||||
List<CheckComment> treeList=mapper.getTreeList(entity);
|
||||
RequestEntity re=new RequestEntity();
|
||||
re.setTaskId(entity.getTaskId());
|
||||
for (CheckComment vo:treeList){
|
||||
re.setVision(vo.getVersion());
|
||||
String userId=vo.getUserId();
|
||||
List<String> userIds=Arrays.asList(userId.split(","));
|
||||
//审核通过的
|
||||
if("1".equals(vo.getAuditStatus())){
|
||||
if("2".equals(vo.getExamType())){
|
||||
re.setVision(vo.getVersion());
|
||||
re.setDataType("5");
|
||||
for (String id:userIds){
|
||||
if(StringUtils.isNotEmpty(id)){
|
||||
re.setUserId(id);
|
||||
List<CheckComment> childList=mapper.checkHistory(re);
|
||||
if(StringUtils.isNotEmpty(childList)){
|
||||
list.addAll(childList);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}else{
|
||||
for (String id:userIds){
|
||||
if(StringUtils.isNotEmpty(id)){
|
||||
re.setUserId(id);
|
||||
re.setDataType("");
|
||||
List<CheckComment> childList=mapper.checkHistory(re);
|
||||
if(StringUtils.isNotEmpty(childList)){
|
||||
list.addAll(childList);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
for (String id:userIds){
|
||||
if(StringUtils.isNotEmpty(id)){
|
||||
re.setUserId(id);
|
||||
re.setDataType("");
|
||||
List<CheckComment> childList=mapper.checkHistory(re);
|
||||
if(StringUtils.isNotEmpty(childList)){
|
||||
list.addAll(childList);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}catch (Exception e){
|
||||
log.error(e.toString(),e);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -840,11 +840,27 @@
|
|||
LEFT JOIN nxdt_ii.pt_check_person_remark pcpr ON pcp.task_id = pcpr.task_id
|
||||
AND pcp.user_id = pcpr.user_id
|
||||
AND pcp.version = pcpr.version
|
||||
and pcp.type=pcpr.type
|
||||
LEFT JOIN nxdt_ii.sys_user su ON pcp.user_id = su.user_id
|
||||
LEFT JOIN nxdt_ii.sys_dept sd ON su.dept_id = sd.dept_id
|
||||
WHERE
|
||||
pcp.task_id = #{taskId}
|
||||
AND pcp.type = 1
|
||||
pcp.task_id = #{taskId} AND pcp.type = 1
|
||||
<if test="userId!=null and userId!=''">
|
||||
and pcp.user_id=#{userId} and pcp.version=#{vision}
|
||||
</if>
|
||||
<if test="dataType!=null and dataType!=''">
|
||||
and pcpr.audit_status is not null
|
||||
</if>
|
||||
</select>
|
||||
<select id="getTreeList" resultType="com.bonus.flowable.entity.CheckComment">
|
||||
select pcp.user_id userId ,pcp.exam_type examType,pcp.version,pcpr.audit_status auditStatus
|
||||
from nxdt_ii.pt_check_person pcp
|
||||
LEFT JOIN nxdt_ii.pt_check_person_remark pcpr ON pcp.task_id = pcpr.task_id
|
||||
AND pcp.user_id = pcpr.user_id
|
||||
AND pcp.version = pcpr.version
|
||||
and pcp.type=pcpr.type
|
||||
where pcp.type=2 and pcp.task_id = #{taskId}
|
||||
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
|
|
|||
|
|
@ -344,11 +344,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
lk_cont_person lkc
|
||||
LEFT JOIN
|
||||
pt_cons_person pcp ON lkc.cons_persion_id = pcp.cons_user_id
|
||||
AND pcp.is_active = '1'
|
||||
left join sys_dict_data sdd on sdd.dict_value = pcp.post and sdd.dict_type = 'sys_cons_post' and sdd.status =
|
||||
'0'
|
||||
WHERE
|
||||
lkc.into_status = '3' and lkc.out_status = '0'
|
||||
lkc.into_status = '3' and lkc.out_status = '0' AND pcp.is_active = '1'
|
||||
<if test="bean.proId != null and bean.proId != ''">
|
||||
and lkc.pro_id = #{bean.proId}
|
||||
</if>
|
||||
|
|
|
|||
Loading…
Reference in New Issue