zby-live-sdk 1.0.49-beta20230402 → 1.0.49-beta20230427
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +40 -48
- package/dist/zby-live-sdk.cjs.js +3 -3
- package/dist/zby-live-sdk.esm.js +3 -3
- package/dist/zby-live-sdk.umd.js +3 -3
- package/package.json +1 -1
- package/src/channel/pomelo/index.js +3 -3
- package/src/channel/pomelo/polemo.js +1 -2
- package/src/config/config.js +16 -3
- package/src/zby-live-sdk.js +2 -0
package/package.json
CHANGED
|
@@ -21,15 +21,15 @@ const pomeloObj = {
|
|
|
21
21
|
return;
|
|
22
22
|
}
|
|
23
23
|
this.log('channel_log : start joining pomelo ......');
|
|
24
|
-
const { userId, roomId, chatUrl, userName, role, institutionId, guid
|
|
25
|
-
const _args = { userId, roomId, host: chatUrl, userName, institutionId, guid, role: polemoUtil.translateRole(role)
|
|
24
|
+
const { userId, roomId, chatUrl, userName, role, institutionId, guid} = args;
|
|
25
|
+
const _args = { userId, roomId, host: chatUrl, userName, institutionId, guid, role: polemoUtil.translateRole(role) };
|
|
26
26
|
this.log(`joinRoom: args: ${JSON.stringify(_args)}`);
|
|
27
27
|
this.initParams = _args;
|
|
28
28
|
// 定时检查发送消息列表
|
|
29
29
|
// this.checkSendMsgList();
|
|
30
30
|
const res = await pomeloClient.joinRoom({
|
|
31
31
|
..._args,
|
|
32
|
-
roomId:
|
|
32
|
+
roomId: util.getConfId(institutionId, roomId)
|
|
33
33
|
}, dealCb);
|
|
34
34
|
// 加入房间成功
|
|
35
35
|
if (res.code === 200) {
|
|
@@ -628,8 +628,7 @@ class PomeloClient {
|
|
|
628
628
|
role: channelInfo.role,
|
|
629
629
|
classid: channelInfo.roomId,
|
|
630
630
|
protocolVersion: '1.0',
|
|
631
|
-
uniqId: channelInfo.guid
|
|
632
|
-
orgId: channelInfo.orgId
|
|
631
|
+
uniqId: channelInfo.guid
|
|
633
632
|
};
|
|
634
633
|
|
|
635
634
|
return new Promise(async (resolve, reject) => {
|
package/src/config/config.js
CHANGED
|
@@ -7,13 +7,18 @@ const prefix = {
|
|
|
7
7
|
online : ''
|
|
8
8
|
};
|
|
9
9
|
|
|
10
|
+
const saasModeApi = {
|
|
11
|
+
1: 'Bp', // 标品
|
|
12
|
+
2: '', // 银联
|
|
13
|
+
}
|
|
14
|
+
|
|
10
15
|
const urls = {
|
|
11
16
|
api : 'api.weclassroom.com',
|
|
12
17
|
report : 's.weclassroom.com'
|
|
13
18
|
};
|
|
14
19
|
|
|
15
20
|
// export const version = require('../../package.json').version;
|
|
16
|
-
export const version = '1.0.49-
|
|
21
|
+
export const version = '1.0.49-beta20230427';
|
|
17
22
|
|
|
18
23
|
export const liveExt = {
|
|
19
24
|
name: 'live',
|
|
@@ -64,6 +69,7 @@ export let config = {
|
|
|
64
69
|
isHttps: true,
|
|
65
70
|
env: 'test',
|
|
66
71
|
weblog: true,
|
|
72
|
+
saasMode: 2,
|
|
67
73
|
};
|
|
68
74
|
|
|
69
75
|
export const getBaseUrl = (type='api') => {
|
|
@@ -114,14 +120,21 @@ const apiMixStreams = {
|
|
|
114
120
|
online: 'https://tf-classroom-online.vdyoo.com'
|
|
115
121
|
};
|
|
116
122
|
|
|
123
|
+
//开启混流-标品
|
|
124
|
+
const apiMixStreamsBp = {
|
|
125
|
+
test: 'https://tf-bp-classroom-test.vdyoo.com',
|
|
126
|
+
online: 'https://tf-classroom-online.vdyoo.com'
|
|
127
|
+
};
|
|
128
|
+
|
|
117
129
|
export const getApiCloudBaseUrl = () => {
|
|
118
130
|
const {env} = config;
|
|
119
131
|
return apiCloudUrl[env];
|
|
120
132
|
};
|
|
121
133
|
|
|
122
134
|
export const getApiMixStreams = () => {
|
|
123
|
-
const {env} = config;
|
|
124
|
-
|
|
135
|
+
const { env ,saasMode} = config;
|
|
136
|
+
const urls = `apiMixStreams${saasModeApi[saasMode]}`
|
|
137
|
+
return urls[env];
|
|
125
138
|
}
|
|
126
139
|
|
|
127
140
|
export const getApiChangeSdkUrl = () => {
|
package/src/zby-live-sdk.js
CHANGED
|
@@ -153,6 +153,8 @@ function caculateDeatailArgs(baseArgs, cloudData) {
|
|
|
153
153
|
live_id: baseArgs.liveId,
|
|
154
154
|
// 课堂模式,0=小组课/1=新小班
|
|
155
155
|
classMode: +baseArgs.classMode,
|
|
156
|
+
// saas业务类型-不同的saas业务线有不同的域名(不传默认是银联) 1=标品
|
|
157
|
+
saasMode: +baseArgs.saasMode,
|
|
156
158
|
//数据上报班课类型
|
|
157
159
|
liveType: +baseArgs.liveType,
|
|
158
160
|
//是否开启转推功能
|