commit
This commit is contained in:
+14
-1
@@ -234,7 +234,20 @@ public class ClubRegistApplyController {
|
||||
|
||||
//如果不是管理员,并且点的提交按钮
|
||||
if (!isSave && Objects.equals(club.getUserid(), ShiroUtil.getUserId())) {
|
||||
club.setState(club.getSponsorType() == 1 ? ClubRegistAuditState.UNIT_PART_READY : ClubRegistAuditState.XT_READY);
|
||||
if(club.getSponsorType() == 1) {
|
||||
// 如果申请是基层单位申请,设置归属工会
|
||||
Sql sql = Sqls.create("SELECT unionid AS unionId,unionname AS unionName FROM `user` WHERE id = @userId").setParam("userId", club.getUserid());
|
||||
sql.setCallback(Sqls.callback.map());
|
||||
dao.execute(sql);
|
||||
NutMap map = (NutMap) sql.getResult();
|
||||
club.setUnionId(map.getString("unionId"));
|
||||
club.setUnionName(map.getString("unionName"));
|
||||
|
||||
club.setState(ClubRegistAuditState.UNIT_PART_READY);
|
||||
} else {
|
||||
club.setState(ClubRegistAuditState.XT_READY);
|
||||
}
|
||||
// club.setState(club.getSponsorType() == 1 ? ClubRegistAuditState.UNIT_PART_READY : ClubRegistAuditState.XT_READY);
|
||||
club.setXtAuditId("");
|
||||
club.setXldAuditId("");
|
||||
club.setUnitPartAuditId("");
|
||||
|
||||
@@ -173,4 +173,14 @@ public class Sys_club {
|
||||
@Comment("发起类型(1.基层单位申请,2.协会发起人申请)")
|
||||
@ColDefine(type = ColType.INT, width = 10)
|
||||
private Integer sponsorType;
|
||||
|
||||
@Column
|
||||
@Comment("归属分工会id(如果是基层单位申请的协会)")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
private String unionId;
|
||||
|
||||
@Column
|
||||
@Comment("归属分工会名称(如果是基层单位申请的协会)")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 100)
|
||||
private String unionName;
|
||||
}
|
||||
|
||||
+19
-4
@@ -24,6 +24,7 @@ import io.v.nutz.zhgh.activity.models.ActivityTissuePerson;
|
||||
import io.v.nutz.zhgh.activity.services.ActivitySchoolService;
|
||||
import io.v.nutz.zhgh.activity.services.ActivityTissueService;
|
||||
import io.v.nutz.zhgh.mobileHome.service.MobileHomeService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.poi.ss.usermodel.Workbook;
|
||||
import org.apache.shiro.authz.annotation.Logical;
|
||||
import org.apache.shiro.authz.annotation.RequiresAuthentication;
|
||||
@@ -58,6 +59,7 @@ import java.util.List;
|
||||
* @description: 分工会活动信息管理
|
||||
**/
|
||||
|
||||
@Slf4j
|
||||
@IocBean
|
||||
@Ok("json:full")
|
||||
@At("/platform/activity/info/mange")
|
||||
@@ -315,7 +317,9 @@ public class ActivityUnionManageController {
|
||||
@At
|
||||
@Ok("void")
|
||||
@RequiresPermissions(value = {"activity.union.info", "activity.club.info", "activity.school.info2"}, logical = Logical.OR)
|
||||
public void doExportUser(String id, @Param(value = "unionId", required = false) String unionId, HttpServletResponse response) throws IOException {
|
||||
public void doExportUser(String id, @Param(value = "unionId", required = false) String unionId,
|
||||
@Param(value = "isSign", required = false) Boolean isSign,
|
||||
HttpServletResponse response) throws IOException {
|
||||
Sql sql = Sqls.create("""
|
||||
SELECT
|
||||
u.id,
|
||||
@@ -325,7 +329,9 @@ public class ActivityUnionManageController {
|
||||
u.unionname,
|
||||
u.sex,
|
||||
u.mobile,
|
||||
atp.applyDateTime
|
||||
atp.applyDateTime,
|
||||
IF(atp.isSign = 1, '已签到', '未签到') AS signState,
|
||||
signTime
|
||||
FROM
|
||||
`activity_tissue_person` atp
|
||||
LEFT JOIN `user` u ON u.id = atp.userId
|
||||
@@ -334,8 +340,13 @@ public class ActivityUnionManageController {
|
||||
Cnd cnd = Cnd.NEW();
|
||||
cnd.and("atp.tissueId", "=", id);
|
||||
cnd.andEX("u.unionId", "=", unionId);
|
||||
if (isSign) {
|
||||
cnd.and("atp.isSign", "=", 1);
|
||||
}
|
||||
sql.setCondition(cnd);
|
||||
|
||||
ActivityTissue tissue = tissuePersonService.dao().fetch(ActivityTissue.class, Cnd.where("id", "=", id));
|
||||
|
||||
List<ActivityTissuePerson> tissuePeople = tissuePersonService.listEntity(sql);
|
||||
List<ExcelExportEntity> entityList = new ArrayList<>();
|
||||
entityList.add(new ExcelExportEntity("姓名", "userName", 20));
|
||||
@@ -344,12 +355,16 @@ public class ActivityUnionManageController {
|
||||
entityList.add(new ExcelExportEntity("联系方式", "mobile", 20));
|
||||
entityList.add(new ExcelExportEntity("单位", "unitName", 20));
|
||||
entityList.add(new ExcelExportEntity("工会", "unionName", 20));
|
||||
if (isSign) {
|
||||
entityList.add(new ExcelExportEntity("签到状态", "singState", 20));
|
||||
entityList.add(new ExcelExportEntity("签到时间", "signTime", 20));
|
||||
}
|
||||
try {
|
||||
ViTool.excelResponse(response, "参赛人数.xls");
|
||||
ViTool.excelResponse(response, tissue.getName() + (isSign ? "签到" : "报名") + "人员信息表.xlsx");
|
||||
Workbook workbook = ExcelExportUtil.exportExcel(new ExportParams(), entityList, tissuePeople);
|
||||
workbook.write(response.getOutputStream());
|
||||
} catch (Exception e) {
|
||||
|
||||
log.error("参赛人员导出失败:{}", e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+9
-4
@@ -12,6 +12,7 @@ import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
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.ioc.loader.annotation.Inject;
|
||||
import org.nutz.ioc.loader.annotation.IocBean;
|
||||
import org.nutz.lang.Lang;
|
||||
@@ -81,7 +82,6 @@ public class ActivityUnionUserStatisticsController {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Sql sql = Sqls.create("""
|
||||
@@ -95,7 +95,9 @@ public class ActivityUnionUserStatisticsController {
|
||||
u.mobile,
|
||||
atp.applyUserId,
|
||||
atp.id atpId ,
|
||||
atp.applyDateTime
|
||||
atp.applyDateTime,
|
||||
IF(atp.isSign = 1, '已签到', '未签到') AS signState,
|
||||
signTime
|
||||
FROM
|
||||
`activity_tissue_person` atp
|
||||
LEFT JOIN `user` u ON u.id = atp.userId
|
||||
@@ -113,8 +115,11 @@ public class ActivityUnionUserStatisticsController {
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
if (Strings.isNotBlank(page.getSearchName()) && Strings.isNotBlank(page.getSearchKeyword())) {
|
||||
cnd.where().andLike(page.getSearchName(), page.getSearchKeyword());
|
||||
if (StrUtil.isNotBlank(page.getSearchKeyword())) {
|
||||
SqlExpressionGroup seg = new SqlExpressionGroup();
|
||||
seg.or("u.loginname", "LIKE", "%" + page.getSearchKeyword() + "%");
|
||||
seg.or("u.username", "LIKE", "%" + page.getSearchKeyword() + "%");
|
||||
cnd.and(seg);
|
||||
}
|
||||
if (StrUtil.isNotBlank(page.getPageOrderName()) && StrUtil.isNotBlank(page.getPageOrderBy())) {
|
||||
cnd.orderBy(page.getPageOrderName(), page.getPageOrderBy().equalsIgnoreCase("ascending") ? "ASC" : "DESC");
|
||||
|
||||
@@ -8,6 +8,7 @@ import cn.afterturn.easypoi.excel.entity.enmus.ExcelType;
|
||||
import cn.afterturn.easypoi.excel.entity.params.ExcelExportEntity;
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import cn.hutool.core.io.IoUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.wizzer.framework.base.Result;
|
||||
import cn.wizzer.framework.base.service.BaseService;
|
||||
@@ -38,6 +39,7 @@ import org.nutz.dao.Dao;
|
||||
import org.nutz.dao.Sqls;
|
||||
import org.nutz.dao.entity.Record;
|
||||
import org.nutz.dao.sql.Sql;
|
||||
import org.nutz.dao.util.cri.SqlExpressionGroup;
|
||||
import org.nutz.ioc.aop.Aop;
|
||||
import org.nutz.ioc.loader.annotation.Inject;
|
||||
import org.nutz.ioc.loader.annotation.IocBean;
|
||||
@@ -111,11 +113,11 @@ public class JdhDbGlController {
|
||||
|
||||
Sql sql = Sqls.create("""
|
||||
SELECT
|
||||
u.username,
|
||||
u.loginname,
|
||||
u.sex,
|
||||
u.mobile,
|
||||
TIMESTAMPDIFF(YEAR, u.birthday,CURDATE()) as age,
|
||||
db.dbLoginName AS loginname,
|
||||
db.dbUserName AS username,
|
||||
db.dbSex AS sex,
|
||||
db.dbMobile AS mobile,
|
||||
TIMESTAMPDIFF(YEAR, db.dbBirthday,CURDATE()) as age,
|
||||
db.political,
|
||||
db.education,
|
||||
db.jobTitle,
|
||||
@@ -146,8 +148,11 @@ public class JdhDbGlController {
|
||||
Cnd cnd = Cnd.NEW();
|
||||
cnd.groupBy("db.id");
|
||||
cnd.and("db.dbzt", "=", 2);
|
||||
if (Strings.isNotBlank(searchName) && Strings.isNotBlank(searchKeyword)) {
|
||||
cnd.and(searchName, "LIKE", "%" + searchKeyword + "%");
|
||||
if (StrUtil.isNotBlank(searchKeyword)) {
|
||||
SqlExpressionGroup seg = new SqlExpressionGroup();
|
||||
seg.orLike("db.dbUserName", searchKeyword);
|
||||
seg.orLike("db.dbLoginName", searchKeyword);
|
||||
cnd.and(seg);
|
||||
}
|
||||
if (Strings.isNotBlank(jdhid)) {
|
||||
cnd.and("db.jdhid", "=", jdhid);
|
||||
@@ -227,6 +232,12 @@ public class JdhDbGlController {
|
||||
db.setDbunitname(userMap.getString("dwname"));
|
||||
db.setDbfghid(userMap.getString("ghid"));
|
||||
db.setDbfghname(userMap.getString("unionname"));
|
||||
db.setDbLoginName(userMap.getString("loginname"));
|
||||
db.setDbUserName(userMap.getString("username"));
|
||||
db.setDbSex(ObjectUtil.defaultIfBlank(userMap.getString("sex"), ""));
|
||||
db.setDbBirthday(ObjectUtil.defaultIfBlank(userMap.getString("birthday"), ""));
|
||||
db.setDbMobile(ObjectUtil.defaultIfBlank(userMap.getString("mobile"), ""));
|
||||
db.setDbNation(ObjectUtil.defaultIfBlank(userMap.getString("nation"), ""));
|
||||
db.setDbtid(dbtid);
|
||||
db.setJdhid(jdhid);
|
||||
db.setDbzt(2);
|
||||
@@ -303,8 +314,10 @@ public class JdhDbGlController {
|
||||
u.education,
|
||||
u.position,
|
||||
u.mobile,
|
||||
u.birthday,
|
||||
u.nation,
|
||||
dw.id AS dwid,
|
||||
dw.NAME AS dwname,
|
||||
dw.`name` AS dwname,
|
||||
gh.id AS ghid,
|
||||
gh.unionname
|
||||
FROM
|
||||
@@ -338,6 +351,13 @@ public class JdhDbGlController {
|
||||
db.setId(R.UU32());
|
||||
db.setDbid(userMap.getString("id"));
|
||||
|
||||
db.setDbLoginName(userMap.getString("loginname"));
|
||||
db.setDbUserName(userMap.getString("username"));
|
||||
db.setDbSex(ObjectUtil.defaultIfBlank(userMap.getString("sex"), ""));
|
||||
db.setDbBirthday(ObjectUtil.defaultIfBlank(userMap.getString("birthday"), ""));
|
||||
db.setDbMobile(ObjectUtil.defaultIfBlank(userMap.getString("mobile"), ""));
|
||||
db.setDbNation(ObjectUtil.defaultIfBlank(userMap.getString("nation"), ""));
|
||||
|
||||
db.setPolitical(userMap.getString("political"));
|
||||
db.setEducation(userMap.getString("education"));
|
||||
db.setJobTitle(userMap.getString("jobTitle"));
|
||||
@@ -513,6 +533,13 @@ public class JdhDbGlController {
|
||||
Jdh_db db = new Jdh_db();
|
||||
db.setId(R.UU32());
|
||||
db.setDbid(userMap.getString("id"));
|
||||
db.setDbLoginName(loginName);
|
||||
db.setDbUserName(userMap.getString("username"));
|
||||
db.setDbSex(userMap.getString("sex"));
|
||||
db.setDbBirthday(userMap.getString("birthday"));
|
||||
db.setDbMobile(userMap.getString("mobile"));
|
||||
db.setDbNation(userMap.getString("nation"));
|
||||
|
||||
db.setPolitical(userMap.getString("political"));
|
||||
db.setEducation(userMap.getString("education"));
|
||||
db.setJobTitle(userMap.getString("jobTitle"));
|
||||
|
||||
@@ -144,26 +144,33 @@ public class JdhDbScmdController {
|
||||
public Object queryNotDbUser(String jdhid, String dbtid, String keyword) {
|
||||
try {
|
||||
Sql sql = Sqls.create("""
|
||||
SELECT
|
||||
u.id,u.loginname,u.username,dw.id as dwid,dw.name as dwname,
|
||||
gh.id as ghid,gh.unionname,
|
||||
u.political,
|
||||
u.education,
|
||||
u.jobTitle,
|
||||
u.position
|
||||
FROM
|
||||
sys_user u
|
||||
LEFT JOIN sys_unit dw ON dw.id = u.unitid
|
||||
LEFT JOIN sys_union gh ON gh.id = dw.unionid
|
||||
SELECT
|
||||
u.id,
|
||||
u.loginname,
|
||||
u.username,
|
||||
u.unitid as dwid,
|
||||
u.unitname as dwname,
|
||||
gh.id as ghid,
|
||||
gh.unionname,
|
||||
u.political,
|
||||
u.education,
|
||||
u.jobTitle,
|
||||
u.position,
|
||||
u.birthday,
|
||||
u.sex,
|
||||
u.nation,
|
||||
u.mobile
|
||||
FROM
|
||||
`user` u
|
||||
$condition
|
||||
AND u.id NOT IN ( SELECT dbid FROM jdh_db WHERE jdhid = @jdhid AND dbzt in (1,2) )
|
||||
AND (u.username like @keyword or u.loginname like @keyword)
|
||||
""");
|
||||
AND u.id NOT IN ( SELECT dbid FROM jdh_db WHERE jdhid = @jdhid AND dbzt in (1,2) )
|
||||
AND (u.username like @keyword or u.loginname like @keyword)
|
||||
""");
|
||||
Cnd cnd = Cnd.NEW();
|
||||
if ("unit".equals(Globals.MyConfig.getString("dbtzc"))) {
|
||||
cnd.and(new Static(" dw.id in (select dwid from jdh_dbt_zcdw where jdhid='%s' and dbtid='%s' )".formatted(jdhid, dbtid)));
|
||||
cnd.and(new Static(" u.unitid IN (select dwid from jdh_dbt_zcdw where jdhid='%s' and dbtid='%s' )".formatted(jdhid, dbtid)));
|
||||
} else {
|
||||
cnd.and(new Static("gh.id IN ( SELECT fghid FROM jdh_dbt_zcfgh WHERE jdhid = '%s' AND dbtid = '%s' )".formatted(jdhid, dbtid)));
|
||||
cnd.and(new Static(" u.unionid IN ( SELECT fghid FROM jdh_dbt_zcfgh WHERE jdhid = '%s' AND dbtid = '%s' )".formatted(jdhid, dbtid)));
|
||||
}
|
||||
sql.setCondition(cnd);
|
||||
sql.setParam("jdhid", jdhid);
|
||||
|
||||
@@ -29,6 +29,7 @@ import org.nutz.dao.Cnd;
|
||||
import org.nutz.dao.Sqls;
|
||||
import org.nutz.dao.entity.Record;
|
||||
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.lang.Lang;
|
||||
@@ -94,13 +95,12 @@ public class JdhDbYlController {
|
||||
try {
|
||||
Sql sql = Sqls.create("""
|
||||
SELECT
|
||||
u.username,
|
||||
u.loginname,
|
||||
u.sex,
|
||||
u.mobile,
|
||||
TIMESTAMPDIFF(YEAR, u.birthday,CURDATE()) as age,
|
||||
u.unionname,
|
||||
u.unioncode,
|
||||
db.dbLoginName AS loginname,
|
||||
db.dbUserName AS username,
|
||||
db.dbSex AS sex,
|
||||
db.dbMobile AS mobile,
|
||||
TIMESTAMPDIFF(YEAR, db.dbBirthday,CURDATE()) as age,
|
||||
db.dbfghname AS unionname,
|
||||
db.id,
|
||||
db.dbid,
|
||||
db.jdhid,
|
||||
@@ -114,7 +114,6 @@ public class JdhDbYlController {
|
||||
r.`name` as rolename
|
||||
FROM
|
||||
jdh_db db
|
||||
LEFT JOIN `user` u ON u.id = db.dbid
|
||||
LEFT JOIN sys_role r ON r.id = db.roleid
|
||||
LEFT JOIN jdh_dbt dbt ON dbt.id = db.dbtid
|
||||
LEFT JOIN jdh_jdhxx jdh on jdh.id = db.jdhid
|
||||
@@ -127,8 +126,11 @@ public class JdhDbYlController {
|
||||
} else {
|
||||
cnd.desc("jdh.jdhkqsj").asc("dbt.dbtname").asc("db.dbunitname");
|
||||
}
|
||||
if (Strings.isNotBlank(searchName) && Strings.isNotBlank(searchKeyword)) {
|
||||
cnd.and(searchName, "LIKE", "%" + searchKeyword + "%");
|
||||
if (StrUtil.isNotBlank(searchKeyword)) {
|
||||
SqlExpressionGroup seg = new SqlExpressionGroup();
|
||||
seg.orLike("db.dbUserName", searchKeyword);
|
||||
seg.orLike("db.dbLoginName", searchKeyword);
|
||||
cnd.and(seg);
|
||||
}
|
||||
if (Strings.isNotBlank(jdhid)) {
|
||||
cnd.and("db.jdhid", "=", jdhid);
|
||||
@@ -151,7 +153,7 @@ public class JdhDbYlController {
|
||||
}
|
||||
|
||||
if (!ShiroUtil.hasAnyRoles("sysadmin,SchoolUnionAdmin,tamange")) {
|
||||
cnd.and("u.unionid", "=", Vi.getUnionId());
|
||||
cnd.and("db.dbfghid", "=", Vi.getUnionId());
|
||||
}
|
||||
|
||||
sql.setCondition(cnd);
|
||||
@@ -171,15 +173,52 @@ public class JdhDbYlController {
|
||||
@At
|
||||
@RequiresPermissions("jdh.db.dbyl")
|
||||
public void downloadDbList(@Param(value = "jdh_id",required = false) String jdh_id, HttpServletResponse response) throws Exception {
|
||||
Sql dbtSql = Sqls.create("SELECT dbt.*,(SELECT count(1) from jdh_db db WHERE db.dbtid = dbt.id) " +
|
||||
"dbnum from jdh_dbt dbt where dbt.jdhid = @jdhid ORDER BY dbt.code").setParam("jdhid", jdh_id);
|
||||
Sql dbSql = Sqls.create("SELECT u.id,(case u.sex when '女' then CONCAT(u.username,'(女)') else u.username end) " +
|
||||
"username,u.nation mz,db.dbtid,db.roleid from jdh_db db left join sys_user u on db.dbid = u.id " +
|
||||
"WHERE db.dbzt = 2 and db.jdhid = @jdhid ORDER BY u.username").setParam("jdhid", jdh_id);
|
||||
Sql tzSql = Sqls.create("SELECT u.id,(case u.sex when '女' then CONCAT(u.username,'(女)') else u.username end) " +
|
||||
"username,u.nation mz,sur.dbtid,sur.roleId roleid from sys_user_role sur left join sys_user u on sur.userId = u.id " +
|
||||
"WHERE sur.roleId in (@tz_role_id,@ftz_role_id) and sur.jdhid = @jdhid ORDER BY u.username")
|
||||
.setParam("tz_role_id", Roles.DBT_TZ).setParam("ftz_role_id", Roles.DBT_FTZ).setParam("jdhid", jdh_id);
|
||||
Sql dbtSql = Sqls.create("""
|
||||
SELECT
|
||||
dbt.*,
|
||||
(SELECT count(1) FROM jdh_db db WHERE db.dbtid = dbt.id) dbnum
|
||||
FROM
|
||||
jdh_dbt dbt
|
||||
WHERE
|
||||
dbt.jdhid = @jdhid
|
||||
ORDER BY
|
||||
dbt.`code`
|
||||
""").setParam("jdhid", jdh_id);
|
||||
|
||||
Sql dbSql = Sqls.create("""
|
||||
SELECT
|
||||
db.dbid AS id,
|
||||
(CASE db.dbSex WHEN '女' THEN CONCAT(db.dbUsername, '(女)') ELSE db.dbUsername END) username,
|
||||
db.dbNation AS mz,
|
||||
db.dbtid,
|
||||
db.roleid
|
||||
FROM
|
||||
jdh_db db
|
||||
WHERE
|
||||
db.dbzt = 2
|
||||
AND db.jdhid = @jdhid
|
||||
ORDER BY
|
||||
db.dbUserName
|
||||
""").setParam("jdhid", jdh_id);
|
||||
|
||||
Sql tzSql = Sqls.create("""
|
||||
SELECT
|
||||
db.dbid AS id,
|
||||
(CASE db.dbSex WHEN '女' THEN CONCAT(db.dbUsername, '(女)') ELSE db.dbUsername END) username,
|
||||
db.dbNation AS mz,
|
||||
sur.dbtid,
|
||||
sur.roleId roleid
|
||||
FROM
|
||||
sys_user_role sur
|
||||
LEFT JOIN jdh_db db ON sur.userId = db.dbid
|
||||
WHERE
|
||||
sur.roleId IN (@tz_role_id, @ftz_role_id)
|
||||
AND sur.jdhid = @jdhid
|
||||
GROUP BY
|
||||
db.id
|
||||
ORDER BY
|
||||
db.dbUserName
|
||||
""").setParam("tz_role_id", Roles.DBT_TZ).setParam("ftz_role_id", Roles.DBT_FTZ).setParam("jdhid", jdh_id);
|
||||
|
||||
List<Record> dbtList = baseService.list(dbtSql);
|
||||
List<Record> dbs = baseService.list(dbSql);
|
||||
@@ -243,7 +282,7 @@ public class JdhDbYlController {
|
||||
Jdh_jdhxx jdhxx = baseService.dao().fetch(Jdh_jdhxx.class, jdhid);
|
||||
|
||||
//只查询开启教代会的代表
|
||||
Sql sql = Sqls.create("""
|
||||
/*Sql sql = Sqls.create("""
|
||||
SELECT
|
||||
u.loginname,
|
||||
u.username,
|
||||
@@ -266,16 +305,16 @@ public class JdhDbYlController {
|
||||
dbt.code,
|
||||
u.unioncode,
|
||||
u.unitcode
|
||||
""").setParam("jdhid", jdhid);
|
||||
""").setParam("jdhid", jdhid);*/
|
||||
|
||||
Sql sql2 = Sqls.create("""
|
||||
SELECT
|
||||
u.loginname,
|
||||
u.username,
|
||||
u.sex,
|
||||
u.mobile,
|
||||
u.unitname,
|
||||
u.unionname,
|
||||
db.dbLoginName AS loginname,
|
||||
db.dbUserName AS username,
|
||||
db.dbSex AS sex,
|
||||
db.dbMobile AS mobile,
|
||||
db.dbunitname AS unitname,
|
||||
db.dbfghname AS unionname,
|
||||
dbt.dbtname,
|
||||
CONCAT( jdh.jdhjs, '届', jdh.jdhcs, '次' ) jdh,
|
||||
role.`name` rolename
|
||||
@@ -312,7 +351,7 @@ public class JdhDbYlController {
|
||||
}
|
||||
|
||||
response.setContentType("application/octet-stream");
|
||||
response.setHeader("Content-Disposition", "attachment;filename=" + new String((jdhxx.getJdhjs() + "届" + jdhxx.getJdhcs() + "次" + "教代会代表名单.xls").getBytes("utf-8"), "ISO8859-1"));
|
||||
response.setHeader("Content-Disposition", "attachment;filename=" + new String((jdhxx.getJdhjs() + "届" + jdhxx.getJdhcs() + "次" + "教代会代表名单.xlsx").getBytes("utf-8"), "ISO8859-1"));
|
||||
Workbook workbook = ExcelExportUtil.exportExcel(new ExportParams(), DB.class, dbs);
|
||||
workbook.write(response.getOutputStream());
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ import cn.wizzer.framework.page.Pagination;
|
||||
import io.v.nutz.base.annontation.ViReturn;
|
||||
import io.v.nutz.base.utils.DateUtil;
|
||||
import io.v.nutz.base.utils.Roles;
|
||||
import io.v.nutz.sys.models.User;
|
||||
import io.v.nutz.zhgh.jdh.model.db.Jdh_db;
|
||||
import io.v.nutz.zhgh.jdh.model.zzjg.Jdh_dbt;
|
||||
import io.v.nutz.zhgh.jdh.model.zzjg.Jdh_dbt_zcdw;
|
||||
@@ -32,6 +33,9 @@ import org.nutz.mvc.annotation.Param;
|
||||
import org.nutz.trans.Trans;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* @author zhf
|
||||
@@ -570,9 +574,9 @@ public class DelegationController {
|
||||
PageForm page, @Param(value = "jdhid", required = false) String jdhid) {
|
||||
Sql sql = Sqls.create("""
|
||||
SELECT
|
||||
u.id,
|
||||
u.loginname,
|
||||
u.username,
|
||||
db.dbid AS id,
|
||||
db.dbLoginName AS loginname,
|
||||
db.dbUserName AS username,
|
||||
db.dbunitname as unitname,
|
||||
db.dbfghname as unionname,
|
||||
r.`name` as rolename
|
||||
@@ -599,4 +603,32 @@ public class DelegationController {
|
||||
sql.setCondition(cnd);
|
||||
return sysUserRoleService.list(sql);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@At
|
||||
@ViReturn
|
||||
@RequiresPermissions("sys.jdh.zzjg.delegation")
|
||||
public Object setDbInfo() {
|
||||
List<Jdh_db> list = dao.query(Jdh_db.class, Cnd.NEW());
|
||||
|
||||
Set<String> userIds = list.stream().map(Jdh_db::getDbid).collect(Collectors.toSet());
|
||||
|
||||
List<User> query = dao.query(User.class, Cnd.where("id", "in", userIds));
|
||||
|
||||
Map<String, User> userMap = query.stream().collect(Collectors.toMap(User::getId, v -> v));
|
||||
|
||||
for (Jdh_db db : list) {
|
||||
User user = userMap.get(db.getDbid());
|
||||
db.setDbUserName(user.getUsername());
|
||||
db.setDbLoginName(user.getLoginname());
|
||||
db.setDbSex(user.getSex());
|
||||
db.setDbBirthday(user.getBirthday());
|
||||
db.setDbMobile(user.getMobile());
|
||||
db.setDbNation(user.getNation());
|
||||
}
|
||||
|
||||
dao.update(list);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,6 +26,36 @@ public class Jdh_db implements Serializable {
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
private String dbid;
|
||||
|
||||
@Column
|
||||
@Comment("代表工号")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
private String dbLoginName;
|
||||
|
||||
@Column
|
||||
@Comment("代表姓名")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
private String dbUserName;
|
||||
|
||||
@Column
|
||||
@Comment("代表性别")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 10)
|
||||
private String dbSex;
|
||||
|
||||
@Column
|
||||
@Comment("代表生日")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
private String dbBirthday;
|
||||
|
||||
@Column
|
||||
@Comment("代表联系方式")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
private String dbMobile;
|
||||
|
||||
@Column
|
||||
@Comment("代表民族")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
private String dbNation;
|
||||
|
||||
@Column
|
||||
@Comment("所属教代会ID")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
|
||||
@@ -64,7 +64,7 @@ public class H5QsvQuizController {
|
||||
|
||||
int count = dao.count(ActivityUserScope.class, Cnd.where("groupId", "=", activity.getGroupId()).and("userId", "=", ShiroUtil.getUserId()));
|
||||
if (count != 1) {
|
||||
return Result.error("您无需参加此次知识竞赛,感谢您的关注!");
|
||||
return Result.error("您无需参加此次答题,感谢您的关注!");
|
||||
}
|
||||
|
||||
String mode = activity.getMode();
|
||||
@@ -76,6 +76,8 @@ public class H5QsvQuizController {
|
||||
Integer maxAttempts = activity.getMaxAttempts();
|
||||
//题目显示模式
|
||||
String displayMode = activity.getDisplayMode();
|
||||
// 重复答题,显示提示
|
||||
Boolean repeatTips = false;
|
||||
|
||||
//最终返回的题目数据
|
||||
List<QsvSubject> resultSubjects = new ArrayList<>();
|
||||
@@ -161,6 +163,7 @@ public class H5QsvQuizController {
|
||||
String dynamic = subjectIds.stream().map(id -> "'" + id + "'").collect(Collectors.joining(","));
|
||||
cnd.and(new Static("1=1 ORDER BY FIELD (id," + dynamic + ")"));
|
||||
resultSubjects = dao.query(QsvSubject.class, cnd);
|
||||
repeatTips = true;
|
||||
} else {
|
||||
//已达到最大次数 返回最新一次记录
|
||||
Optional<QsvUserAnswerRecord> maxAnswerRecordOptional = answerRecords.stream().max(Comparator.comparingLong(QsvUserAnswerRecord::getRandomNumber));
|
||||
@@ -306,7 +309,8 @@ public class H5QsvQuizController {
|
||||
|
||||
resultSubjects.forEach(v -> v.setUserSelectOptionIds(new ArrayList<>()));
|
||||
|
||||
NutMap result = NutMap.NEW().addv("subjects", resultSubjects).addv("answerRecordId", answerRecordId).addv("activity", activity);
|
||||
NutMap result = NutMap.NEW().addv("subjects", resultSubjects).addv("answerRecordId", answerRecordId)
|
||||
.addv("activity", activity).addv("repeatTips", repeatTips);
|
||||
return Result.success(result);
|
||||
}
|
||||
|
||||
|
||||
@@ -93,6 +93,7 @@ public class QsvQuizRankServiceImpl extends BaseServiceImpl<QsvUserAnswerRecord>
|
||||
t1.userId,
|
||||
t1.userName,
|
||||
t1.loginName,
|
||||
u.sex,
|
||||
t1.unitName,
|
||||
t1.unionName,
|
||||
u.mobile,
|
||||
|
||||
@@ -319,10 +319,15 @@ public class WelfareProjectMangeController {
|
||||
Set<String> loginNameList = userList.stream().map(user -> user.getString("loginname")).collect(Collectors.toSet());
|
||||
String loginNames = loginNameList.stream().collect(Collectors.joining(","));
|
||||
|
||||
WelfareProject project = dao.fetch(WelfareProject.class, projectId);
|
||||
// WelfareProject project = dao.fetch(WelfareProject.class, projectId);
|
||||
String link = Globals.AppDomain + "/mobile/welfare/list/receive?projectId=%s".formatted(projectId);
|
||||
// String imageUrl = Globals.AppDomain + "/file_server/fileStreamPreview?id=" + project.getCover();
|
||||
msgApi.sendMsg(List.of("DingTalk"), loginNames, 2, "职工福利", sendMsgValue, "", link);
|
||||
// msgApi.sendMsg(List.of("DingTalk"), loginNames, 2, "职工福利", sendMsgValue, "", link);
|
||||
if ("51e3449b5f234dd58757de63142d6b48".equals(projectId)) {
|
||||
msgApi.sendMsg(List.of("DingTalk"), loginNames, 2, "答题纪念品!点开有惊喜!", sendMsgValue, "", link);
|
||||
} else {
|
||||
msgApi.sendMsg(List.of("DingTalk"), loginNames, 2, "职工福利", sendMsgValue, "", link);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
@@ -125,6 +125,7 @@ layout("/mobile/platform.html"){
|
||||
return {
|
||||
list: [],
|
||||
id: GetQueryString("id"),
|
||||
H5JumpTo: GetQueryString("H5JumpTo"),
|
||||
subjects: [],
|
||||
activity: {},
|
||||
// remainingTime: 0,
|
||||
@@ -162,7 +163,22 @@ layout("/mobile/platform.html"){
|
||||
this.subjects = res.data.subjects
|
||||
this.answerRecordId = res.data.answerRecordId
|
||||
// this.checkGroupPermission()
|
||||
this.getAnswerRecord()
|
||||
if (!this.H5JumpTo && this.activity.repeatable && res.data.repeatTips){
|
||||
// 如果是可重复答题,第二次答题进来弹出提示
|
||||
vant.Dialog.confirm({
|
||||
title: '温馨提示',
|
||||
message: '您已完成本次答题,是否要重新答题?',
|
||||
confirmButtonText: '重新答题',
|
||||
cancelButtonText: '查看答题记录',
|
||||
}).then(() => {
|
||||
this.getAnswerRecord()
|
||||
}).catch(() => {
|
||||
pjaxReplace("/platform/h5/qsv/quiz/result?answerRecordId=" + this.answerRecordId)
|
||||
// pjaxReplace("/mobile/index")
|
||||
});
|
||||
} else {
|
||||
this.getAnswerRecord()
|
||||
}
|
||||
} else {
|
||||
vant.Dialog.alert({
|
||||
title: '温馨提示',
|
||||
@@ -181,7 +197,7 @@ layout("/mobile/platform.html"){
|
||||
this.answerRecord = res.data
|
||||
|
||||
if (this.answerRecord.isFinish || this.$moment().unix() > this.$moment(this.activity.endTime)) {
|
||||
this.$pjaxReplace("/platform/h5/qsv/quiz/result?answerRecordId=" + this.answerRecordId)
|
||||
pjaxReplace("/platform/h5/qsv/quiz/result?answerRecordId=" + this.answerRecordId)
|
||||
}
|
||||
|
||||
this.initAnswer()
|
||||
|
||||
@@ -210,6 +210,8 @@ layout("/mobile/platform.html"){
|
||||
|
||||
<div class="button-control">
|
||||
<van-button v-if="canAgainQuestion" type="primary" @click="againQuestion" block>重新答题</van-button>
|
||||
<!-- 女性知识答题 -->
|
||||
<van-button v-if="activity.id === 'c3372eb3ee774e86b373fcacf8eb89c7'" type="primary" @click="goWelfareChoose" block>纪念品选择</van-button>
|
||||
<van-button type="primary" @click="openHistory" block>查看全部答题记录</van-button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -272,6 +274,13 @@ layout("/mobile/platform.html"){
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 福利选择
|
||||
*/
|
||||
goWelfareChoose(){
|
||||
// 女性答题的福利
|
||||
pjaxReplace('/mobile/welfare/list/receive?projectId=8799d66b0bb640078f50feb029e506ed')
|
||||
},
|
||||
/**
|
||||
* 重新答题
|
||||
*/
|
||||
@@ -280,7 +289,7 @@ layout("/mobile/platform.html"){
|
||||
title: '温馨提示',
|
||||
message: '确定要重新答题吗?',
|
||||
}).then(() => {
|
||||
pjaxReplace('/platform/h5/qsv/quiz?id=' + this.activity.id)
|
||||
pjaxReplace('/platform/h5/qsv/quiz?id=' + this.activity.id + "&H5JumpTo=true")
|
||||
}).catch(() => {
|
||||
// on cancel
|
||||
});
|
||||
@@ -290,8 +299,19 @@ layout("/mobile/platform.html"){
|
||||
if (res.code === 0) {
|
||||
this.subjects = res.data.subjects
|
||||
this.activity = res.data.activity
|
||||
this.getAnswerRecord()
|
||||
this.getHistoryQuestion()
|
||||
|
||||
if (this.activity.id === 'c3372eb3ee774e86b373fcacf8eb89c7') {
|
||||
vant.Dialog.alert({
|
||||
title: '温馨提示',
|
||||
message: "感谢您参与女性健康知识竞赛。请选取活动纪念品",
|
||||
}).then(() => {
|
||||
this.getAnswerRecord()
|
||||
this.getHistoryQuestion()
|
||||
})
|
||||
} else {
|
||||
this.getAnswerRecord()
|
||||
this.getHistoryQuestion()
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
@@ -649,15 +649,26 @@ layout("/mobile/platform.html"){
|
||||
})
|
||||
if (code === 0) {
|
||||
this.getUserSelection(this.projectId)
|
||||
this.$modal.msgSuccess("您已完成本次福利选择。")
|
||||
// 女性健康知识讲座福利品Id
|
||||
if (this.projectId === '8799d66b0bb640078f50feb029e506ed') {
|
||||
pjaxReplace('/mobile/welfare/list/receive_success?projectId=' + this.projectId + '&provideMode=' + this.projectInfo.provideMode)
|
||||
} else {
|
||||
vant.Dialog.alert({
|
||||
title: '温馨提示',
|
||||
message: "您已完成本次福利选择。",
|
||||
}).then(async () => {
|
||||
this.confirmPopup = false
|
||||
await this.getProjectInfo()
|
||||
window.location.reload()
|
||||
});
|
||||
}
|
||||
// this.$modal.msgSuccess("您已完成本次福利选择。")
|
||||
} else {
|
||||
this.$modal.msgError(msg)
|
||||
}
|
||||
this.confirmPopup = false
|
||||
await this.getProjectInfo()
|
||||
setTimeout(() => {
|
||||
this.confirmPopup = false
|
||||
await this.getProjectInfo()
|
||||
window.location.reload()
|
||||
}, 1000)
|
||||
}
|
||||
},
|
||||
|
||||
//查看详情
|
||||
|
||||
@@ -9,7 +9,7 @@ layout("/mobile/platform.html"){
|
||||
<div id="app" v-cloak>
|
||||
<van-sticky>
|
||||
<van-nav-bar :title="title" left-arrow
|
||||
@click-left="history.back()"></van-nav-bar>
|
||||
@click-left="back"></van-nav-bar>
|
||||
</van-sticky>
|
||||
|
||||
<div style="text-align: center;margin-top: 200px;">
|
||||
@@ -25,7 +25,8 @@ layout("/mobile/platform.html"){
|
||||
</svg>
|
||||
<div style="margin-top: 20px;">{{code=='2' ? '您已领取' : '您已选择'}}</div>
|
||||
<div style="margin: 20px auto 0px auto;width: 300px;word-break: break-all">
|
||||
福利品: {{selectOptionNames}}
|
||||
<!-- 女性健康知识讲座福利品Id -->
|
||||
{{ projectId == '8799d66b0bb640078f50feb029e506ed' ? '纪念品' : '福利品' }}: {{selectOptionNames}}
|
||||
</div>
|
||||
<van-button style="margin-top: 20px;width: 100px" size="small" hairline type="primary"
|
||||
@click="back">返回
|
||||
@@ -43,6 +44,7 @@ layout("/mobile/platform.html"){
|
||||
mixins: [mobileMixins, welfareMixins],
|
||||
data() {
|
||||
return {
|
||||
projectId: '',
|
||||
selectOptionNames: null
|
||||
}
|
||||
},
|
||||
@@ -52,7 +54,7 @@ layout("/mobile/platform.html"){
|
||||
this.selectOptionNames = resp.data
|
||||
},
|
||||
back() {
|
||||
window.history.go(-1)
|
||||
pjaxReplace('/mobile/welfare/list/receive?projectId=' + this.projectId)
|
||||
}
|
||||
},
|
||||
created() {
|
||||
|
||||
@@ -54,7 +54,7 @@ layout("/mobile/platform.html"){
|
||||
|
||||
<div id="app" v-cloak>
|
||||
<van-sticky>
|
||||
<van-nav-bar @click-left="pjaxReplace('/mobile//index')" left-arrow
|
||||
<van-nav-bar @click-left="pjaxReplace('/mobile/index')" left-arrow
|
||||
title="我的福利"></van-nav-bar>
|
||||
|
||||
<van-dropdown-menu active-color="#1989fa">
|
||||
|
||||
@@ -50,24 +50,17 @@
|
||||
</div>
|
||||
|
||||
<div class="search-item">
|
||||
<div class="search-item-label">姓名/工号</div>
|
||||
<div class="search-item-label">姓名工号</div>
|
||||
<div class="search-item-option">
|
||||
<el-input @keyup.enter.native="doSearch" clearable
|
||||
placeholder="请输入姓名/工号"
|
||||
placeholder="请输入姓名或工号查询"
|
||||
v-model="pageForm.searchKeyword">
|
||||
<el-select placeholder="姓名/工号" slot="prepend"
|
||||
style="width: 80px;"
|
||||
v-model="pageForm.searchName">
|
||||
<el-option label="姓名" value="u.username"></el-option>
|
||||
<el-option label="工号" value="u.loginanme"></el-option>
|
||||
</el-select>
|
||||
</el-input>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="search-query">
|
||||
<el-button @click="pageData" icon="el-icon-search" type="primary">搜索
|
||||
</el-button>
|
||||
<el-button @click="pageData" icon="el-icon-search" type="primary">搜索</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</el-card>
|
||||
@@ -76,6 +69,7 @@
|
||||
<el-card class="mt10" shadow="never">
|
||||
<table-tool :app="this" label="人员列表">
|
||||
<template #func>
|
||||
<el-button @click="doExportSign" icon="el-icon-s-promotion" type="primary" size="small">导出签到人员</el-button>
|
||||
<el-button @click="doExport" icon="el-icon-s-promotion" type="primary" size="small">导出</el-button>
|
||||
</template>
|
||||
</table-tool>
|
||||
@@ -95,6 +89,10 @@
|
||||
header-align="center"
|
||||
sortable
|
||||
v-for="column in tableColumns">
|
||||
<template scope="{row}" v-if="column.prop=='signTime'">
|
||||
<span v-if="row.signTime">{{ row.signTime }}</span>
|
||||
<el-tag v-else type="warning">暂无</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" header-align="center" label="操作"
|
||||
v-if="${@shiro.hasRole('sysadmin')}"
|
||||
@@ -125,7 +123,6 @@
|
||||
activityList: {},
|
||||
pageForm: {
|
||||
unionId: '',
|
||||
searchName: "u.username",
|
||||
type: type,
|
||||
year: new Date().getFullYear() + ''
|
||||
},
|
||||
@@ -138,6 +135,8 @@
|
||||
{prop: 'unionname', label: '所属工会'},
|
||||
{prop: 'applyDateTime', label: '报名时间'}
|
||||
],
|
||||
// 这个活动是否签字
|
||||
showSignExport: false,
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -159,8 +158,7 @@
|
||||
},
|
||||
async doExport() {
|
||||
const {activityId, unionId} = this.pageForm
|
||||
window.open("/platform/activity/info/mange/doExportUser?id=" + activityId +
|
||||
"&unionId=" + unionId)
|
||||
window.open("/platform/activity/info/mange/doExportUser?id=" + activityId + "&unionId=" + unionId + "&isSign=false")
|
||||
},
|
||||
pageData() {
|
||||
sublime.showLoadingbar();
|
||||
@@ -185,12 +183,26 @@
|
||||
this.activityList = resp.data
|
||||
if (resp.data && resp.data.length > 0) {
|
||||
this.$set(this.pageForm, "activityId", resp.data[0].id)
|
||||
if (resp.data[0].needSign) {
|
||||
// 需要签到
|
||||
this.tableColumns.push(
|
||||
{prop: 'signState', label: '签到状态'},
|
||||
{prop: 'signTime', label: '签到时间'}
|
||||
)
|
||||
this.showSignExport = true
|
||||
}
|
||||
} else {
|
||||
this.$set(this.pageForm, "activityId", null)
|
||||
this.tableColumns.filter(item => item.prop !== 'signState' && item.prop !== 'signTime')
|
||||
this.showSignExport = false
|
||||
}
|
||||
this.pageData()
|
||||
}
|
||||
},
|
||||
doExportSign() {
|
||||
const {activityId, unionId} = this.pageForm
|
||||
window.open("/platform/activity/info/mange/doExportUser?id=" + activityId + "&unionId=" + unionId + "&isSign=true")
|
||||
}
|
||||
},
|
||||
async created() {
|
||||
await this.getActivityByYearOrType()
|
||||
|
||||
@@ -12,13 +12,7 @@ layout("/layouts/platform.html"){
|
||||
<template>
|
||||
<el-card shadow="never">
|
||||
<div class="btn-group tool-button">
|
||||
<el-input placeholder="请输入内容" clearable v-model="pageForm.searchKeyword">
|
||||
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询"
|
||||
style="width: 100px;">
|
||||
<el-option label="工号" value="u.loginname"></el-option>
|
||||
<el-option label="姓名" value="u.username"></el-option>
|
||||
</el-select>
|
||||
</el-input>
|
||||
<el-input placeholder="请输入工号或姓名查询" clearable v-model="pageForm.searchKeyword"></el-input>
|
||||
</div>
|
||||
<div class="btn-group tool-button">
|
||||
<el-select v-model="pageForm.jdhid" clearable filterable placeholder="请选择教代会"
|
||||
|
||||
@@ -10,13 +10,7 @@ layout("/layouts/platform.html"){
|
||||
<guava ref="guava">
|
||||
<el-card shadow="never">
|
||||
<div class="btn-group tool-button">
|
||||
<el-input placeholder="请输入内容" clearable v-model="pageForm.searchKeyword">
|
||||
<el-select v-model="pageForm.searchName" slot="prepend" placeholder="查询"
|
||||
style="width: 100px;">
|
||||
<el-option label="工号" value="u.loginname"></el-option>
|
||||
<el-option label="姓名" value="u.username"></el-option>
|
||||
</el-select>
|
||||
</el-input>
|
||||
<el-input placeholder="请输入工号或姓名查询" clearable v-model="pageForm.searchKeyword"></el-input>
|
||||
</div>
|
||||
|
||||
<div class="btn-group tool-button">
|
||||
@@ -118,9 +112,6 @@ layout("/layouts/platform.html"){
|
||||
|
||||
<el-table-column align="center" header-align="center" label="所属工会" prop="dbunitname"
|
||||
show-overflow-tooltip sortable>
|
||||
<template scope="scope">
|
||||
{{scope.row.unionname}}({{scope.row.unioncode}})
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" header-align="center" label="所属单位" prop="dbunitname"
|
||||
show-overflow-tooltip
|
||||
|
||||
@@ -104,6 +104,8 @@ layout("/layouts/platform.html"){
|
||||
<div class="pull-right offscreen-right">
|
||||
<el-button type="primary" @click="openAdd"><i class="ti-plus"></i> 添加代表团
|
||||
</el-button>
|
||||
<el-button type="primary" @click="doSetDbInfo"><i class="ti-plus"></i> 重置代表信息
|
||||
</el-button>
|
||||
</div>
|
||||
</el-card>
|
||||
<el-dialog title="添加代表团" :visible.sync="addDialogVisible" width="40%">
|
||||
@@ -513,6 +515,14 @@ layout("/layouts/platform.html"){
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
async doSetDbInfo(){
|
||||
const resp = await $.post('/platform/jdh/zzjg/delegation/setDbInfo')
|
||||
if (resp.code === 0) {
|
||||
this.$message.success('设置成功')
|
||||
} else {
|
||||
this.$message.warning('操作失败')
|
||||
}
|
||||
},
|
||||
dropdownCommand(command) {
|
||||
const {type, data} = command
|
||||
if (type == 'fgh') {
|
||||
|
||||
@@ -38,9 +38,24 @@ layout("/layouts/platform.html"){
|
||||
|
||||
<el-form :model="formData" ref="form" :rules="formRules" label-width="120px">
|
||||
|
||||
<vi-title title="请选择活动"></vi-title>
|
||||
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item prop="activity_id" label="项目名称">
|
||||
<el-autocomplete style="width: 100%"
|
||||
v-model="formData.activity_name"
|
||||
placeholder="请输入内容"
|
||||
@select="handleSelect"
|
||||
@input="activityChange"
|
||||
></el-autocomplete>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12" v-if="formData.activity_id != null && formData.activity_id !== ''">
|
||||
<el-button @click="openView" type="primary">查看活动详细信息</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<!--<el-row :gutter="20">
|
||||
<el-col :span="12">
|
||||
<el-form-item prop="activity_id" label="活动名称">
|
||||
<el-select v-model="formData.activity_id"
|
||||
@@ -56,39 +71,17 @@ layout("/layouts/platform.html"){
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12" v-if="formData.activity_id != null && formData.activity_id !== ''">
|
||||
<el-button @click="openView" type="primary">查看活动详细信息</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-row :gutter="20" v-if="formData.activity_id != null && formData.activity_id !== ''">
|
||||
<el-col :span="12">
|
||||
<el-form-item prop="activity_number" label="实际参与人数">
|
||||
<el-input-number v-model="formData.activity_number"
|
||||
style="width: 100%"
|
||||
placeholder="请输入实际参与人数"></el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="12">
|
||||
<div style="padding: 4px 0 20px 0">
|
||||
<!--<el-button type="primary" size="small" @click="doExportActivityApply">
|
||||
导出活动申请方案表
|
||||
</el-button>
|
||||
<el-button type="primary" size="small" style="margin-left: 10px"
|
||||
@click="doExportReimbursementVoucher">导出报销凭证
|
||||
</el-button>
|
||||
<el-button type="primary" size="small" style="margin-left: 10px"
|
||||
@click="doExportActivitySignUpUser">导出活动参加人员
|
||||
</el-button>-->
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-row>-->
|
||||
|
||||
<el-row :gutter="20" v-if="formData.activity_id != null && formData.activity_id !== ''">
|
||||
|
||||
|
||||
|
||||
|
||||
</el-row>
|
||||
|
||||
<el-row :gutter="20" v-if="formData.activity_id != null && formData.activity_id !== ''">
|
||||
<vi-title title="活动费用预算及报销信息表"></vi-title>
|
||||
|
||||
<el-form-item label-width="40px">
|
||||
<span style="color: red">如有收款人请填写收款人、支行名称及报销卡号;如无收款人,请在备注栏中说明报销情况</span>
|
||||
<el-table :data="formData.budgets" border max-height="500" size="mini" style="width: 100%">
|
||||
@@ -132,22 +125,6 @@ layout("/layouts/platform.html"){
|
||||
<el-input v-model="row.username" maxlength="50"
|
||||
@input="getCardNumberByPayeeId(row)"
|
||||
placeholder="请输入收款人"></el-input>
|
||||
<!--<el-select :loading="selectLoading" :remote-method="remoteMethod"
|
||||
clearable
|
||||
filterable
|
||||
@change="getCardNumberByPayeeId(row)"
|
||||
placeholder="请选择收款人"
|
||||
remote
|
||||
reserve-keyword
|
||||
style="width: 100%"
|
||||
v-model="row.payeeId">
|
||||
<el-option
|
||||
:key="item.id"
|
||||
:label="item.username+'-'+item.loginname+'-'+item.unitname"
|
||||
:value="item.id"
|
||||
v-for="item in userList">
|
||||
</el-option>
|
||||
</el-select>-->
|
||||
</el-form-item>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
@@ -508,8 +508,8 @@ layout("/layouts/platform.html"){
|
||||
this.$set(this.pageForm, 'unionId', this.unions ? this.unions[0].id : null)
|
||||
this.flushUnits()
|
||||
}
|
||||
this.personTypeOptions = await getDictOptions("UserType")
|
||||
this.userStateOptions = await getDictOptions("UserState")
|
||||
this.personTypeOptions = await getDictOptions("PERSON_TYPE")
|
||||
this.userStateOptions = await getDictOptions("USER_STATE")
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
@@ -187,7 +187,7 @@ layout("/layouts/platform.html"){
|
||||
}
|
||||
},
|
||||
async created() {
|
||||
this.personTypeOptions = await getDictOptions("UserType")
|
||||
this.personTypeOptions = await getDictOptions("PERSON_TYPE")
|
||||
this.unions = await getUnions(null)
|
||||
this.units = await getUnits(null)
|
||||
this.pageData();
|
||||
|
||||
Reference in New Issue
Block a user