diff --git a/src/main/java/com/dreamchaser/depository_manage/controller/DepositoryRecordController.java b/src/main/java/com/dreamchaser/depository_manage/controller/DepositoryRecordController.java index 4e218836..1d9e83d1 100644 --- a/src/main/java/com/dreamchaser/depository_manage/controller/DepositoryRecordController.java +++ b/src/main/java/com/dreamchaser/depository_manage/controller/DepositoryRecordController.java @@ -1685,7 +1685,8 @@ public class DepositoryRecordController { } }); - } else if ("out".equals(type)) { + } + else if ("out".equals(type)) { // 获取部门负责人 List departmentHeadByUsers = PublicConfig.findDepartmentHeadByUser(userToken.getMaindeparment(), userkey, usertoken); StringBuilder departmentHeadId = new StringBuilder(); @@ -1976,6 +1977,7 @@ public class DepositoryRecordController { Integer integer = ObjectFormatUtil.toInteger(o); sumQuantity += integer; } + // 获取部门负责人 List departmentHeadByUsers = PublicConfig.findDepartmentHeadByUser(userToken.getMaindeparment(), userkey, usertoken); StringBuilder departmentHeadId = new StringBuilder(); @@ -1997,6 +1999,8 @@ public class DepositoryRecordController { mainRecord.put("adminorgId", userToken.getMaindeparment()); mainRecord.put("createUid", userToken.getId()); mainRecord.put("flagForAgency", 2); + mainRecord.put("depositoryId",depositoryIds.get(0)); + // 插入主表 depositoryRecordService.insertApplicationOutRecord(mainRecord, userToken, userkey, usertoken); id = ObjectFormatUtil.toInteger(mainRecord.get("id")); diff --git a/src/main/java/com/dreamchaser/depository_manage/service/impl/DepositoryRecordServiceImpl.java b/src/main/java/com/dreamchaser/depository_manage/service/impl/DepositoryRecordServiceImpl.java index 5b3c6e9b..315c4cb4 100644 --- a/src/main/java/com/dreamchaser/depository_manage/service/impl/DepositoryRecordServiceImpl.java +++ b/src/main/java/com/dreamchaser/depository_manage/service/impl/DepositoryRecordServiceImpl.java @@ -3019,6 +3019,9 @@ public class DepositoryRecordServiceImpl implements DepositoryRecordService { // 如果是开放仓库 flagForHasOtherDepository = false; + + + } else { // 如果不是 for (ApplicationOutRecordMin min : minByParent diff --git a/src/main/resources/templates/pages/application/form-step-look_back.html b/src/main/resources/templates/pages/application/form-step-look_back.html index 50b7dadc..e2ea2f91 100644 --- a/src/main/resources/templates/pages/application/form-step-look_back.html +++ b/src/main/resources/templates/pages/application/form-step-look_back.html @@ -207,7 +207,7 @@ $("#departmentheadMessageT").show(); } - if (departmentheadTime !== "" && departmentheadTime !== "0" && balancePoster === "") { + if (departmentheadTime !== "" && departmentheadTime !== "0" && balancePoster === "" && depositoryManagerPass !== "4") { // 如果部门负责人已经审批过 $("#depositoryManagerNameT").show(); } else if (departmentheadTime !== "" && departmentheadTime !== "0" && balancePoster !== "") { diff --git a/target/classes/templates/pages/application/form-step-look_back.html b/target/classes/templates/pages/application/form-step-look_back.html index 50b7dadc..e2ea2f91 100644 --- a/target/classes/templates/pages/application/form-step-look_back.html +++ b/target/classes/templates/pages/application/form-step-look_back.html @@ -207,7 +207,7 @@ $("#departmentheadMessageT").show(); } - if (departmentheadTime !== "" && departmentheadTime !== "0" && balancePoster === "") { + if (departmentheadTime !== "" && departmentheadTime !== "0" && balancePoster === "" && depositoryManagerPass !== "4") { // 如果部门负责人已经审批过 $("#depositoryManagerNameT").show(); } else if (departmentheadTime !== "" && departmentheadTime !== "0" && balancePoster !== "") {