|
@@ -753,16 +753,16 @@ public class RoomServiceImpl implements RoomService {
|
|
|
taskInfo.setRoomId(roomId);
|
|
|
taskInfo.setTypeEnum(typeEnum);
|
|
|
taskInfo.setOnOff(true);
|
|
|
- taskInfo.setApplyUserId(userId);
|
|
|
+ taskInfo.setApplyUserId(authUser.getId().toString());
|
|
|
taskInfo.setTargetUserId(userId);
|
|
|
taskInfo.setTicket(ticket);
|
|
|
scheduleManager.addTask(taskInfo);
|
|
|
ControlDeviceNotifyMessage msg = new ControlDeviceNotifyMessage(ActionEnum.Invite.ordinal());
|
|
|
msg.setTicket(ticket);
|
|
|
msg.setType(taskInfo.getTypeEnum().ordinal());
|
|
|
- msg.setOpUserId(userId);
|
|
|
+ msg.setOpUserId(authUser.getId().toString());
|
|
|
msg.setOpUserName(authUser.getUsername());
|
|
|
- imHelper.publishMessage(userId, userId, roomId, msg);
|
|
|
+ imHelper.publishMessage(authUser.getId().toString(), userId, roomId, msg);
|
|
|
} else {
|
|
|
if (typeEnum.equals(DeviceTypeEnum.Camera)) {
|
|
|
roomMemberDao.updateCameraByRidAndUid(roomId, userId, false);
|
|
@@ -1238,14 +1238,13 @@ public class RoomServiceImpl implements RoomService {
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- @Transactional(rollbackFor = Exception.class,isolation = Isolation.READ_COMMITTED)
|
|
|
+ @Transactional(rollbackFor = Exception.class)
|
|
|
public boolean statusSync(String roomId,String userId) throws Exception {
|
|
|
log.info("statusSync: roomId={}, userId={}", roomId, userId);
|
|
|
List<RoomMember> byRidAndUid = roomMemberDao.findByRidAndUid(roomId, userId);
|
|
|
if(byRidAndUid.size() > 0){
|
|
|
// SysUser sysUser = sysUserFeignService.queryUserById(Integer.parseInt(userId));
|
|
|
SysUser sysUser = teacherDao.getUser(Integer.parseInt(userId));
|
|
|
- studentDao.lockUser(Integer.parseInt(userId));
|
|
|
Teacher teacher = teacherDao.get(sysUser.getId());
|
|
|
CourseSchedule courseSchedule = courseScheduleDao.get(Long.parseLong(roomId.substring(1)));
|
|
|
log.info("statusSyncLevelRoom: roomId={}, userId={}", roomId, userId);
|