root 1 سال پیش
والد
کامیت
0aafa325c4
1فایلهای تغییر یافته به همراه24 افزوده شده و 20 حذف شده
  1. 24 20
      node/message.js

+ 24 - 20
node/message.js

@@ -526,9 +526,10 @@ us.deluser = function (userid, pageid) {
 
     var i, j, z; //定义循环变量
     var _userid, _fileid, _message, _docinfo, _messageinfo,
-        _csclids = us.offLineMessage[pageid].cscl,
-        _wordids = us.offLineMessage[pageid].word, //得到加入的所有word
-        _excelids = us.offLineMessage[pageid].excel; //得到加入的所有excel
+        _csclids = us.offLineMessage[pageid].cscl;
+    //其他应用的数据
+    // _wordids = us.offLineMessage[pageid].word, //得到加入的所有word
+    // _excelids = us.offLineMessage[pageid].excel; //得到加入的所有excel
 
     console.log(pageid)
     console.log(us.offLineMessage[pageid])
@@ -551,7 +552,7 @@ us.deluser = function (userid, pageid) {
         var _messageinfo = us.message(userid, 'us.cscl', {
             id: us.createGuid(),
             type: "delUser",
-            userid: _userid,
+            userinfo: us.user[_userid],
             docId: _fileid
         });
         _message[_fileid] = [_messageinfo];
@@ -559,23 +560,26 @@ us.deluser = function (userid, pageid) {
         us.broadcast(_message, pageid, "cscl");
     }
 
-    //word的下线的处理
-    for (i = 0; i < _wordids.length; i++) { //循环处理每一个文档
-        _docinfo = us.word[_wordids[i]]; //记录文档信息
-        if (_docinfo) { //如果存在文档信息
-            us.quitUserList(_docinfo, userid, pageid); //将用户在协同列表中删除
-            us.insertHistory(_docinfo, 'word'); //插入历史
-        }
-    }
 
-    //excel的下线的处理
-    for (j = 0; i < _excelids.length; j++) {
-        _docinfo = us.excel[_excelids[j]]; //记录文档信息
-        if (_docinfo) { //如果存在文档信息
-            us.quitUserList(_docinfo, userid, pageid); //将用户在协同列表中删除
-            us.insertHistory(_docinfo, 'excel'); //插入历史
-        }
-    }
+    //其他应用的处理
+
+    // //word的下线的处理
+    // for (i = 0; i < _wordids.length; i++) { //循环处理每一个文档
+    //     _docinfo = us.word[_wordids[i]]; //记录文档信息
+    //     if (_docinfo) { //如果存在文档信息
+    //         us.quitUserList(_docinfo, userid, pageid); //将用户在协同列表中删除
+    //         us.insertHistory(_docinfo, 'word'); //插入历史
+    //     }
+    // }
+
+    // //excel的下线的处理
+    // for (j = 0; i < _excelids.length; j++) {
+    //     _docinfo = us.excel[_excelids[j]]; //记录文档信息
+    //     if (_docinfo) { //如果存在文档信息
+    //         us.quitUserList(_docinfo, userid, pageid); //将用户在协同列表中删除
+    //         us.insertHistory(_docinfo, 'excel'); //插入历史
+    //     }
+    // }
 
 }