|
@ -48,6 +48,9 @@ router.post("/", function (req, res) {
|
|
|
let sessions = new Sessions();
|
|
|
let participantArray = [];
|
|
|
|
|
|
///是否视频会议的会话
|
|
|
let videoconferencing = false;
|
|
|
|
|
|
participants = JSON.parse(participants);
|
|
|
for (let j in participants) {
|
|
|
participantArray.push(j + ":" + participants[j]);
|
|
@ -55,6 +58,18 @@ router.post("/", function (req, res) {
|
|
|
|
|
|
ControllerUtil.regModelEventHandler(sessions, res);
|
|
|
sessions.createSession(sessionId, sessionName, sessionType, participantArray);
|
|
|
|
|
|
//视频会议的会话 szx add 20181121
|
|
|
if (!payload.hasOwnProperty('videoconferencing') && payload.videoconferencing == 1){
|
|
|
videoconferencing = true;
|
|
|
//发送广播,给相关的与会人员
|
|
|
for (let j in participants) {
|
|
|
let participant = participants[j];
|
|
|
let socketClient = ClientCache.findById(participant.userId);
|
|
|
socketClient.emt("startVideoconference",{"session_id":sessionId});
|
|
|
}
|
|
|
|
|
|
}
|
|
|
});
|
|
|
|
|
|
/**
|