动火审批过程中审批信息统一
parent
11585c5133
commit
1dd8bfad94
|
@ -623,8 +623,9 @@ public class AppHotworkCfdController extends BaseController {
|
|||
}
|
||||
|
||||
switch (status) {
|
||||
// created by liu jun 2024-01-30 description: 安全项检查人签字
|
||||
// 作业负责人审批
|
||||
case "2": {//确认
|
||||
case "1.5": {//确认
|
||||
if (files != null && files.length > 0) {
|
||||
MultipartFile file = files[0];
|
||||
|
||||
|
@ -643,7 +644,7 @@ public class AppHotworkCfdController extends BaseController {
|
|||
}
|
||||
// created by liu jun 2024-01-30 description: 作业负责人之前添加项目主管部门负责人签字
|
||||
// 项目主管部门审批
|
||||
case "2.5": {
|
||||
case "2": {
|
||||
if (files != null && files.length > 0) {
|
||||
MultipartFile file = files[0];
|
||||
String ffile = DateUtil.getDays();
|
||||
|
@ -651,9 +652,9 @@ public class AppHotworkCfdController extends BaseController {
|
|||
Smb.sshSftp(file, fileName, Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile);
|
||||
// 如果审批通过则进入下一阶段
|
||||
if (pd.get("APPROVAL_STATUS").equals("1")) {
|
||||
pd2.put("APPLY_STATUS", "3");
|
||||
pd2.put("APPLY_STATUS", "2");
|
||||
} else {
|
||||
pd2.put("APPLY_STATUS", "-2.5");
|
||||
pd2.put("APPLY_STATUS", "-2");
|
||||
}
|
||||
hotworkCfdService.edit(pd2);
|
||||
// 保存审批信息
|
||||
|
|
|
@ -189,6 +189,15 @@ public class HotworkCfdServiceImpl implements HotworkCfdService {
|
|||
message = message + "动火交底人未签字";
|
||||
passFlag = "0";
|
||||
}
|
||||
|
||||
condition.put("TYPE", "2");
|
||||
List<PageData> safetyList = busHotworkCfdExamineMapper.findByCondition(condition);
|
||||
if (safetyList == null || safetyList.size() == 0) throw new RuntimeException("未找到审批信息");
|
||||
unApprovalNum = (int) safetyList.stream().filter(x -> "0".equals(x.getString("APPROVAL_STATUS"))).count();
|
||||
if (unApprovalNum > 0) {
|
||||
message = message + "安全项检查人未签字";
|
||||
passFlag = "0";
|
||||
}
|
||||
PageData result = new PageData();
|
||||
result.put("passFlag", passFlag);
|
||||
result.put("message", message);
|
||||
|
@ -388,7 +397,7 @@ public class HotworkCfdServiceImpl implements HotworkCfdService {
|
|||
condition.put("IS_DELETE", "0");
|
||||
condition.put("VALID_FLAG", "1");
|
||||
List<PageData> approvalInfos = busHotworkCfdExamineMapper.findByCondition(condition);
|
||||
if(approvalInfos == null || approvalInfos.size() == 0) throw new RuntimeException("未找到审批信息");
|
||||
if(approvalInfos != null && approvalInfos.size() > 0) {
|
||||
// 动火交底人
|
||||
List<PageData> confess = approvalInfos.stream().filter(x -> "0".equals(x.getString("TYPE"))).collect(Collectors.toList());
|
||||
for (PageData x : confess) {
|
||||
|
@ -399,12 +408,14 @@ public class HotworkCfdServiceImpl implements HotworkCfdService {
|
|||
}
|
||||
pd.put("confessUserNames", confess.stream().map(x -> x.getString("USER_NAME")).collect(Collectors.joining(",")));
|
||||
pd.put("confessList", confess);
|
||||
|
||||
// 项目责任负责人
|
||||
PageData belong = approvalInfos.stream().filter(x -> "1".equals(x.getString("TYPE"))).findFirst().orElse(null);
|
||||
pd.put("BELONGING_USER_ID", belong.getString("USER_ID"));
|
||||
pd.put("BELONGING_USER_NAME", belong.getString("USER_NAME"));
|
||||
pd.put("BELONGING_DEPARTMENT_ID", belong.getString("DEPARTMENT_ID"));
|
||||
pd.put("BELONGING_DEPARTMENT_NAME", belong.getString("DEPARTMENT_NAME"));
|
||||
pd.put("BELONGING_OPINIONS", belong.getString("APPROVAL_OPINIONS"));
|
||||
pd.put("BELONGING_SIGNATURE", belong.getString("APPROVAL_SIGNATURE"));
|
||||
pd.put("BELONGING_SIGNATURE_TIME", belong.getString("APPROVAL_SIGNATURE_TIME"));
|
||||
// 安全项检查人
|
||||
|
@ -415,6 +426,7 @@ public class HotworkCfdServiceImpl implements HotworkCfdService {
|
|||
pd.put("SAFETY_DEPARTMENT_NAME", safety.getString("DEPARTMENT_NAME"));
|
||||
pd.put("SAFETY_SIGNATURE", safety.getString("APPROVAL_SIGNATURE"));
|
||||
pd.put("SAFETY_SIGNATURE_TIME", safety.getString("APPROVAL_SIGNATURE_TIME"));
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue