commit
This commit is contained in:
@@ -37,7 +37,7 @@ public class SchoolAssignGrades {
|
|||||||
|
|
||||||
|
|
||||||
@Column
|
@Column
|
||||||
@Comment("所属单位")
|
@Comment("")
|
||||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||||
private String unitId;
|
private String unitId;
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,102 @@
|
|||||||
|
package io.v.nutz.meeting.controller.mobile;
|
||||||
|
|
||||||
|
import cn.wizzer.framework.base.Result;
|
||||||
|
import io.v.nutz.annontation.ViReturn;
|
||||||
|
import io.v.nutz.meeting.models.MeetingInfo;
|
||||||
|
import io.v.nutz.meeting.models.MeetingTimePeriodUser;
|
||||||
|
import io.v.nutz.meeting.models.MeetingUser;
|
||||||
|
import io.v.nutz.web.commons.utils.ShiroUtil;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresAuthentication;
|
||||||
|
import org.nutz.dao.Chain;
|
||||||
|
import org.nutz.dao.Cnd;
|
||||||
|
import org.nutz.dao.Dao;
|
||||||
|
import org.nutz.ioc.loader.annotation.Inject;
|
||||||
|
import org.nutz.ioc.loader.annotation.IocBean;
|
||||||
|
import org.nutz.lang.Lang;
|
||||||
|
import org.nutz.mvc.annotation.At;
|
||||||
|
import org.nutz.mvc.annotation.GET;
|
||||||
|
import org.nutz.mvc.annotation.Ok;
|
||||||
|
import org.nutz.mvc.annotation.Param;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@IocBean
|
||||||
|
@Slf4j
|
||||||
|
@At("/mobile/meeting/notify")
|
||||||
|
public class MMeetingNotifyController {
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
private Dao dao;
|
||||||
|
|
||||||
|
@At("")
|
||||||
|
@Ok("beetl:/mobile/meeting/notify.html")
|
||||||
|
@RequiresAuthentication
|
||||||
|
public void index(HttpServletRequest request) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@At("/getMeetingInfo")
|
||||||
|
@Ok("json:full")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresAuthentication
|
||||||
|
public Object getMeetingInfo(@Param("meetingId") String meetingId) {
|
||||||
|
MeetingInfo meetingInfo = dao.fetch(MeetingInfo.class, meetingId);
|
||||||
|
dao.fetchLinks(meetingInfo, "meetingTimePeriods", Cnd.NEW().asc("startTime"));
|
||||||
|
|
||||||
|
Cnd cnd = Cnd.NEW();
|
||||||
|
cnd.and("userId", "=", ShiroUtil.getPrincipalProperty("id"));
|
||||||
|
MeetingTimePeriodUser mtPu = dao.fetch(MeetingTimePeriodUser.class, cnd);
|
||||||
|
|
||||||
|
if (Lang.isEmpty(meetingInfo)) {
|
||||||
|
return Result.error("参数错误");
|
||||||
|
}
|
||||||
|
if (Lang.isEmpty(mtPu)) {
|
||||||
|
return Result.error("你不是当前会议人员");
|
||||||
|
}
|
||||||
|
|
||||||
|
return meetingInfo;
|
||||||
|
}
|
||||||
|
|
||||||
|
@At("/joinDo")
|
||||||
|
@Ok("json:full")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresAuthentication
|
||||||
|
public Object joinDo(@Param("isJoin") Boolean isJoin,
|
||||||
|
@Param("notJoinReason") String notJoinReason,
|
||||||
|
@Param("ids") String[] ids,
|
||||||
|
@Param("meetingId") String meetingId) {
|
||||||
|
List<MeetingTimePeriodUser> periodUsers = dao.query(MeetingTimePeriodUser.class, Cnd.where("meetingId", "=", meetingId)
|
||||||
|
.and("userId", "=", ShiroUtil.getPlatformUid()));
|
||||||
|
if (isJoin) {
|
||||||
|
//参加
|
||||||
|
periodUsers.forEach(item -> {
|
||||||
|
item.setIsJoinByMsg(true);
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
List<String> strings = Arrays.asList(ids);
|
||||||
|
periodUsers.forEach(item -> {
|
||||||
|
if (strings.contains(item.getMeetingTimePeriodId())) {
|
||||||
|
item.setIsJoinByMsg(false);
|
||||||
|
item.setNotJoinReason(notJoinReason);
|
||||||
|
} else {
|
||||||
|
item.setIsJoinByMsg(true);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
dao.update(periodUsers);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@At("/readDo")
|
||||||
|
@Ok("json:full")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresAuthentication
|
||||||
|
public Object readDo(@Param("meetingId") String meetingId) {
|
||||||
|
dao.update(MeetingUser.class, Chain.make("isReadByMsg", true), Cnd.where("meetingId", "=", meetingId).and("userId", "=", ShiroUtil.getPlatformUid()));
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
package io.v.nutz.meeting.controller.mobile;
|
||||||
|
|
||||||
|
import io.v.nutz.meeting.models.ShortUrl;
|
||||||
|
import io.v.nutz.web.commons.base.Globals;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresAuthentication;
|
||||||
|
import org.nutz.dao.Cnd;
|
||||||
|
import org.nutz.dao.Dao;
|
||||||
|
import org.nutz.ioc.loader.annotation.Inject;
|
||||||
|
import org.nutz.ioc.loader.annotation.IocBean;
|
||||||
|
import org.nutz.mvc.annotation.At;
|
||||||
|
import org.nutz.mvc.annotation.Ok;
|
||||||
|
|
||||||
|
@IocBean
|
||||||
|
@Slf4j
|
||||||
|
@At("/s")
|
||||||
|
public class MMeetingShortUrlController {
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
private Dao dao;
|
||||||
|
|
||||||
|
@At("/**")
|
||||||
|
@Ok("re")
|
||||||
|
@RequiresAuthentication
|
||||||
|
public String index(String key) throws Exception {
|
||||||
|
ShortUrl shortUrl = dao.fetch(ShortUrl.class, Cnd.where("shortUrl", "=", key));
|
||||||
|
String realPath = Globals.AppDomain + shortUrl.getRealUrl();
|
||||||
|
return ">>:" + realPath;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,16 +1,23 @@
|
|||||||
package io.v.nutz.meeting.controller.pc;
|
package io.v.nutz.meeting.controller.pc;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import cn.wizzer.framework.base.Result;
|
||||||
import io.v.nutz.annontation.ViReturn;
|
import io.v.nutz.annontation.ViReturn;
|
||||||
import io.v.nutz.meeting.models.MeetingInfo;
|
import io.v.nutz.meeting.models.MeetingInfo;
|
||||||
import io.v.nutz.meeting.models.MeetingUser;
|
import io.v.nutz.meeting.models.MeetingUser;
|
||||||
|
import io.v.nutz.meeting.models.ShortUrl;
|
||||||
import io.v.nutz.meeting.service.MeetingManageService;
|
import io.v.nutz.meeting.service.MeetingManageService;
|
||||||
import io.v.nutz.modules.models.PageForm;
|
import io.v.nutz.modules.models.PageForm;
|
||||||
import io.v.nutz.msgNotify.models.MsgNotify;
|
import io.v.nutz.msgNotify.models.MsgNotify;
|
||||||
import io.v.nutz.msgNotify.service.MsgNotifyService;
|
import io.v.nutz.msgNotify.service.MsgNotifyService;
|
||||||
|
import io.v.nutz.web.commons.base.Globals;
|
||||||
import org.apache.shiro.authz.annotation.Logical;
|
import org.apache.shiro.authz.annotation.Logical;
|
||||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
import org.nutz.dao.Cnd;
|
import org.nutz.dao.Cnd;
|
||||||
import org.nutz.dao.Dao;
|
import org.nutz.dao.Dao;
|
||||||
|
import org.nutz.dao.Sqls;
|
||||||
|
import org.nutz.dao.sql.Sql;
|
||||||
|
import org.nutz.dao.sql.VarIndex;
|
||||||
import org.nutz.ioc.loader.annotation.Inject;
|
import org.nutz.ioc.loader.annotation.Inject;
|
||||||
import org.nutz.ioc.loader.annotation.IocBean;
|
import org.nutz.ioc.loader.annotation.IocBean;
|
||||||
import org.nutz.lang.util.NutMap;
|
import org.nutz.lang.util.NutMap;
|
||||||
@@ -20,8 +27,10 @@ import org.nutz.mvc.annotation.POST;
|
|||||||
import org.nutz.mvc.annotation.Param;
|
import org.nutz.mvc.annotation.Param;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import java.security.SecureRandom;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
@IocBean
|
@IocBean
|
||||||
@At("/platform/meeting/manage")
|
@At("/platform/meeting/manage")
|
||||||
@@ -155,4 +164,78 @@ public class MeetingManageController {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@At
|
||||||
|
@Ok("json:full")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresPermissions("meeting.manage.search")
|
||||||
|
public Object getUserCount(String id) {
|
||||||
|
return meetingManageService.dao().count(MeetingUser.class, Cnd.where("meetingId", "=", id));
|
||||||
|
}
|
||||||
|
|
||||||
|
@At
|
||||||
|
@Ok("json:full")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresPermissions("meeting.manage.search")
|
||||||
|
public Object sendMsg(String id) {
|
||||||
|
MeetingInfo meetingInfo = meetingManageService.fetch(id);
|
||||||
|
MsgNotify msgNotify = meetingManageService.dao().fetch(MsgNotify.class, meetingInfo.getNotifyId());
|
||||||
|
|
||||||
|
String content = msgNotify.getContent();
|
||||||
|
if(StrUtil.isBlank(content)) {
|
||||||
|
return Result.error("短信内容为空,请点击编辑按钮核查");
|
||||||
|
}
|
||||||
|
|
||||||
|
Sql sql = Sqls.create("""
|
||||||
|
SELECT
|
||||||
|
u.username,
|
||||||
|
u.loginname
|
||||||
|
FROM
|
||||||
|
`meeting_user` mu
|
||||||
|
LEFT JOIN USER u ON mu.userid = u.id
|
||||||
|
$condition
|
||||||
|
""");
|
||||||
|
Cnd cnd = Cnd.NEW();
|
||||||
|
cnd.and("mu.meetingId", "=", id);
|
||||||
|
sql.setCondition(cnd);
|
||||||
|
List<NutMap> list = meetingManageService.listMap(sql);
|
||||||
|
List<String> loginnameList = list.stream().map(o -> o.getString("loginname")).collect(Collectors.toList());
|
||||||
|
|
||||||
|
//生成短链
|
||||||
|
String shortUrl;
|
||||||
|
int count;
|
||||||
|
do {
|
||||||
|
shortUrl = generateRandomString();
|
||||||
|
count = dao.count(ShortUrl.class, Cnd.where("shortUrl", "=", shortUrl));
|
||||||
|
} while (count > 0);
|
||||||
|
|
||||||
|
//判断最后一个是不是句号
|
||||||
|
if (content.endsWith("。") || content.endsWith(";")) {
|
||||||
|
content += "";
|
||||||
|
} else {
|
||||||
|
content += ",";
|
||||||
|
}
|
||||||
|
content += "请点击" + Globals.AppDomain + shortUrl + ",确认是否参加。";
|
||||||
|
System.out.println(content);
|
||||||
|
|
||||||
|
ShortUrl sUrl = new ShortUrl();
|
||||||
|
sUrl.setShortUrl(shortUrl);
|
||||||
|
sUrl.setRealUrl("/mobile/meeting/notify?meetingId=" + id);
|
||||||
|
dao.insert(sUrl);
|
||||||
|
|
||||||
|
msgNotifyService.sendMsg(List.of("msg"), loginnameList, content);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final String CHARACTERS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
||||||
|
private static final int CODE_LENGTH = 8;
|
||||||
|
private static final SecureRandom random = new SecureRandom();
|
||||||
|
|
||||||
|
public String generateRandomString() {
|
||||||
|
StringBuilder code = new StringBuilder(CODE_LENGTH);
|
||||||
|
for (int i = 0; i < CODE_LENGTH; i++) {
|
||||||
|
int index = random.nextInt(CHARACTERS.length());
|
||||||
|
code.append(CHARACTERS.charAt(index));
|
||||||
|
}
|
||||||
|
return code.toString();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+107
@@ -0,0 +1,107 @@
|
|||||||
|
package io.v.nutz.meeting.controller.pc.statistics;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import io.v.nutz.annontation.ViReturn;
|
||||||
|
import io.v.nutz.meeting.models.MeetingInfo;
|
||||||
|
import io.v.nutz.meeting.service.MeetingCommonService;
|
||||||
|
import io.v.nutz.meeting.service.MeetingManageService;
|
||||||
|
import io.v.nutz.modules.models.PageForm;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
import org.nutz.dao.Cnd;
|
||||||
|
import org.nutz.dao.Dao;
|
||||||
|
import org.nutz.dao.Sqls;
|
||||||
|
import org.nutz.dao.sql.Sql;
|
||||||
|
import org.nutz.ioc.loader.annotation.Inject;
|
||||||
|
import org.nutz.ioc.loader.annotation.IocBean;
|
||||||
|
import org.nutz.mvc.annotation.At;
|
||||||
|
import org.nutz.mvc.annotation.Ok;
|
||||||
|
import org.nutz.mvc.annotation.Param;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
|
||||||
|
@IocBean
|
||||||
|
@At("/platform/meeting/msgManage")
|
||||||
|
public class MeetingMsgManageController {
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
private Dao dao;
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
private MeetingManageService meetingManageService;
|
||||||
|
|
||||||
|
@At("")
|
||||||
|
@Ok("beetl:/platform/meeting/statistics/msgManage.html")
|
||||||
|
@RequiresPermissions("meeting.msg.manage")
|
||||||
|
public void index(HttpServletRequest request) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@At("/pageData")
|
||||||
|
@Ok("json:full")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresPermissions("meeting.msg.manage")
|
||||||
|
public Object pageData(PageForm pageForm,
|
||||||
|
@Param(value = "year", required = false) String year,
|
||||||
|
@Param(value = "meetingId", required = false) String meetingId,
|
||||||
|
@Param(value = "unionId", required = false) String unionId,
|
||||||
|
@Param(value = "unitId", required = false) String unitId) {
|
||||||
|
Sql sql = Sqls.create("""
|
||||||
|
SELECT
|
||||||
|
mu.id,
|
||||||
|
mu.meetingId,
|
||||||
|
u.id as userId,
|
||||||
|
u.username,
|
||||||
|
u.loginname,
|
||||||
|
u.sex,
|
||||||
|
u.mobile,
|
||||||
|
u.unitname,
|
||||||
|
u.unionname,
|
||||||
|
mu.isReadByMsg,
|
||||||
|
(select count(1) from meeting_time_period_user mt where mt.meetingId = @meetingId and userId = mu.userId and isJoinByMsg = true) as isJoinByMsg
|
||||||
|
FROM
|
||||||
|
`meeting_user` mu left join `user` u on mu.userId = u.id
|
||||||
|
$condition
|
||||||
|
""").setParam("meetingId", meetingId);
|
||||||
|
Cnd cnd = Cnd.NEW();
|
||||||
|
cnd.and("mu.meetingId", "=", meetingId);
|
||||||
|
cnd.andEX("u.unionId", "=", unionId);
|
||||||
|
cnd.andEX("u.unitId", "=", unitId);
|
||||||
|
cnd.desc("isReadByMsg").desc("isJoinByMsg");
|
||||||
|
sql.setCondition(cnd);
|
||||||
|
return meetingManageService.listPageMap(pageForm.getPageNumber(), pageForm.getPageSize(), sql);
|
||||||
|
}
|
||||||
|
|
||||||
|
@At("/getMeetingList")
|
||||||
|
@Ok("json:full")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresPermissions("meeting.msg.manage")
|
||||||
|
public Object getMeetingList(Integer year) {
|
||||||
|
return dao.query(MeetingInfo.class, Cnd.NEW().andEX("year(startTime)", "=", year));
|
||||||
|
}
|
||||||
|
|
||||||
|
@At("/getLeaveInfoByUser")
|
||||||
|
@Ok("json:full")
|
||||||
|
@ViReturn
|
||||||
|
@RequiresPermissions("meeting.msg.manage")
|
||||||
|
public Object getLeaveInfoByUser(String meetingId, String userId) {
|
||||||
|
Sql sql = Sqls.create("""
|
||||||
|
SELECT
|
||||||
|
mp.timePeriodName,
|
||||||
|
mp.startTime,
|
||||||
|
mp.endTime,
|
||||||
|
mt.isJoinByMsg,
|
||||||
|
mt.notJoinReason
|
||||||
|
FROM
|
||||||
|
meeting_time_period_user mt
|
||||||
|
LEFT JOIN meeting_info mi ON mt.meetingId = mi.id
|
||||||
|
LEFT JOIN meeting_time_period mp ON mt.meetingTimePeriodId = mp.id
|
||||||
|
$condition
|
||||||
|
""");
|
||||||
|
Cnd cnd = Cnd.NEW();
|
||||||
|
cnd.and("mt.meetingId", "=", meetingId);
|
||||||
|
cnd.and("mt.userId", "=", userId);
|
||||||
|
cnd.asc("mp.startTime");
|
||||||
|
sql.setCondition(cnd);
|
||||||
|
return meetingManageService.listMap(sql);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -79,5 +79,13 @@ public class MeetingTimePeriodUser {
|
|||||||
@Comment("审核记录ID")
|
@Comment("审核记录ID")
|
||||||
private List<NutMap> auditIdList;
|
private List<NutMap> auditIdList;
|
||||||
|
|
||||||
|
@Column
|
||||||
|
@ColDefine(type = ColType.BOOLEAN)
|
||||||
|
@Comment("是否参加")
|
||||||
|
private Boolean isJoinByMsg;
|
||||||
|
|
||||||
|
@Column
|
||||||
|
@ColDefine(type = ColType.VARCHAR, width = 100)
|
||||||
|
@Comment("不参加理由")
|
||||||
|
private String notJoinReason;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -75,4 +75,8 @@ public class MeetingUser {
|
|||||||
@Comment("审核记录ID")
|
@Comment("审核记录ID")
|
||||||
private List<NutMap> auditIdList;
|
private List<NutMap> auditIdList;
|
||||||
|
|
||||||
|
@Column
|
||||||
|
@ColDefine(type = ColType.BOOLEAN)
|
||||||
|
@Comment("是否已阅")
|
||||||
|
private Boolean isReadByMsg;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package io.v.nutz.meeting.models;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
import org.nutz.dao.entity.annotation.*;
|
||||||
|
import org.nutz.dao.interceptor.annotation.PrevInsert;
|
||||||
|
|
||||||
|
@Table
|
||||||
|
@Data
|
||||||
|
@Accessors(chain = true)
|
||||||
|
public class ShortUrl {
|
||||||
|
|
||||||
|
@Name
|
||||||
|
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||||
|
@PrevInsert(uu32 = true)
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
@Column
|
||||||
|
@ColDefine(type = ColType.VARCHAR, width = 100)
|
||||||
|
@Comment("短链")
|
||||||
|
private String shortUrl;
|
||||||
|
|
||||||
|
@Column
|
||||||
|
@ColDefine(type = ColType.VARCHAR, width = 100)
|
||||||
|
@Comment("真实链接")
|
||||||
|
private String realUrl;
|
||||||
|
}
|
||||||
@@ -0,0 +1,386 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/mobile/platform.html"){
|
||||||
|
#-->
|
||||||
|
<style>
|
||||||
|
[v-cloak] {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
#app {
|
||||||
|
max-height: 100vh;
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.header {
|
||||||
|
height: 400px;
|
||||||
|
max-height: 400px;
|
||||||
|
background-color: white
|
||||||
|
}
|
||||||
|
|
||||||
|
.body {
|
||||||
|
background-color: white;
|
||||||
|
margin-top: 6px;
|
||||||
|
height: calc(100vh - (400px + 6px + 26px + 70px));
|
||||||
|
max-height: calc(100vh - (400px + 6px + 26px + 70px));
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
background-color: white;
|
||||||
|
margin-top: 6px;
|
||||||
|
width: 100%;
|
||||||
|
height: 70px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.meeting_info {
|
||||||
|
height: 200px;
|
||||||
|
width: 86%;
|
||||||
|
margin: 0 auto;
|
||||||
|
transform: translateY(-60%);
|
||||||
|
background-color: white;
|
||||||
|
box-shadow: 0 8px 12px #ebedf0;
|
||||||
|
padding: 10px 10px;
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.header .text {
|
||||||
|
color: white;
|
||||||
|
text-align: center;
|
||||||
|
letter-spacing: 3px;
|
||||||
|
line-height: 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.meeting_info .meeting_name {
|
||||||
|
text-align: center;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.meeting_info .meeting_address {
|
||||||
|
text-align: center;
|
||||||
|
color: grey;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.van-button--block {
|
||||||
|
margin: 0 auto;
|
||||||
|
width: 170px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tag {
|
||||||
|
color: #1867b0;
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 20px;
|
||||||
|
margin-right: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.span_text {
|
||||||
|
color: grey;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.van-col {
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.van-col span {
|
||||||
|
color: grey;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon {
|
||||||
|
width: 6.4em;
|
||||||
|
height: 6.4em;
|
||||||
|
display: inline-block;
|
||||||
|
vertical-align: middle;
|
||||||
|
font-size: 10px;
|
||||||
|
-webkit-mask-size: 100%;
|
||||||
|
-webkit-mask-position: 50% 50%;
|
||||||
|
background-color: currentColor;
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon_ok {
|
||||||
|
-webkit-mask-image: url(data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M12%2022C6.477%2022%202%2017.523%202%2012S6.477%202%2012%202s10%204.477%2010%2010-4.477%2010-10%2010zm-1.177-7.86l-2.765-2.767L7%2012.431l3.119%203.121a1%201%200%20001.414%200l5.952-5.95-1.062-1.062-5.6%205.6z%22%2F%3E%3C%2Fsvg%3E);
|
||||||
|
color: #07c160;
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon_no {
|
||||||
|
-webkit-mask-image: url(data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M12%2022C6.477%2022%202%2017.523%202%2012S6.477%202%2012%202s10%204.477%2010%2010-4.477%2010-10%2010zm-.763-15.864l.11%207.596h1.305l.11-7.596h-1.525zm.759%2010.967c.512%200%20.902-.383.902-.882%200-.5-.39-.882-.902-.882a.878.878%200%2000-.896.882c0%20.499.396.882.896.882z%22%2F%3E%3C%2Fsvg%3E);
|
||||||
|
color: #fa5151;
|
||||||
|
}
|
||||||
|
|
||||||
|
.weui-msg__text-area {
|
||||||
|
margin-bottom: 32px;
|
||||||
|
padding: 0 32px;
|
||||||
|
-webkit-box-flex: 1;
|
||||||
|
line-height: 1.6;
|
||||||
|
}
|
||||||
|
|
||||||
|
.weui-msg__text-area .weui-msg__title {
|
||||||
|
margin-bottom: 16px;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 22px;
|
||||||
|
color: rgba(0, 0, 0, 0.9);
|
||||||
|
}
|
||||||
|
|
||||||
|
.weui-msg__desc {
|
||||||
|
font-size: 17px;
|
||||||
|
font-weight: 400;
|
||||||
|
color: rgba(0, 0, 0, 0.9);
|
||||||
|
margin-bottom: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.meeting_index {
|
||||||
|
width: 40px;
|
||||||
|
border-radius: 50%;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
background-color: lightgrey;
|
||||||
|
color: white;
|
||||||
|
font-size: 20px;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.meeting_peri {
|
||||||
|
width: 90%;
|
||||||
|
line-height: 19px;
|
||||||
|
margin-left: 10px
|
||||||
|
}
|
||||||
|
|
||||||
|
.meeting_primary {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.weui-btn_primary:not(.weui-btn_disabled):visited {
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.weui-btn_primary {
|
||||||
|
background-color: #1867b0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.weui-btn {
|
||||||
|
position: relative;
|
||||||
|
display: block;
|
||||||
|
width: 184px;
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
padding: 8px 24px;
|
||||||
|
box-sizing: border-box;
|
||||||
|
font-weight: 700;
|
||||||
|
font-size: 17px;
|
||||||
|
text-align: center;
|
||||||
|
text-decoration: none;
|
||||||
|
color: #fff;
|
||||||
|
line-height: 1.88235294;
|
||||||
|
border-radius: 8px;
|
||||||
|
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
.body .van-cell {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.body .van-field__control--custom {
|
||||||
|
justify-content: flex-end;
|
||||||
|
}
|
||||||
|
|
||||||
|
.body .van-field__label {
|
||||||
|
min-width: 170px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<div id="app">
|
||||||
|
<div v-if="isCanAudit">
|
||||||
|
<div class="header">
|
||||||
|
<div style="height: 300px; background-color: #1867b0; border-radius: 0 0 16% 16%;">
|
||||||
|
<div class="text">会议通知</div>
|
||||||
|
</div>
|
||||||
|
<div class="meeting_info">
|
||||||
|
<div class="meeting_name">{{meetingInfo.meetingName}}</div>
|
||||||
|
<div class="meeting_address">{{meetingInfo.location}}</div>
|
||||||
|
<div style="position: relative; top: 55px">
|
||||||
|
<van-row>
|
||||||
|
<van-col span="24"><span>会议类型:</span>{{typeName}}</van-col>
|
||||||
|
</van-row>
|
||||||
|
<div style="position: relative; top: 30px">
|
||||||
|
<van-row>
|
||||||
|
<van-col span="24">
|
||||||
|
<span style="color: grey; font-size: 14px;">会议时间:</span>
|
||||||
|
{{moment(meetingInfo.startTime).format('YYYY-MM-DD HH:mm')}}
|
||||||
|
</van-col>
|
||||||
|
</van-row>
|
||||||
|
<van-row>
|
||||||
|
<van-col span="24">
|
||||||
|
<span style="color: grey; font-size: 14px;">结束时间:</span>
|
||||||
|
{{moment(meetingInfo.endTime).format('YYYY-MM-DD HH:mm')}}
|
||||||
|
</van-col>
|
||||||
|
</van-row>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="body">
|
||||||
|
<div><span class="tag">|</span>会议名称</div>
|
||||||
|
<div style="overflow-y: auto; height: 100%; font-size: 13px;margin-top: 16px">
|
||||||
|
<div class="meeting_primary" v-for="(item,index) in meetingInfo.meetingTimePeriods">
|
||||||
|
<van-field name="checkbox">
|
||||||
|
<template #label>
|
||||||
|
<div class="meeting_peri">
|
||||||
|
<div>{{item.timePeriodName}}</div>
|
||||||
|
<div>{{moment(item.startTime).format('YYYY-MM-DD HH:mm')}}</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<template #input>
|
||||||
|
<van-checkbox v-model="item.canJoin" shape="square"></van-checkbox>
|
||||||
|
</template>
|
||||||
|
</van-field>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="footer">
|
||||||
|
<van-button @click="canJoin(false)" block color="#1867b0" round type="primary">
|
||||||
|
不参加
|
||||||
|
</van-button>
|
||||||
|
<van-button @click="canJoin(true)" block color="#1867b0" round type="primary">
|
||||||
|
参加
|
||||||
|
</van-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div style="text-align: center; padding-top: calc(100% - 50%)" v-cloak v-else>
|
||||||
|
<div style="margin-bottom: 32px;">
|
||||||
|
<span :class="isIncorrect === true ? 'icon icon_ok' : 'icon icon_no'"></span>
|
||||||
|
</div>
|
||||||
|
<div class="weui-msg__text-area">
|
||||||
|
<h2 class="weui-msg__title">{{isIncorrect === true ? '操作成功' : '温馨提示'}}</h2>
|
||||||
|
<p class=".weui-msg__desc">{{incorrectMag}}</p>
|
||||||
|
</div>
|
||||||
|
<p style="margin-top: 190px">
|
||||||
|
<span @click="back" class="weui-btn weui-btn_primary" role="button">点击返回</span>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<van-dialog v-model="notJoinShow" title="提示" show-cancel-button :before-close="onBeforeClose">
|
||||||
|
<van-field
|
||||||
|
v-model="notJoinReason"
|
||||||
|
rows="2"
|
||||||
|
autosize
|
||||||
|
label="不参加原因"
|
||||||
|
type="textarea"
|
||||||
|
maxlength="100"
|
||||||
|
placeholder="请输入不参加原因"
|
||||||
|
show-word-limit
|
||||||
|
></van-field>
|
||||||
|
</van-dialog>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
<!--# include("/platform/meeting/includeJs/meetingUtil.js"){} #-->
|
||||||
|
const meetUtil = new meetingUtil()
|
||||||
|
|
||||||
|
function getQueryString(name) {
|
||||||
|
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
|
||||||
|
var r = window.location.search.substr(1).match(reg);
|
||||||
|
if (r != null) return decodeURI(r[2]);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
const vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
notJoinShow: false,
|
||||||
|
notJoinReason: '',
|
||||||
|
meetingInfo: {},
|
||||||
|
isCanAudit: true,
|
||||||
|
incorrectMag: '',
|
||||||
|
meetingId: '',
|
||||||
|
mtpId: '',
|
||||||
|
isIncorrect: true,
|
||||||
|
typeName: '',
|
||||||
|
isJoin: true,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async pageData() {
|
||||||
|
const res = await $.post('/mobile/meeting/notify/getMeetingInfo', {
|
||||||
|
meetingId: this.meetingId,
|
||||||
|
})
|
||||||
|
if (res.code === 0) {
|
||||||
|
this.meetingInfo = res.data
|
||||||
|
const typeList = await meetUtil.getAllMeetingType()
|
||||||
|
const type = typeList.find(o => o.id === this.meetingInfo.typeId)
|
||||||
|
this.typeName = type !== undefined ? type.meetingTypeName : ''
|
||||||
|
} else {
|
||||||
|
this.isCanAudit = false
|
||||||
|
this.incorrectMag = res.msg
|
||||||
|
this.isIncorrect = false
|
||||||
|
}
|
||||||
|
$('#app').css('opacity', '1')
|
||||||
|
},
|
||||||
|
async canJoin(type) {
|
||||||
|
this.isJoin = type
|
||||||
|
if(!type) {
|
||||||
|
const joinArray = this.meetingInfo.meetingTimePeriods.filter(o => o.canJoin === true)
|
||||||
|
if(joinArray.length === 0) {
|
||||||
|
this.$modal.alert('请选择不参加的时间段')
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.notJoinShow = true
|
||||||
|
} else {
|
||||||
|
const confirm = await vant.Dialog.confirm({
|
||||||
|
title: '提示',
|
||||||
|
message: '您确认要参加吗?',
|
||||||
|
})
|
||||||
|
if (confirm === "confirm") {
|
||||||
|
await this.joinDo()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async onBeforeClose(action, done) {
|
||||||
|
if (action === "confirm") {
|
||||||
|
if (this.notJoinReason) {
|
||||||
|
await this.joinDo()
|
||||||
|
} else {
|
||||||
|
this.$modal.msg('请填写不参加原因')
|
||||||
|
return done(false)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
done(true)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async joinDo() {
|
||||||
|
const ids = this.meetingInfo.meetingTimePeriods.filter(o => o.canJoin === true).map(o => o.id)
|
||||||
|
const resp = await $.post('/mobile/meeting/notify/joinDo', {
|
||||||
|
isJoin: this.isJoin,
|
||||||
|
notJoinReason: this.notJoinReason,
|
||||||
|
ids: JSON.stringify(ids),
|
||||||
|
meetingId: this.meetingInfo.id
|
||||||
|
})
|
||||||
|
this.$modal.msg(resp.msg)
|
||||||
|
this.notJoinShow = false
|
||||||
|
},
|
||||||
|
async readDo() {
|
||||||
|
await $.post('/mobile/meeting/notify/readDo', {meetingId: this.meetingInfo.id})
|
||||||
|
},
|
||||||
|
back() {
|
||||||
|
const str = this.incorrectMag === '你不是当前会议人员' ? 'http://' + window.location.host : '/mobile/meeting/mine/go_sign?meetingId=' + this.meetingId + '&mtpId=' + this.mtpId
|
||||||
|
location.href = str
|
||||||
|
},
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.meetingId = getQueryString('meetingId')
|
||||||
|
await this.pageData()
|
||||||
|
await this.readDo()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
@@ -62,7 +62,8 @@ layout("/layouts/platform.html"){
|
|||||||
|
|
||||||
<el-table-column label="操作" width="300px">
|
<el-table-column label="操作" width="300px">
|
||||||
<template scope="{row}">
|
<template scope="{row}">
|
||||||
<el-button @click="openView(row)" size="mini">查看</el-button>
|
<el-button @click="sendMsg(row)" size="mini" type="primary">通知</el-button>
|
||||||
|
<el-button @click="openView(row)" size="mini" type="primary">查看</el-button>
|
||||||
<el-button @click="openEdit(row)" size="mini" type="primary">编辑</el-button>
|
<el-button @click="openEdit(row)" size="mini" type="primary">编辑</el-button>
|
||||||
<el-button @click="doDelete(row.id)" size="mini" type="danger">删除</el-button>
|
<el-button @click="doDelete(row.id)" size="mini" type="danger">删除</el-button>
|
||||||
</template>
|
</template>
|
||||||
@@ -97,7 +98,26 @@ layout("/layouts/platform.html"){
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
async sendMsg(row) {
|
||||||
|
const resp = await $.post(loc() + '/getUserCount', {id: row.id})
|
||||||
|
if(resp.code === 0) {
|
||||||
|
const confirm = await this.$confirm('此操作将给' + resp.data + '位人员发送短信,请确认?', '提示', {
|
||||||
|
confirmButtonText: '确定',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'warning'
|
||||||
|
})
|
||||||
|
if (confirm === "confirm") {
|
||||||
|
const resp = await $.post(loc() + '/sendMsg', {id: row.id})
|
||||||
|
if(resp.code === 0) {
|
||||||
|
this.$message.success(resp.msg)
|
||||||
|
} else {
|
||||||
|
this.$message.warning(resp.msg)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.$message.warning(resp.msg)
|
||||||
|
}
|
||||||
|
},
|
||||||
openView(row) {
|
openView(row) {
|
||||||
const {id, notifyId, hold} = row
|
const {id, notifyId, hold} = row
|
||||||
window.location.href = '/platform/meeting/manage/createMeeting?notifyId=' + notifyId + "&hold=" + true + "&id=" + id
|
window.location.href = '/platform/meeting/manage/createMeeting?notifyId=' + notifyId + "&hold=" + true + "&id=" + id
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ layout("/layouts/platform.html"){
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<!--<el-form-item label="会议时间" prop="meetingTime">
|
<el-form-item label="会议时间" prop="meetingTime">
|
||||||
<el-date-picker end-placeholder="结束日期"
|
<el-date-picker end-placeholder="结束日期"
|
||||||
format="yyyy-MM-dd HH:mm:ss"
|
format="yyyy-MM-dd HH:mm:ss"
|
||||||
range-separator="至" start-placeholder="开始日期"
|
range-separator="至" start-placeholder="开始日期"
|
||||||
@@ -66,8 +66,8 @@ layout("/layouts/platform.html"){
|
|||||||
v-model="formData.meetingTime"
|
v-model="formData.meetingTime"
|
||||||
value-format="yyyy-MM-dd HH:mm:ss">
|
value-format="yyyy-MM-dd HH:mm:ss">
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>-->
|
</el-form-item>
|
||||||
<el-form-item label="会议时间" prop="meetTime">
|
<!--<el-form-item label="会议时间" prop="meetTime">
|
||||||
<el-date-picker :disabled="hold"
|
<el-date-picker :disabled="hold"
|
||||||
format="yyyy-MM-dd HH:mm:ss"
|
format="yyyy-MM-dd HH:mm:ss"
|
||||||
placeholder="请选择会议时间"
|
placeholder="请选择会议时间"
|
||||||
@@ -76,7 +76,7 @@ layout("/layouts/platform.html"){
|
|||||||
v-model="formData.meetTime"
|
v-model="formData.meetTime"
|
||||||
value-format="yyyy-MM-dd HH:mm:ss">
|
value-format="yyyy-MM-dd HH:mm:ss">
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>-->
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,214 @@
|
|||||||
|
<!--#
|
||||||
|
layout("/layouts/platform.html"){
|
||||||
|
#-->
|
||||||
|
<style>
|
||||||
|
.timeTable {
|
||||||
|
color: red;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<div id="app" v-cloak>
|
||||||
|
<guava ref="guava">
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never">
|
||||||
|
<div class="search">
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">年度:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-date-picker
|
||||||
|
placeholder="选择年份"
|
||||||
|
style="width: 100%" type="year"
|
||||||
|
v-model="pageForm.year"
|
||||||
|
format="yyyy"
|
||||||
|
value-format="yyyy">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">会议名称:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select @change="doSearch" clearable
|
||||||
|
filterable="true"
|
||||||
|
placeholder="请输入会议名称"
|
||||||
|
style="width: 100%;" v-model="pageForm.meetingId">
|
||||||
|
<el-option :label="item.meetingName" :value="item.id" v-for="item in meetingList"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属工会:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属工会" v-model="pageForm.unionId" style="width: 100%;"
|
||||||
|
clearable="true" filterable="true"
|
||||||
|
@change="flushUnits" @clear="flushUnits">
|
||||||
|
<el-option v-for="item in unions" :label="item.unionname" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="search-item">
|
||||||
|
<div class="search-item-label">所属单位:</div>
|
||||||
|
<div class="search-item-option">
|
||||||
|
<el-select placeholder="所属单位" v-model="pageForm.unitId" style="width: 100%;" clearable="true"
|
||||||
|
filterable="true">
|
||||||
|
<el-option v-for="item in units" :label="item.name" :value="item.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="search-query">
|
||||||
|
<el-button @click="doSearch" icon="el-icon-search" type="primary">搜索</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card class="mt10" shadow="never">
|
||||||
|
<table-tool :app="this" label="参会人员信息">
|
||||||
|
<template #func>
|
||||||
|
</template>
|
||||||
|
</table-tool>
|
||||||
|
<el-table :data="tableData" :size="tableSize" @sort-change="pageOrder"
|
||||||
|
align="center" header-align="center" ref="meetingTable">
|
||||||
|
<el-table-column label="序号" type="index" width="80">
|
||||||
|
<template scope="scope">
|
||||||
|
<span>{{ scope.$index + (pageForm.pageNumber - 1) * pageForm.pageSize + 1 }} </span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="username" label="姓名" header-align="center" align="center"
|
||||||
|
sortable></el-table-column>
|
||||||
|
<el-table-column prop="loginname" label="工号" header-align="center" align="center"
|
||||||
|
sortable></el-table-column>
|
||||||
|
<el-table-column prop="sex" label="性别" header-align="center" align="center"
|
||||||
|
sortable></el-table-column>
|
||||||
|
<el-table-column prop="mobile" label="联系方式" header-align="center" align="center"
|
||||||
|
sortable></el-table-column>
|
||||||
|
<el-table-column prop="unitname" label="所属单位" header-align="center" align="center"
|
||||||
|
sortable show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="unionname" label="所属工会" header-align="center" align="center"
|
||||||
|
sortable show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="isReadByMsg" label="是否已读" header-align="center" align="center"
|
||||||
|
sortable>
|
||||||
|
<template scope="scope">
|
||||||
|
<span v-if="scope.row.isReadByMsg === true || scope.row.isReadByMsg === 1" style="color: #0e9558">已读</span>
|
||||||
|
<span v-else>未读</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="isJoinByMsg" label="选择时间段" header-align="center" align="center"
|
||||||
|
sortable>
|
||||||
|
<template scope="scope">
|
||||||
|
<el-link type="primary" @click="openView(scope.row)">{{scope.row.isJoinByMsg}}</el-link>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="操作" header-align="center" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button type="primary" size="mini" @click="openView(scope.row)">查看</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<el-pagination
|
||||||
|
@size-change="pageSizeChange"
|
||||||
|
@current-change="pageNumberChange"
|
||||||
|
:current-page="pageForm.pageNumber"
|
||||||
|
:page-sizes="[10, 20, 30, 50]"
|
||||||
|
:page-size="pageForm.pageSize"
|
||||||
|
layout="total, sizes, prev, pager, next, jumper"
|
||||||
|
:total="pageForm.totalCount">
|
||||||
|
</el-pagination>
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template #edit>
|
||||||
|
<el-table :data="leaveTableData" align="center" header-align="center">
|
||||||
|
<el-table-column prop="timePeriodName" label="会议名称" header-align="center" align="center"
|
||||||
|
sortable show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="startTime" label="开始时间" header-align="center" align="center"
|
||||||
|
sortable show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="endTime" label="结束时间" header-align="center" align="center"
|
||||||
|
sortable show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="isJoinByMsg" label="是否参加" header-align="center" align="center"
|
||||||
|
sortable show-overflow-tooltip>
|
||||||
|
<template scope="scope">
|
||||||
|
<span v-if="scope.row.isJoinByMsg === false || scope.row.isJoinByMsg === 0" style="color: red">不参加</span>
|
||||||
|
<span v-else-if="!scope.row.isJoinByMsg">未选择</span>
|
||||||
|
<span v-else>参加</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="notJoinReason" label="不参加原因" header-align="center" align="center"
|
||||||
|
sortable show-overflow-tooltip>
|
||||||
|
<template scope="scope">
|
||||||
|
<span v-if="scope.row.notJoinReason">{{scope.row.notJoinReason}}</span>
|
||||||
|
<span v-else>暂无</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</template>
|
||||||
|
</guava>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
<!--# include("/platform/meeting/includeJs/meetingUtil.js"){} #-->
|
||||||
|
const meetUtil = new meetingUtil()
|
||||||
|
window.vue = new Vue({
|
||||||
|
el: '#app',
|
||||||
|
mixins: [initTableMixins],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
meetingList: [],
|
||||||
|
unions: [],
|
||||||
|
units: [],
|
||||||
|
leaveTableData: [],
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async openView(row) {
|
||||||
|
const resp = await $.post(loc() + "/getLeaveInfoByUser", {
|
||||||
|
meetingId: row.meetingId,
|
||||||
|
userId: row.userId
|
||||||
|
})
|
||||||
|
if(resp.code === 0) {
|
||||||
|
this.leaveTableData = resp.data
|
||||||
|
this.$refs.guava.edit()
|
||||||
|
} else {
|
||||||
|
this.$message.warning(resp.msg)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async flushUnits() {
|
||||||
|
this.$set(this.pageForm, "unitId", "")
|
||||||
|
if ("${@shiro.hasRole('sysadmin')||@shiro.hasRole('A06')||@shiro.hasRole('H03')}" === 'true') {
|
||||||
|
this.units = await getUnits(this.pageForm.unionId)
|
||||||
|
} else {
|
||||||
|
this.units = await getUnits("${@shiro.getPrincipalProperty('unit').getUnionid()}")
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async getMeetingList() {
|
||||||
|
const {data} = await $.post(loc() + "/getMeetingList", {year: this.pageForm.year})
|
||||||
|
this.meetingList = data
|
||||||
|
if (this.meetingList.length > 0) {
|
||||||
|
this.$set(this.pageForm, "meetingId", this.meetingList[0].id)
|
||||||
|
await this.pageData()
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async pageData() {
|
||||||
|
const resp = await $.post(loc() + "/pageData", this.pageForm)
|
||||||
|
if (resp.code === 0) {
|
||||||
|
this.tableData = resp.data.list
|
||||||
|
this.pageForm.totalCount = resp.data.totalCount
|
||||||
|
} else {
|
||||||
|
this.$message.warning(resp.msg)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async created() {
|
||||||
|
this.$set(this.pageForm, 'year', new Date().getFullYear() + '')
|
||||||
|
this.unions = await getUnions()
|
||||||
|
this.flushUnits()
|
||||||
|
await this.getMeetingList()
|
||||||
|
await this.pageData()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!--#
|
||||||
|
}
|
||||||
|
#-->
|
||||||
Reference in New Issue
Block a user