diff --git a/src/main/java/com/budwk/app/sys/controller/SysUnionController.java b/src/main/java/com/budwk/app/sys/controller/SysUnionController.java index 1578bb5d..3cc83385 100644 --- a/src/main/java/com/budwk/app/sys/controller/SysUnionController.java +++ b/src/main/java/com/budwk/app/sys/controller/SysUnionController.java @@ -354,7 +354,17 @@ public class SysUnionController { @ApiOperation("分工会组成单位分页") @SaCheckPermission("sys.manager.union") public Result branchUnionPartUnitPageData(PageForm pageForm, String unionId) { - List list = dao.query(Sys_unit.class, Cnd.where("unionId", "=", unionId).asc("unitcode")); + Cnd cnd = Cnd.NEW(); + cnd.and("unionId", "=", unionId); + if (StrUtil.isNotBlank(pageForm.getSearchKeyword())) { + SqlExpressionGroup seg = new SqlExpressionGroup(); + seg.orLike("`name`", pageForm.getSearchKeyword()); + seg.orLike("unitcode", pageForm.getSearchKeyword()); + cnd.and(seg); + } + cnd.desc("unitcode"); + + List list = dao.query(Sys_unit.class, cnd); return Result.success(list); } diff --git a/src/main/java/com/budwk/app/sys/controller/SysUnitController.java b/src/main/java/com/budwk/app/sys/controller/SysUnitController.java index b280fab3..0bfadc42 100644 --- a/src/main/java/com/budwk/app/sys/controller/SysUnitController.java +++ b/src/main/java/com/budwk/app/sys/controller/SysUnitController.java @@ -46,6 +46,7 @@ import javax.servlet.http.HttpServletRequest; import javax.validation.Valid; import java.util.ArrayList; import java.util.List; +import java.util.Map; ; @@ -75,12 +76,13 @@ public class SysUnitController { @At("/pageData") @Ok("json") @SaCheckLogin - public Object pageData(PageForm pageForm, String unitName, Integer unitLevel) { + public Object pageData(PageForm pageForm, String unitName, String unitId) { Cnd cnd = Cnd.NEW(); // cnd.and("parentId", "is not", null).andEX("unitLevel", "=", unitLevel).asc("unitLevel").asc("unitcode"); - cnd.and("parentId", "is not", null) - .and("unitTypeCode", "=", "1") - .asc("unitcode"); + cnd.and("parentId", "is not", null); + cnd.andEX("parentId", "=", unitId); +// cnd.and("unitTypeCode", "=", "1"); + cnd.asc("unitcode"); cnd.and(Cnd.likeEX("name", unitName)); Pagination listPage = sysUnitService.listPage(pageForm.getPageNumber(), pageForm.getPageSize(), Sys_unit.class, cnd); @@ -92,14 +94,14 @@ public class SysUnitController { @SaCheckLogin public Object userPageData(PageForm pageForm, String unitId) { Sql sql = Sqls.create(""" - select username,loginname,sex,mobile,if(member = 1, '是', '否') as member from vw_user $condition + select username,loginname,sex,mobile,member from vw_user $condition """).setParam("unitId", unitId); Cnd cnd = Cnd.NEW(); cnd.and("unitid", "=", unitId); if (Strings.isNotBlank(pageForm.getSearchName()) && Strings.isNotBlank(pageForm.getSearchKeyword())) { cnd.and(pageForm.getSearchName(), "like", "%" + pageForm.getSearchKeyword() + "%"); } - cnd.asc("member"); + cnd.desc("member"); sql.setCondition(cnd); return Result.success(sysUnitService.listPageMap(pageForm.getPageNumber(), pageForm.getPageSize(), sql)); } @@ -290,7 +292,13 @@ public class SysUnitController { List> nodeList = CollUtil.newArrayList(); for (int i = 0; i < list.size(); i++) { - nodeList.add(new TreeNode<>(list.get(i).getId(), list.get(i).getParentId(), list.get(i).getName(), i)); + nodeList.add(new TreeNode<>(list.get(i).getId(), list.get(i).getParentId(), list.get(i).getName(), i) + .setExtra( + Map.of( + "unitType", list.get(i).getUnitType(), + "unitTypeCode", list.get(i).getUnitTypeCode() + ) + )); } List> treeList = TreeUtil.build(nodeList, StrUtil.blankToDefault(pid, "0000")); diff --git a/src/main/java/com/budwk/app/sys/services/impl/SysUnionGroupServiceImpl.java b/src/main/java/com/budwk/app/sys/services/impl/SysUnionGroupServiceImpl.java index a7188e06..3fece4c4 100644 --- a/src/main/java/com/budwk/app/sys/services/impl/SysUnionGroupServiceImpl.java +++ b/src/main/java/com/budwk/app/sys/services/impl/SysUnionGroupServiceImpl.java @@ -43,7 +43,10 @@ public class SysUnionGroupServiceImpl extends BaseServiceImpl i @Override @Aop(TransAop.READ_COMMITTED) public void insert(Sys_union_group group) { - int count = dao().count(Sys_union_group.class, Cnd.where(Sys_union_group::getCode, "=", group.getCode())); + int count = dao().count(Sys_union_group.class, + Cnd.where(Sys_union_group::getCode, "=", group.getCode()) + .and(Sys_union_group::getUnionId, "=", group.getUnionId()) + ); if (count > 0) { throw new BaseException("小组编码已存在"); } @@ -54,8 +57,11 @@ public class SysUnionGroupServiceImpl extends BaseServiceImpl i @Override @Aop(TransAop.READ_COMMITTED) public void update(Sys_union_group group) { - int count = dao().count(Sys_union_group.class, Cnd.where(Sys_union_group::getCode, "=", group.getCode()) - .and(Sys_union_group::getId, "!=", group.getId())); + int count = dao().count(Sys_union_group.class, + Cnd.where(Sys_union_group::getCode, "=", group.getCode()) + .and(Sys_union_group::getId, "!=", group.getId()) + .and(Sys_union_group::getUnionId, "=", group.getUnionId()) + ); if (count > 0) { throw new BaseException("小组编码已存在"); } diff --git a/src/main/java/com/budwk/app/zhgh/staffbenefit/difficulthelp/controller/DifficultHelpApplyController.java b/src/main/java/com/budwk/app/zhgh/staffbenefit/difficulthelp/controller/DifficultHelpApplyController.java index 585b4ec8..26636ef6 100644 --- a/src/main/java/com/budwk/app/zhgh/staffbenefit/difficulthelp/controller/DifficultHelpApplyController.java +++ b/src/main/java/com/budwk/app/zhgh/staffbenefit/difficulthelp/controller/DifficultHelpApplyController.java @@ -149,7 +149,7 @@ public class DifficultHelpApplyController { $condition """); Cnd cnd = Cnd.NEW(); - + cnd.and("id", "<>", SecurityUtil.getUserId()); if (!AuthUtil.hasRoleOr(RoleConstant.SYSADMIN.name(), RoleConstant.SCHOOL_UNION_ADMIN.name())) { if (AuthUtil.hasRoleOr(RoleConstant.BRANCH_UNION_CHAIRMAN.name(), RoleConstant.BRANCH_UNION_ADMIN.name(), RoleConstant.BRANCH_UNION_OPERATOR.name())) { cnd.and("unionid", "=", SecurityUtil.getUnionId()); diff --git a/src/main/java/com/budwk/app/zhgh/staffbenefit/difficulthelp/controller/DifficultHelpReadingController.java b/src/main/java/com/budwk/app/zhgh/staffbenefit/difficulthelp/controller/DifficultHelpReadingController.java index 3109e2ff..8efb5355 100644 --- a/src/main/java/com/budwk/app/zhgh/staffbenefit/difficulthelp/controller/DifficultHelpReadingController.java +++ b/src/main/java/com/budwk/app/zhgh/staffbenefit/difficulthelp/controller/DifficultHelpReadingController.java @@ -88,7 +88,7 @@ public class DifficultHelpReadingController { """); Cnd cnd = Cnd.NEW(); pageParam.buildSearch(cnd, "info."); - cnd.groupBy("t.id"); + cnd.groupBy("info.id"); sql.setCondition(cnd); Pagination pagination = difficultHelpCommonService.listPageMap(pageParam.getPageNumber(), pageParam.getPageSize(), sql); return Result.success().addData(pagination); diff --git a/src/main/resources/static/components/plugins/sysUserSelect/index.vue b/src/main/resources/static/components/plugins/sysUserSelect/index.vue index e117d77d..f04ca49e 100644 --- a/src/main/resources/static/components/plugins/sysUserSelect/index.vue +++ b/src/main/resources/static/components/plugins/sysUserSelect/index.vue @@ -1,6 +1,6 @@ @@ -250,17 +252,18 @@ layout("/layouts/platform.html"){ formRules: { proxyUserName: [{required: true, message: '必填', trigger: ['blur', 'change']}], proxyLoginName: [{required: true, message: '必填', trigger: ['blur', 'change']}], - sex: [{required: true, message: '必填', trigger: ['blur', 'change']}], - unitName: [{required: true, message: '必填', trigger: ['blur', 'change']}], - unionName: [{required: true, message: '必填', trigger: ['blur', 'change']}], - monthlyIncome: [{required: true, message: '必填', trigger: ['blur', 'change']}], - mobile: [{required: true, message: '必填', trigger: ['blur', 'change']}], - idCard: [{required: true, message: '必填', trigger: ['blur', 'change']}], - bankCardNum: [{required: true, message: '必填', trigger: ['blur', 'change']}], - officialCapacity: [{required: true, message: '必填', trigger: ['blur', 'change']}], - subsidyStandards: [{required: true, message: '必填', trigger: ['blur', 'change']}], - reason: [{required: true, message: '必填', trigger: ['blur', 'change']}], - sign: [{required: true, message: '必填', trigger: ['blur', 'change']}] + sex: [{required: true, message: '请填写性别', trigger: ['blur', 'change']}], + userName: [{required: true, message: '请填写受补助人', trigger: ['blur', 'change']}], + unitName: [{required: true, message: '请填写所属单位', trigger: ['blur', 'change']}], + unionName: [{required: true, message: '请填写所属工会', trigger: ['blur', 'change']}], + monthlyIncome: [{required: true, message: '请填写月收入', trigger: ['blur', 'change']}], + mobile: [{required: true, message: '请填写手机号码', trigger: ['blur', 'change']}], + idCard: [{required: true, message: '请填写身份证号', trigger: ['blur', 'change']}], + bankCardNum: [{required: true, message: '请填写收款账户卡号', trigger: ['blur', 'change']}], + officialCapacity: [{required: true, message: '请填写职务职称', trigger: ['blur', 'change']}], + subsidyStandards: [{required: true, message: '请选择困难类型', trigger: ['blur', 'change']}], + reason: [{required: true, message: '请填写申请原因', trigger: ['blur', 'change']}], + sign: [{required: true, message: '请签字', trigger: ['blur', 'change']}] }, // 替他人申请相关 @@ -285,44 +288,75 @@ layout("/layouts/platform.html"){ }, // 提交 - onSubmit() { - this.$confirm("您确定要提交吗?", "提示", { - confirmButtonText: "确定", - cancelButtonText: "取消", - type: "warning" - }).then(() => { - this.$axios.post('/platform/difficultHelp/apply/submit', { - data: JSON.stringify(this.formData) - }).then(res => { - if (res.code === 0) { - this.$message.success("提交成功") - commonUtil.pjaxPush('/platform/difficultHelp/mine') - } - }) + async onSubmit() { + this.$refs.formRef.validate().then((valid) => { + if (valid) { + this.$confirm("您确定要提交吗?", "提示", { + confirmButtonText: "确定", + cancelButtonText: "取消", + type: "warning" + }).then(() => { + const result = this.isValidIdCard(this.formData.idCard) + if (result.status === 0) { + this.$message.warning(result.msg) + return + } + // const bankRes = this.validateCard(this.formData.bankCardNum) + // if (bankRes.status === 0) { + // this.$message.warning(bankRes.msg) + // return; + // } + + this.$axios.post('/platform/difficultHelp/apply/submit', { + data: JSON.stringify(this.formData) + }).then(res => { + if (res.code === 0) { + this.$message.success("提交成功") + commonUtil.pjaxPush('/platform/difficultHelp/mine') + } + }) + }) + } }) }, - onFinishTask() { - this.$confirm("您确定要提交吗?", "提示", { - confirmButtonText: "确定", - cancelButtonText: "取消", - type: "warning" - }).then(() => { - this.$axios.post('/platform/difficultHelp/apply/submitAgain', { - data: JSON.stringify(this.formData), - taskId: GetQueryString("taskId") - }).then(res => { - if (res.code === 0) { - this.$message.success("提交成功") - commonUtil.pjaxPush('/platform/difficultHelp/mine') - } - }) + async onFinishTask() { + this.$refs.formRef.validate().then((valid) => { + if (valid) { + this.$confirm("您确定要提交吗?", "提示", { + confirmButtonText: "确定", + cancelButtonText: "取消", + type: "warning" + }).then(() => { + + const result = this.isValidIdCard(this.formData.idCard) + if (result.status === 0) { + this.$message.warning(result.msg) + return + } + // const bankRes = this.validateCard(this.formData.bankCardNum) + // if (bankRes.status === 0) { + // this.$message.warning(bankRes.msg) + // return; + // } + + this.$axios.post('/platform/difficultHelp/apply/submitAgain', { + data: JSON.stringify(this.formData), + taskId: GetQueryString("taskId") + }).then(res => { + if (res.code === 0) { + this.$message.success("提交成功") + commonUtil.pjaxPush('/platform/difficultHelp/mine') + } + }) + }) + } }) }, // 查询受助人 queryRecipients(key) { - this.$axios.get("/platform/difficultHelp/apply/queryRecipients", { + this.$axios.post("/platform/difficultHelp/apply/queryRecipients", { key }).then(res => { if (res.code === 0) { @@ -334,6 +368,7 @@ layout("/layouts/platform.html"){ this.$axios.post('/platform/difficultHelp/mine/findOne', { id }).then(res => { if (res.code === 0) { this.formData = res.data + this.queryRecipients(res.data.loginName) } }) }, diff --git a/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/branchunionapproval/index.html b/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/branchunionapproval/index.html index 52a55b6f..2d7e82b0 100644 --- a/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/branchunionapproval/index.html +++ b/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/branchunionapproval/index.html @@ -126,7 +126,7 @@ layout("/layouts/platform.html"){ { prop: "unitName", label: "所属单位", sortable: true }, { prop: "subsidyStandards", label: "困难类型", sortable: true }, { prop: "applyTime", label: "申请时间", sortable: true }, - { prop: "taskName", label: "当前节点"}, + { prop: "curTaskName", label: "当前节点"}, { prop: "instanceState", label: "流程状态"} ], unions: [], diff --git a/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/mine/index.html b/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/mine/index.html index f9e26d2a..fb2c0ef8 100644 --- a/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/mine/index.html +++ b/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/mine/index.html @@ -105,7 +105,7 @@ layout("/layouts/platform.html"){ { prop: "unitName", label: "所属单位", sortable: true }, { prop: "subsidyStandards", label: "困难类型", sortable: true }, { prop: "applyTime", label: "申请时间", sortable: true }, - { prop: "curTaskName", label: "当前节点" }, + { prop: "taskName", label: "当前节点" }, { prop: "instanceState", label: "流程状态" } ], unions: [], diff --git a/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/reading/index.html b/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/reading/index.html index 4b76926c..e527254f 100644 --- a/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/reading/index.html +++ b/src/main/resources/views/platform/zhgh/staffbenefit/difficulthelp/reading/index.html @@ -62,6 +62,9 @@ layout("/layouts/platform.html"){ + diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/apply/mine/index.html b/src/main/resources/views/platform/zhgh/staffmanage/member/apply/mine/index.html index b9acd785..eab5b783 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/apply/mine/index.html +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/apply/mine/index.html @@ -90,7 +90,7 @@ layout("/layouts/platform.html"){ { prop: "unionName", label: "所属工会", sortable: true }, { prop: "unitName", label: "所属单位", sortable: true }, { prop: "sign", label: "签字" }, - { prop: "curTaskName", label: "当前节点"}, + { prop: "taskName", label: "当前节点"}, { prop: "instanceState", label: "流程状态"} ], unions: [], diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/branch/verification/check/index.html b/src/main/resources/views/platform/zhgh/staffmanage/member/branch/verification/check/index.html index 46fbe729..b6fbc0bf 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/branch/verification/check/index.html +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/branch/verification/check/index.html @@ -40,13 +40,13 @@ layout("/layouts/platform.html"){ - + - + - + diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/change/common/commonQuery.js b/src/main/resources/views/platform/zhgh/staffmanage/member/change/common/commonQuery.js index 8a84e481..886faa21 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/change/common/commonQuery.js +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/change/common/commonQuery.js @@ -19,15 +19,15 @@ const COMMON_QUERY = { - - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/change/manage/index.html b/src/main/resources/views/platform/zhgh/staffmanage/member/change/manage/index.html index 8f21aedf..8473e50d 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/change/manage/index.html +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/change/manage/index.html @@ -27,15 +27,15 @@ layout("/layouts/platform.html"){ code="USER_SEX"> - - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/change/record/index.html b/src/main/resources/views/platform/zhgh/staffmanage/member/change/record/index.html index 3da8d75b..f3e29747 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/change/record/index.html +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/change/record/index.html @@ -24,11 +24,11 @@ layout("/layouts/platform.html"){ - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/common/manage/memberManageQuery.js b/src/main/resources/views/platform/zhgh/staffmanage/member/common/manage/memberManageQuery.js index bcb54692..4daa8989 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/common/manage/memberManageQuery.js +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/common/manage/memberManageQuery.js @@ -24,15 +24,15 @@ const MEMBER_MANAGE_QUERY = { code="USER_SEX"> - - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/info/common/commonQuery.js b/src/main/resources/views/platform/zhgh/staffmanage/member/info/common/commonQuery.js index f22d4414..ae62ed74 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/info/common/commonQuery.js +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/info/common/commonQuery.js @@ -34,15 +34,15 @@ const COMMON_QUERY = { - - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/info/history/index.html b/src/main/resources/views/platform/zhgh/staffmanage/member/info/history/index.html index 86606107..a2a57761 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/info/history/index.html +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/info/history/index.html @@ -41,15 +41,15 @@ layout("/layouts/platform.html"){ - + - + diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/modelworker/manage/index.html b/src/main/resources/views/platform/zhgh/staffmanage/member/modelworker/manage/index.html index b422e4ca..c282c950 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/modelworker/manage/index.html +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/modelworker/manage/index.html @@ -23,11 +23,11 @@ layout("/layouts/platform.html"){ - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/check/schoolViewAndHandle.js b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/check/schoolViewAndHandle.js index de2d1b0f..fcbb75f8 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/check/schoolViewAndHandle.js +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/check/schoolViewAndHandle.js @@ -16,15 +16,15 @@ const SCHOOL_VIEW_AND_HANDLE = { - - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/check/viewChangeTypeUser.js b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/check/viewChangeTypeUser.js index c985147c..8bcfd7e6 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/check/viewChangeTypeUser.js +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/check/viewChangeTypeUser.js @@ -14,15 +14,15 @@ const VIEW_CHANGE_TYPE_USER = { - - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationQuery.js b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationQuery.js index b528f657..76e9fd8f 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationQuery.js +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationQuery.js @@ -20,11 +20,11 @@ const VERIFICATION_QUERY = { - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationSetUserList.js b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationSetUserList.js index b21a46ee..c13c98df 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationSetUserList.js +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationSetUserList.js @@ -25,15 +25,15 @@ const VERIFICATION_SET_USER_LIST = { - - - diff --git a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationShowSelectionUsers.js b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationShowSelectionUsers.js index ea1b6f8c..fa06c013 100644 --- a/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationShowSelectionUsers.js +++ b/src/main/resources/views/platform/zhgh/staffmanage/member/school/verification/manage/verificationShowSelectionUsers.js @@ -23,15 +23,15 @@ const VERIFICATION_SHOW_SELECTION_USERS = { - - -