Merge branch 'master' into docker_package

This commit is contained in:
wangliwen 2022-09-02 11:33:01 +08:00
commit 6bd39f39bd
2 changed files with 43 additions and 1 deletions

View File

@ -40,6 +40,7 @@
<ffmpeg.version>5.0</ffmpeg.version>
<okhttp.version>3.14.9</okhttp.version>
<flyway-core.version>8.5.12</flyway-core.version>
<cas-client-autoconfig-support.version>2.0.0-GA</cas-client-autoconfig-support.version>
<java.version>1.8</java.version>
</properties>
@ -297,7 +298,7 @@
<dependency>
<groupId>net.unicon.cas</groupId>
<artifactId>cas-client-autoconfig-support</artifactId>
<version>2.0.0-GA</version>
<version>${cas-client-autoconfig-support.version}</version>
</dependency>
</dependencies>

View File

@ -21,6 +21,7 @@ import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.*;
import springfox.documentation.annotations.ApiIgnore;
@ -35,6 +36,13 @@ import java.util.Map;
@RequestMapping("bookMeeting")
public class BookMeetingRoomController {
@Value("${big_date.name}")
private String bigDateDeptName; // 大数据局名称
@Value("${big_date.default_assignee_role_id}")
private String defaultAssigneeRoleId; // 当某部门未设置部门审批人时将使用该用户审批
@Value("${big_date.assignee_role_name}")
private String roleName; // 具备审批的角色名称
@Resource
private TMeetingroomBookService tMeetingroomBookService;
@Resource
@ -91,6 +99,39 @@ public class BookMeetingRoomController {
}
dto.setState(1);
tMeetingroomBookService.save(dto);
// 发起预约后推送消息
String content = "【通知】请审核" + dto.getName() + "发起的" + dto.getRoomName() +
"会议室申请";
SysNoticeDTO sysNoticeDTO = new SysNoticeDTO();
sysNoticeDTO.setType(2);
sysNoticeDTO.setTitle("会议室申请审核通知");
sysNoticeDTO.setContent(content); // 通知内容
sysNoticeDTO.setReceiverType(1);
sysNoticeDTO.setReceiverTypeIds(defaultAssigneeRoleId);
sysNoticeDTO.setStatus(NoticeStatusEnum.SEND.value());
sysNoticeDTO.setSenderName("流程系统");
sysNoticeDTO.setSenderDate(new Date());
sysNoticeDTO.setCreator(dto.getCreator());
sysNoticeDTO.setCreateDate(new Date());
sysNoticeDTO.setFrom("通知");
sysNoticeService.save(sysNoticeDTO);
// 还要发送自己能看到的的谁给我审核的消息
String ownedContent = "【通知】您发起的" + dto.getRoomName() +
"会议室申请,当前审核部门为:" + bigDateDeptName + ",审核负责人:" + roleName;
SysNoticeDTO ownedSysNoticeDTO = new SysNoticeDTO();
ownedSysNoticeDTO.setType(2);
ownedSysNoticeDTO.setTitle("会议室申请发起通知");
ownedSysNoticeDTO.setContent(ownedContent); // 通知内容
ownedSysNoticeDTO.setReceiverType(1);
ownedSysNoticeDTO.setReceiverTypeIds(dto.getCreator().toString());
ownedSysNoticeDTO.setStatus(NoticeStatusEnum.SEND.value());
ownedSysNoticeDTO.setSenderName("流程系统");
ownedSysNoticeDTO.setSenderDate(new Date());
ownedSysNoticeDTO.setCreator(dto.getCreator());
ownedSysNoticeDTO.setCreateDate(new Date());
ownedSysNoticeDTO.setFrom("通知");
sysNoticeService.save(ownedSysNoticeDTO);
return new Result();
}