差别
这里会显示出您选择的修订版和当前版本之间的差别。
两侧同时换到之前的修订记录 前一修订版 后一修订版 | 前一修订版 后一修订版 两侧同时换到之后的修订记录 | ||
im:web:intro:basic [2020/04/11 11:45] zhangdong [登录] |
im:web:intro:basic [2020/07/02 03:13] zhangdong [创建连接] |
||
---|---|---|---|
行 11: | 行 11: | ||
isMultiLoginSessions: WebIM.config.isMultiLoginSessions, | isMultiLoginSessions: WebIM.config.isMultiLoginSessions, | ||
https: WebIM.config.https, | https: WebIM.config.https, | ||
- | url: WebIM.config.xmppURL, | + | url: WebIM.config.socketServer, |
- | apiUrl: WebIM.config.apiURL, | + | apiUrl: WebIM.config.restServer, |
isAutoLogin: WebIM.config.isAutoLogin, | isAutoLogin: WebIM.config.isAutoLogin, | ||
heartBeatWait: WebIM.config.heartBeatWait, | heartBeatWait: WebIM.config.heartBeatWait, | ||
行 18: | 行 18: | ||
autoReconnectInterval: WebIM.config.autoReconnectInterval, | autoReconnectInterval: WebIM.config.autoReconnectInterval, | ||
isStropheLog: WebIM.config.isStropheLog, | isStropheLog: WebIM.config.isStropheLog, | ||
- | delivery: WebIM.config.delivery | + | delivery: WebIM.config.delivery, |
+ | useOwnUploadFun: WebIM.config.useOwnUploadFun | ||
}) | }) | ||
// WebIM.config 为之前集成里介绍的WebIMConfig.js | // WebIM.config 为之前集成里介绍的WebIMConfig.js | ||
行 105: | 行 106: | ||
=== 使用 Token 登录 === | === 使用 Token 登录 === | ||
- | 1. 使用用户名/密码登录,获取并存储 Token。 | + | 1. 使用用户名/密码登录,获取Token。 |
<code javascript> | <code javascript> | ||
行 113: | 行 114: | ||
pwd: 'password', | pwd: 'password', | ||
appKey: WebIM.config.appkey, | appKey: WebIM.config.appkey, | ||
- | success: function (token) { | + | success: function (res) { |
+ | var token = res.access_token | ||
}, | }, | ||
error: function(){ | error: function(){ |