Commit 1d8ee783 authored by 王晓旭's avatar 王晓旭
parents 7d665069 24b159bf
...@@ -113,6 +113,8 @@ public class MeetSwitchTaskImpl implements ITaskExcuteService { ...@@ -113,6 +113,8 @@ public class MeetSwitchTaskImpl implements ITaskExcuteService {
//通知设备进行数据更新 //通知设备进行数据更新
long expire = between * 60 == 0 ? between * 60 : 60; long expire = between * 60 == 0 ? between * 60 : 60;
log.info("会议redis 设置过期时间:{}", expire);
try {
boolean setnx = cacheService.setnx(RedisKey.KEY_METTING_START_CACHE, recordEntity.getId(), expire); boolean setnx = cacheService.setnx(RedisKey.KEY_METTING_START_CACHE, recordEntity.getId(), expire);
if (setnx) { if (setnx) {
UploadDeviceReq uploadDeviceReq = new UploadDeviceReq(); UploadDeviceReq uploadDeviceReq = new UploadDeviceReq();
...@@ -122,6 +124,10 @@ public class MeetSwitchTaskImpl implements ITaskExcuteService { ...@@ -122,6 +124,10 @@ public class MeetSwitchTaskImpl implements ITaskExcuteService {
log.info("preMeetStart send msg :{}", roomDeviceEntity.getDeviceCode()); log.info("preMeetStart send msg :{}", roomDeviceEntity.getDeviceCode());
messageFeign.downMsg(uploadDeviceReq); messageFeign.downMsg(uploadDeviceReq);
} }
}catch (Exception e){
log.error("设置异常",e);
}
} }
} }
......
...@@ -119,7 +119,6 @@ public class MettingRecordServiceImpl extends AbstractCRUDServiceImpl<MettingRec ...@@ -119,7 +119,6 @@ public class MettingRecordServiceImpl extends AbstractCRUDServiceImpl<MettingRec
protected void saveBefore(MettingRecordEntity entity, Context context) throws AppException { protected void saveBefore(MettingRecordEntity entity, Context context) throws AppException {
super.saveBefore(entity, context); super.saveBefore(entity, context);
checkStartAndEndTime(entity); checkStartAndEndTime(entity);
Boolean bool = checkExistStartMeetTime(entity); Boolean bool = checkExistStartMeetTime(entity);
if (bool) { if (bool) {
throw new AppException("当前会议室该时段已经存在等待或进行中的会议,请选择其它时间段!"); throw new AppException("当前会议室该时段已经存在等待或进行中的会议,请选择其它时间段!");
...@@ -134,6 +133,7 @@ public class MettingRecordServiceImpl extends AbstractCRUDServiceImpl<MettingRec ...@@ -134,6 +133,7 @@ public class MettingRecordServiceImpl extends AbstractCRUDServiceImpl<MettingRec
boolean in = DateUtil.isIn(new Date(), entity.getMeetTimeStart(), entity.getMeetTimeEnd()); boolean in = DateUtil.isIn(new Date(), entity.getMeetTimeStart(), entity.getMeetTimeEnd());
if (in) { if (in) {
entity.setMeetStatus(MeetStatusEnum.进行中.getValue()); entity.setMeetStatus(MeetStatusEnum.进行中.getValue());
}
//发送推送通知 //发送推送通知
RoomDeviceQuery roomDeviceQuery = new RoomDeviceQuery(); RoomDeviceQuery roomDeviceQuery = new RoomDeviceQuery();
roomDeviceQuery.setRoomId(entity.getRoomId()); roomDeviceQuery.setRoomId(entity.getRoomId());
...@@ -146,7 +146,6 @@ public class MettingRecordServiceImpl extends AbstractCRUDServiceImpl<MettingRec ...@@ -146,7 +146,6 @@ public class MettingRecordServiceImpl extends AbstractCRUDServiceImpl<MettingRec
messageFeign.downMsg(uploadDeviceReq); messageFeign.downMsg(uploadDeviceReq);
} }
} }
}
@Override @Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment