diff --git a/src/main/java/com/budwk/app/zhgh/activity/basic/controller/ActivityBasicScopeController.java b/src/main/java/com/budwk/app/zhgh/activity/basic/controller/ActivityBasicScopeController.java index 65d06236..0c83832a 100644 --- a/src/main/java/com/budwk/app/zhgh/activity/basic/controller/ActivityBasicScopeController.java +++ b/src/main/java/com/budwk/app/zhgh/activity/basic/controller/ActivityBasicScopeController.java @@ -2,6 +2,7 @@ package com.budwk.app.zhgh.activity.basic.controller; import cn.afterturn.easypoi.excel.ExcelExportUtil; import cn.afterturn.easypoi.excel.entity.ExportParams; +import cn.afterturn.easypoi.excel.entity.enmus.ExcelType; import cn.afterturn.easypoi.excel.entity.params.ExcelExportEntity; import cn.dev33.satoken.annotation.SaCheckPermission; import cn.dev33.satoken.stp.StpUtil; @@ -312,10 +313,10 @@ public class ActivityBasicScopeController { propMap.forEach((k, v) -> { entityList.add(new ExcelExportEntity(v, k, 40)); }); - response.setContentType("application/octet-stream"); - response.setHeader("Content-Disposition", "attachment;filename=" + new String(("人员名单.xls").getBytes("utf-8"), "ISO8859-1")); - Workbook workbook = ExcelExportUtil.exportExcel(new ExportParams(), entityList, map); - workbook.write(response.getOutputStream()); + ExportParams exportParams = new ExportParams(); + exportParams.setType(ExcelType.XSSF); + Workbook workbook = ExcelExportUtil.exportExcel(exportParams, entityList, map); + CommonDownloadUtil.download("人员名单.xlsx", workbook, response); } catch (Exception e) { e.printStackTrace(); } diff --git a/src/main/java/com/budwk/app/zhgh/activity/basic/controller/ActivityBasicScopeUserDataController.java b/src/main/java/com/budwk/app/zhgh/activity/basic/controller/ActivityBasicScopeUserDataController.java index 0c1e3ccb..7d3959af 100644 --- a/src/main/java/com/budwk/app/zhgh/activity/basic/controller/ActivityBasicScopeUserDataController.java +++ b/src/main/java/com/budwk/app/zhgh/activity/basic/controller/ActivityBasicScopeUserDataController.java @@ -1,5 +1,9 @@ package com.budwk.app.zhgh.activity.basic.controller; +import cn.afterturn.easypoi.excel.ExcelExportUtil; +import cn.afterturn.easypoi.excel.entity.ExportParams; +import cn.afterturn.easypoi.excel.entity.enmus.ExcelType; +import cn.afterturn.easypoi.excel.entity.params.ExcelExportEntity; import cn.dev33.satoken.annotation.SaCheckPermission; import cn.dev33.satoken.stp.StpUtil; import cn.hutool.core.util.ArrayUtil; @@ -11,16 +15,19 @@ import com.budwk.app.base.page.Pagination; import com.budwk.app.base.param.PageForm; import com.budwk.app.base.result.Result; import com.budwk.app.base.service.BaseService; +import com.budwk.app.base.utils.CommonDownloadUtil; import com.budwk.app.base.utils.EasyExcelUtil; import com.budwk.app.web.commons.auth.utils.SecurityUtil; import com.budwk.app.zhgh.activity.basic.models.ActivityUserScope; import com.budwk.app.zhgh.activity.basic.template.UserTemp; import io.swagger.annotations.ApiOperation; import org.apache.poi.ss.formula.functions.T; +import org.apache.poi.ss.usermodel.Workbook; import org.nutz.aop.interceptor.ioc.TransAop; import org.nutz.dao.Cnd; import org.nutz.dao.Sqls; import org.nutz.dao.sql.Sql; +import org.nutz.dao.util.cri.SqlExpressionGroup; import org.nutz.dao.util.cri.Static; import org.nutz.integration.jedis.RedisService; import org.nutz.ioc.aop.Aop; @@ -35,6 +42,7 @@ import org.nutz.mvc.annotation.Param; import org.nutz.mvc.upload.TempFile; import org.nutz.mvc.upload.UploadAdaptor; +import javax.servlet.http.HttpServletResponse; import javax.validation.Valid; import java.util.ArrayList; import java.util.List; @@ -94,8 +102,11 @@ public class ActivityBasicScopeUserDataController { """); Cnd cnd = Cnd.NEW(); - if (StrUtil.isNotBlank(pageForm.getSearchName()) && StrUtil.isNotBlank(pageForm.getSearchKeyword())) { - cnd.and(Cnd.likeEX(pageForm.getSearchName(), pageForm.getSearchKeyword())); + if (StrUtil.isNotBlank(pageForm.getSearchKeyword())){ + SqlExpressionGroup group = new SqlExpressionGroup(); + group.orLike("u.username", pageForm.getSearchKeyword()); + group.orLike("u.loginname", pageForm.getSearchKeyword()); + cnd.and(group); } if (StrUtil.isNotBlank(pageForm.getPageOrderName()) && StrUtil.isNotBlank(pageForm.getPageOrderBy())) { cnd.orderBy(pageForm.getPageOrderName(), pageForm.getPageOrderBy().equalsIgnoreCase("ascending") ? "ASC" : "DESC"); @@ -229,4 +240,50 @@ public class ActivityBasicScopeUserDataController { return Result.success(nutMap); } + @At + @Ok("void") + @ApiOperation("导出人员名单") + @SaCheckPermission("activity.basic.user") + public void doExportUser(Integer groupId, HttpServletResponse response) { + + + try { + + + Sql sql = Sqls.create(""" + SELECT + u.username AS userName, + u.loginname AS loginName, + u.sex, + u.mobile, + u.unitname AS unitName, + u.unionName AS unionName + FROM + activity_user_scope aus + LEFT JOIN `vw_user` u ON u.id = aus.userId + $condition + """); + + Cnd cnd = Cnd.NEW(); + cnd.andEX("aus.groupId", "=", groupId); + sql.setCondition(cnd); + List listMap = baseService.listMap(sql); + + List exportEntities = new ArrayList<>(); + exportEntities.add(new ExcelExportEntity("姓名", "userName", 20)); + exportEntities.add(new ExcelExportEntity("工号", "loginName", 20)); + exportEntities.add(new ExcelExportEntity("工会", "unionName", 20)); + exportEntities.add(new ExcelExportEntity("单位", "unitName", 20)); + exportEntities.add(new ExcelExportEntity("手机号码", "mobile", 20)); + + + ExportParams exportParams = new ExportParams(); + exportParams.setType(ExcelType.XSSF); + Workbook workbook = ExcelExportUtil.exportExcel(exportParams, exportEntities, listMap); + CommonDownloadUtil.download("人员名单.xlsx", workbook, response); + } catch (Exception e) { + e.printStackTrace(); + } + + } } diff --git a/src/main/java/com/budwk/app/zhgh/dayofficework/evaluation/controller/EvaluateApplyController.java b/src/main/java/com/budwk/app/zhgh/dayofficework/evaluation/controller/EvaluateApplyController.java index e4859d3c..4321534f 100644 --- a/src/main/java/com/budwk/app/zhgh/dayofficework/evaluation/controller/EvaluateApplyController.java +++ b/src/main/java/com/budwk/app/zhgh/dayofficework/evaluation/controller/EvaluateApplyController.java @@ -13,6 +13,7 @@ import com.budwk.app.flow.entity.ProcessTask; import com.budwk.app.flow.enums.ProcessSubmitTypeEnum; import com.budwk.app.flow.service.FlowCommonService; import com.budwk.app.web.commons.auth.utils.SecurityUtil; +import com.budwk.app.zhgh.dayofficework.evaluation.models.EvaluateActivity; import com.budwk.app.zhgh.dayofficework.evaluation.models.EvaluateApply; import com.budwk.app.zhgh.dayofficework.evaluation.service.EvaluateActivityService; import com.budwk.app.zhgh.dayofficework.evaluation.service.EvaluateService; @@ -91,6 +92,13 @@ public class EvaluateApplyController { @SaCheckPermission("evaluation.apply") @ApiOperation("验证能否申请") public Result valid(@Valid String id) { + EvaluateActivity activity = evaluateActivityService.fetch(id); + if (activity.getStartTime().after(new Date())){ + return Result.success().addData(false).addMsg("活动未开始"); + } + if (activity.getEndTime().before(new Date())){ + return Result.success().addData(false).addMsg("活动已结束"); + } return Result.success().addData(true); } diff --git a/src/main/java/com/budwk/app/zhgh/dayofficework/honor/controller/HonorManageController.java b/src/main/java/com/budwk/app/zhgh/dayofficework/honor/controller/HonorManageController.java index f594db8e..fcc738a9 100644 --- a/src/main/java/com/budwk/app/zhgh/dayofficework/honor/controller/HonorManageController.java +++ b/src/main/java/com/budwk/app/zhgh/dayofficework/honor/controller/HonorManageController.java @@ -7,7 +7,6 @@ import cn.afterturn.easypoi.excel.entity.params.ExcelExportEntity; import cn.dev33.satoken.annotation.SaCheckLogin; import cn.dev33.satoken.annotation.SaCheckPermission; import cn.hutool.core.util.StrUtil; -import cn.hutool.db.Page; import com.budwk.app.base.constant.RoleConstant; import com.budwk.app.base.page.Pagination; import com.budwk.app.base.result.Result; @@ -24,6 +23,7 @@ import org.nutz.dao.Cnd; import org.nutz.dao.Dao; import org.nutz.dao.Sqls; import org.nutz.dao.sql.Sql; +import org.nutz.dao.util.cri.SqlExpressionGroup; import org.nutz.ioc.loader.annotation.Inject; import org.nutz.ioc.loader.annotation.IocBean; import org.nutz.json.Json; @@ -32,11 +32,8 @@ import org.nutz.lang.util.NutMap; import org.nutz.mvc.Mvcs; import org.nutz.mvc.annotation.At; import org.nutz.mvc.annotation.Ok; -import org.nutz.mvc.annotation.Param; import javax.servlet.http.HttpServletResponse; -import java.io.IOException; -import java.nio.charset.StandardCharsets; import java.util.*; import java.util.stream.Collectors; @@ -83,9 +80,12 @@ public class HonorManageController { cnd.andEX("h.honorType", "=", pageForm.getHonorType()); cnd.andEX("h.prize", "=", pageForm.getPrize()); cnd.andEX("h.honorLevel", "=", pageForm.getHonorLevel()); - if (Strings.isNotBlank(pageForm.getUserName())) { - cnd.andEX("h.userName", "like", "%" + pageForm.getUserName() + "%"); - + cnd.andEX("h.unionId", "=", pageForm.getUnionId()); + if (Strings.isNotBlank(pageForm.getSearchKeyword())) { + SqlExpressionGroup group = new SqlExpressionGroup(); + group.orLike("u.loginname", "%" + pageForm.getSearchKeyword() + "%"); + group.orLike("u.username", "%" + pageForm.getSearchKeyword() + "%"); + cnd.and(group); } if (Strings.isNotBlank(pageForm.getUnitName())) { cnd.andEX("h.unitName", "like", "%" + pageForm.getUnitName() + "%"); @@ -105,7 +105,7 @@ public class HonorManageController { Pagination pagination = honorViService.listPageMap(pageForm.getPageNumber(), pageForm.getPageSize(), sql); List list = pagination.getList(); list.forEach(v -> { - if(StrUtil.isNotBlank(v.getString("awardMaterials"))){ + if (StrUtil.isNotBlank(v.getString("awardMaterials"))) { v.setv("awardMaterialsExcel", getBasicNameById(v.getString("awardMaterials")).toString()); } }); @@ -195,11 +195,11 @@ public class HonorManageController { v.setPrize(null); } } - if(v.getAwardMaterials() != null && !v.getAwardMaterials().isEmpty()) { + if (v.getAwardMaterials() != null && !v.getAwardMaterials().isEmpty()) { v.setAwardMaterialsExcel(getBasicNameById(Json.toJson(v.getAwardMaterials())).toString()); } v.setHonorType(singleHonor.get().getName()); - if(StrUtil.isNotBlank(v.getUserId())) { + if (StrUtil.isNotBlank(v.getUserId())) { Sys_user user = dao.fetch(Sys_user.class, v.getUserId()); v.setLoginname(user != null ? user.getLoginname() : ""); } diff --git a/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/activityBudget/service/impl/ActivityBudgetQueryStatisticsServiceImpl.java b/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/activityBudget/service/impl/ActivityBudgetQueryStatisticsServiceImpl.java index 8b3279fb..a14ccc56 100644 --- a/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/activityBudget/service/impl/ActivityBudgetQueryStatisticsServiceImpl.java +++ b/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/activityBudget/service/impl/ActivityBudgetQueryStatisticsServiceImpl.java @@ -66,7 +66,7 @@ public class ActivityBudgetQueryStatisticsServiceImpl extends BaseServiceImpl im } else if (outlayManageSource.equals("ACTIVITY_BUDGET_TYPE_THREE")) { Sql sql = Sqls.create(""" SELECT - @YEAR `year`, + @year `year`, sc.clubCode, sc.clubName, ab.clubId, diff --git a/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseApplyController.java b/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseApplyController.java index 75bb0df3..bed5b99d 100644 --- a/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseApplyController.java +++ b/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseApplyController.java @@ -104,6 +104,9 @@ public class OutlayReimburseApplyController { Dict args = Dict.create(); args.set(FlowConst.SUBMIT_TYPE, ProcessSubmitTypeEnum.APPLY.getCode()); args.set(FlowConst.FORM_DATA, outlayReimburse); + if (outlayReimburse.getOutlayManageSource().equals("ACTIVITY_BUDGET_TYPE_THREE")){ + args.set("clubId", outlayReimburse.getClubId()); + } args.set("outlayManageSource", outlayReimburse.getOutlayManageSource()); ProcessInstance instance = flowEngine.startProcessInstanceByKey("FYBXSQ", outlayReimburse.getId(), SecurityUtil.getUserId(), args); diff --git a/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseClubAuditController.java b/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseClubAuditController.java index d49dd7b8..c5f106c8 100644 --- a/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseClubAuditController.java +++ b/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseClubAuditController.java @@ -2,15 +2,22 @@ package com.budwk.app.zhgh.dayofficework.outlay.outlayReimburse.controller; import cn.dev33.satoken.annotation.SaCheckPermission; import cn.dev33.satoken.annotation.SaMode; +import cn.hutool.core.lang.Dict; import cn.hutool.core.util.StrUtil; import com.budwk.app.base.page.Pagination; import com.budwk.app.base.param.PageForm; import com.budwk.app.base.result.Result; import com.budwk.app.base.service.BaseService; import com.budwk.app.base.utils.PageUtil; +import com.budwk.app.flow.constant.FlowConst; +import com.budwk.app.flow.engine.FlowEngine; +import com.budwk.app.flow.entity.ProcessInstance; +import com.budwk.app.flow.entity.ProcessTask; +import com.budwk.app.flow.enums.ProcessSubmitTypeEnum; import com.budwk.app.flow.enums.ProcessTaskStateEnum; import com.budwk.app.sys.services.SysDictService; import com.budwk.app.web.commons.auth.utils.SecurityUtil; +import com.budwk.app.zhgh.dayofficework.outlay.outlayReimburse.model.OutlayReimburse; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import lombok.extern.slf4j.Slf4j; @@ -22,6 +29,7 @@ import org.nutz.ioc.loader.annotation.IocBean; import org.nutz.lang.util.NutMap; import org.nutz.mvc.annotation.At; import org.nutz.mvc.annotation.Ok; +import org.nutz.mvc.annotation.Param; import java.util.List; @@ -42,12 +50,17 @@ public class OutlayReimburseClubAuditController { @Inject private SysDictService sysDictService; + @Inject + private FlowEngine flowEngine; + + @At("/index") @Ok("beetl:/platform/zhgh/dayofficework/outlay/outlayReimburse/clubAudit/index.html") @SaCheckPermission("outlay.reimburse.clubAudit") public void index() { } + @At("/h5") @Ok("beetl:/platform/zhghh5/dayofficework/outlayReimburse/clubAudit/index.html") @SaCheckPermission("h5.outlay.reimburse.clubAudit") @@ -118,7 +131,24 @@ public class OutlayReimburseClubAuditController { } + @At + @ApiOperation("协会审核") + @SaCheckPermission(value = {"outlay.reimburse.clubAudit", "h5.outlay.reimburse.clubAudit"}, mode = SaMode.OR) + public Result submit(@Param("data") OutlayReimburse outlayReimburse) { + // 开启流程实例 + Dict args = Dict.create(); + args.set(FlowConst.SUBMIT_TYPE, ProcessSubmitTypeEnum.APPLY.getCode()); + args.set(FlowConst.FORM_DATA, outlayReimburse); + args.set("clubId", outlayReimburse.getClubId()); + ProcessInstance instance = flowEngine.startProcessInstanceByKey("FYBXSQ", outlayReimburse.getId(), SecurityUtil.getUserId(), args); + // 自动完成第一个申请任务 + List doingTaskList = flowEngine.processTaskService().getDoingTaskList(instance.getId(), null); + for (ProcessTask task : doingTaskList) { + flowEngine.executeProcessTask(task.getId(), SecurityUtil.getUserId(), args); + } + return Result.success(); + } } diff --git a/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseUnionAuditController.java b/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseUnionAuditController.java index c51497a9..a907a96d 100644 --- a/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseUnionAuditController.java +++ b/src/main/java/com/budwk/app/zhgh/dayofficework/outlay/outlayReimburse/controller/OutlayReimburseUnionAuditController.java @@ -65,6 +65,7 @@ public class OutlayReimburseUnionAuditController { String outlayManageSource) { Sql sql = Sqls.create(""" SELECT + ta.actorId, info.*, YEAR(info.applyTime) year, ins.id AS instanceId, diff --git a/src/main/java/com/budwk/app/zhgh/democratic/executiveCommittee/controller/ExecutiveCommitteePushController.java b/src/main/java/com/budwk/app/zhgh/democratic/executiveCommittee/controller/ExecutiveCommitteePushController.java index 9ced36ae..610c9013 100644 --- a/src/main/java/com/budwk/app/zhgh/democratic/executiveCommittee/controller/ExecutiveCommitteePushController.java +++ b/src/main/java/com/budwk/app/zhgh/democratic/executiveCommittee/controller/ExecutiveCommitteePushController.java @@ -140,7 +140,7 @@ public class ExecutiveCommitteePushController { ExecutiveCommitteeConfig config = dao.fetch(ExecutiveCommitteeConfig.class, Cnd.where("teacherMeetId", "=", teacherMeetId)); - if (ObjectUtil.isEmpty(config)) { + /* if (ObjectUtil.isEmpty(config)) { return Result.error("请先配置基础信息"); } if (config.getFirstStartTime().getTime() > System.currentTimeMillis()) { @@ -148,7 +148,7 @@ public class ExecutiveCommitteePushController { } if (config.getFirstEndTime().getTime() < System.currentTimeMillis()) { return Result.error("一次预选已结束"); - } + }*/ int dbCount = dao.count(ExecutiveCommitteeOnePush.class, Cnd.where("teacherMeetId", "=", teacherMeetId) diff --git a/src/main/java/com/budwk/app/zhgh/democratic/executiveCommittee/service/impl/ExecutiveCommitteeMemberServiceImpl.java b/src/main/java/com/budwk/app/zhgh/democratic/executiveCommittee/service/impl/ExecutiveCommitteeMemberServiceImpl.java index 2a506c5f..1989e861 100644 --- a/src/main/java/com/budwk/app/zhgh/democratic/executiveCommittee/service/impl/ExecutiveCommitteeMemberServiceImpl.java +++ b/src/main/java/com/budwk/app/zhgh/democratic/executiveCommittee/service/impl/ExecutiveCommitteeMemberServiceImpl.java @@ -1,5 +1,6 @@ package com.budwk.app.zhgh.democratic.executiveCommittee.service.impl; +import cn.hutool.core.util.StrUtil; import com.budwk.app.base.service.impl.BaseServiceImpl; import com.budwk.app.zhgh.democratic.executiveCommittee.param.ExecutiveCommitteePageForm; import com.budwk.app.zhgh.democratic.executiveCommittee.service.ExecutiveCommitteeMemberService; @@ -7,8 +8,8 @@ import org.nutz.dao.Cnd; import org.nutz.dao.Dao; import org.nutz.dao.Sqls; import org.nutz.dao.sql.Sql; +import org.nutz.dao.util.cri.SqlExpressionGroup; import org.nutz.ioc.loader.annotation.IocBean; -import org.nutz.lang.Strings; /** * @author zhf @@ -50,8 +51,11 @@ public class ExecutiveCommitteeMemberServiceImpl extends BaseServiceImpl impleme cnd.andEX("op.unitId", "=", pageForm.getUnitId()); cnd.andEX("it.unionid", "=", pageForm.getUnionId()); cnd.andEX("op.delegationId", "=", pageForm.getDelegationId()); - if (Strings.isNotBlank(pageForm.getSearchName()) && Strings.isNotBlank(pageForm.getSearchKeyword())) { - cnd.and(pageForm.getSearchName(), "LIKE", "%" + pageForm.getSearchKeyword() + "%"); + if (StrUtil.isNotBlank(pageForm.getSearchKeyword())) { + SqlExpressionGroup group = new SqlExpressionGroup(); + group.orLike("op.userName", pageForm.getSearchKeyword()); + group.orLike("op.loginName", pageForm.getSearchKeyword()); + cnd.and(group); } cnd.desc("pushCount"); cnd.asc("op.firstLetter"); diff --git a/src/main/resources/static/components/module/activity/UserDataScope.vue b/src/main/resources/static/components/module/activity/UserDataScope.vue index 3982722c..fb6ff1d7 100644 --- a/src/main/resources/static/components/module/activity/UserDataScope.vue +++ b/src/main/resources/static/components/module/activity/UserDataScope.vue @@ -28,17 +28,9 @@
姓名/工号
- - - - - +
diff --git a/src/main/resources/views/platform/zhgh/dayofficework/evaluation/activity/index.html b/src/main/resources/views/platform/zhgh/dayofficework/evaluation/activity/index.html index b3dd0c98..1319d92e 100644 --- a/src/main/resources/views/platform/zhgh/dayofficework/evaluation/activity/index.html +++ b/src/main/resources/views/platform/zhgh/dayofficework/evaluation/activity/index.html @@ -236,11 +236,20 @@ layout("/layouts/platform.html"){ openAdd() { this.stepActive = 0 this.dialogVisible = true - this.formData={} + this.formData={ + name: "", + year: new Date().getFullYear().toString(), + startTime: null, + endTime: null, + notice: null, + quotaAllocations: null, + activityGroupId: "", + enable: true + } this.$nextTick(() => { this.$refs.formRef.resetFields() + this.$refs.formRef.clearValidate() }) - this.$refs.formRef.clearValidate() this.$axios.post("/platform/evaluate/activity/initQuotaAllocations").then((res) => { if (res.code === 0) { this.$set(this.formData, "quotaAllocations", res.data) diff --git a/src/main/resources/views/platform/zhgh/dayofficework/honor/manage/index.html b/src/main/resources/views/platform/zhgh/dayofficework/honor/manage/index.html index ce778863..5aeca8bd 100644 --- a/src/main/resources/views/platform/zhgh/dayofficework/honor/manage/index.html +++ b/src/main/resources/views/platform/zhgh/dayofficework/honor/manage/index.html @@ -7,21 +7,24 @@ layout("/layouts/platform.html"){ - + - - + + @@ -29,12 +32,14 @@ layout("/layouts/platform.html"){ - - + + - - + + @@ -45,34 +50,44 @@ layout("/layouts/platform.html"){ 导出 - + - - - - - - + + + + + + - + - + @@ -287,10 +304,17 @@ layout("/layouts/platform.html"){ userOptions: [], isEdit: false, firstInPage: true, - id: GetQueryString("id") ? GetQueryString("id") : "" + id: GetQueryString("id") ? GetQueryString("id") : "", } }, methods: { + async userRemoteMethod(query) { + if (query) { + this.userOptions = [] + const resp = await this.$axios.post("/platform/honor/registration/listBeComfortedUser", {keyWord: query}) + this.userOptions = resp.data + } + }, doBack() { if (GetQueryString("id")) { this.$store.dispatch("pjaxRoute", "/platform/honor/manage") @@ -311,7 +335,7 @@ layout("/layouts/platform.html"){ }) }, userChange(id) { - this.$axios.post("/platform/honor/apply/getUserInfo", { id: id }).then((res) => { + this.$axios.post("/platform/honor/apply/getUserInfo", {id: id}).then((res) => { if (res.code === 0) { this.setFormData(res.data) } @@ -330,7 +354,7 @@ layout("/layouts/platform.html"){ this.$set(this.formData, "political", user.political) }, async getUser(keyWord) { - const resp = await this.$axios.post("/platform/condolence/apply/listBeComfortedUser", { keyWord: keyWord }) + const resp = await this.$axios.post("/platform/condolence/apply/listBeComfortedUser", {keyWord: keyWord}) return resp.data }, async honorTypeChange(val) { @@ -339,7 +363,7 @@ layout("/layouts/platform.html"){ const data = this.honorTypeList.find((v) => v.id === val) if (data) { this.$set(this.formData, "queryTypeCode", data.queryTypeCode) - if(data.queryTypeCode === 'HONOR_LIST') { + if (data.queryTypeCode === 'HONOR_LIST') { this.$set(this.formData, "unionId", this.$store.state.user.union ? this.$store.state.user.union.id : "") if (this.formData.unionId) { this.searchUnionInfo(this.formData.unionId) @@ -350,32 +374,29 @@ layout("/layouts/platform.html"){ } }, async getHonorPrize(honorType) { - const res = await this.$axios.post("/platform/honor/basic/settings/getData", { parentId: honorType }) + const res = await this.$axios.post("/platform/honor/basic/settings/getData", {parentId: honorType}) return res.data }, - getHonorType() { - this.$axios.post("/platform/honor/basic/settings/getHonorType").then((res) => { - if (res.code === 0) { - this.honorTypeList = res.data - } - }) + async getHonorType() { + const res = await this.$axios.post("/platform/honor/basic/settings/getHonorType") + if (res.code === 0) { + this.honorTypeList = res.data + } }, - getHonorLevel() { - this.$axios.post("/platform/honor/basic/settings/getHonorLevel").then((res) => { - if (res.code === 0) { - this.honorLevelList = res.data - } - }) + async getHonorLevel() { + const res = await this.$axios.post("/platform/honor/basic/settings/getHonorLevel") + if (res.code === 0) { + this.honorLevelList = res.data + } }, - getHonorAwardType() { - this.$axios.post("/platform/honor/basic/settings/getHonorAwardType").then((res) => { - if (res.code === 0) { - this.honorAwardList = res.data - } - }) + async getHonorAwardType() { + const res = await this.$axios.post("/platform/honor/basic/settings/getHonorAwardType") + if (res.code === 0) { + this.honorAwardList = res.data + } }, searchUnionInfo(id) { - this.$axios.post("/platform/honor/basic/settings/getUnionInfo", { id: id }).then((res) => { + this.$axios.post("/platform/honor/basic/settings/getUnionInfo", {id: id}).then((res) => { if (res.code === 0) { this.formData.memberNumber = res.data.memberNumber this.formData.unionLeader = res.data.username @@ -383,29 +404,28 @@ layout("/layouts/platform.html"){ }) }, async findData(id) { - const resp = await this.$axios.post(loc() + "/findData", { id: id }) + const resp = await this.$axios.post(loc() + "/findData", {id: id}) const data1 = resp.data this.formData = resp.data if (this.formData.userId && this.formData.userId !== "") { - this.$nextTick(() => { - this.userChange(this.formData.userId) - }) + await this.userRemoteMethod(this.formData.userName) } else { this.$set(this.formData, "userName", this.formData.userName) } await this.honorTypeChange(data1.honorType) - this.$set(this.formData, "prize", data1.prize) - this.$set(this.formData, "honorLevel", data1.honorLevel) - this.$set(this.formData, "political", data1.political) - this.$set(this.formData, "post", data1.post) - this.$set(this.formData, "title", data1.title) - this.$set(this.formData, "unionId", data1.unionId) - this.$set(this.formData, "unionLeader", data1.unionLeader) + /* this.$set(this.formData, "prize", data1.prize) + this.$set(this.formData, "honorLevel", data1.honorLevel) + this.$set(this.formData, "political", data1.political) + this.$set(this.formData, "post", data1.post) + this.$set(this.formData, "title", data1.title) + this.$set(this.formData, "unionId", data1.unionId) + this.$set(this.formData, "unionLeader", data1.unionLeader)*/ + console.log(this.formData) }, async initData() { - this.getHonorType() - this.getHonorLevel() - this.getHonorAwardType() + await this.getHonorType() + await this.getHonorLevel() + await this.getHonorAwardType() this.unions = await this.$businessTool.listUnion() this.units = await this.$businessTool.listUnit() /*this.$set(this.formData, "unionId", this.$store.state.user.union ? this.$store.state.user.union.id : "") @@ -421,8 +441,8 @@ layout("/layouts/platform.html"){ } } }, - created() { - this.initData() + async created() { + await this.initData() if (GetQueryString("id")) { this.findData(GetQueryString("id")) } diff --git a/src/main/resources/views/platform/zhgh/dayofficework/outlay/outlayReimburse/clubAudit/index.html b/src/main/resources/views/platform/zhgh/dayofficework/outlay/outlayReimburse/clubAudit/index.html index 11a147e2..8f4b60be 100644 --- a/src/main/resources/views/platform/zhgh/dayofficework/outlay/outlayReimburse/clubAudit/index.html +++ b/src/main/resources/views/platform/zhgh/dayofficework/outlay/outlayReimburse/clubAudit/index.html @@ -145,7 +145,7 @@ layout("/layouts/platform.html"){ cancelButtonText: "取消", type: "warning" }).then(() => { - this.$axios.post("/flow/common/executeTask", { + this.$axios.post("/platform/outlay/reimburse/clubAudit/submit", { data: JSON.stringify({ ...this.formData, submitType: val diff --git a/src/main/resources/views/platform/zhgh/democratic/executiveCommittee/executiveCommitteeMember/index.html b/src/main/resources/views/platform/zhgh/democratic/executiveCommittee/executiveCommitteeMember/index.html index 146d7d39..21406ac6 100644 --- a/src/main/resources/views/platform/zhgh/democratic/executiveCommittee/executiveCommitteeMember/index.html +++ b/src/main/resources/views/platform/zhgh/democratic/executiveCommittee/executiveCommitteeMember/index.html @@ -6,18 +6,8 @@ layout("/layouts/platform.html"){ - - - - - - - + + { - this.$axios.post('/flow/common/executeTask', { + this.$axios.post('/platform/outlay/reimburse/clubAudit/submit', { data: JSON.stringify({ ...this.formData, submitType: val