Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
shuidiapp
shuidiapp
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Operations
    • Operations
    • Incidents
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • 互联网应用开发
  • shuidiappshuidiapp
  • Wiki
  • im

im · Changes

Page history
xiaolong.jin created page: get_company_info authored Nov 24, 2016 by 互联网应用开发's avatar 互联网应用开发
Hide whitespace changes
Inline Side-by-side
Showing with 29 additions and 0 deletions
+29 -0
  • im.md im.md +29 -0
  • No files found.
im.md
View page @ bda73f79
...@@ -58,3 +58,32 @@ var uid_sinature = RSF.getCookie('uid_sinature'); ...@@ -58,3 +58,32 @@ var uid_sinature = RSF.getCookie('uid_sinature');
}); });
``` ```
#### 使用shuidiIm类
```js
RSF.regist("Shuidi.User");
Shuidi.User = function(){
};
Shuidi.User.prototype = {
'init':function(){
var shuidiIm = new ShuidiIm();
shuidiIm.init();
shuidiIm.onMessage = function(message){
console.log(message.message);
};
shuidiIm.ready = function(data){
console.log('聊天服务准备完毕');
};
setInterval(function(){
var msg = new ShuidiIm.Message();
msg.fid = shuidiIm.uid;
msg.toid = shuidiIm.uid;
msg.message = '测试消息'+new Date().getTime();
shuidiIm.sendMessage(msg);
},1000);
}
};
```
Clone repository
  • add_application
  • agree_application
  • api_desc
  • api_list
  • autobiography
  • base_info
  • branch
  • cancel_follow
  • change
  • change_applicant_name
  • change_avatar
  • change_logo
  • change_nickname
  • change_password
  • change_position
View All Pages