This commit is contained in:
parent
d6bdecc359
commit
b978744362
Binary file not shown.
|
After Width: | Height: | Size: 416 B |
Binary file not shown.
|
After Width: | Height: | Size: 411 B |
Binary file not shown.
|
After Width: | Height: | Size: 417 B |
Binary file not shown.
|
After Width: | Height: | Size: 524 B |
|
|
@ -11,6 +11,7 @@ let reconnectTime = "" as any;
|
||||||
let refreshTime = "" as any;
|
let refreshTime = "" as any;
|
||||||
let isAutoApplySpeakTime = "" as any;
|
let isAutoApplySpeakTime = "" as any;
|
||||||
let isSpeakTime = "" as any;
|
let isSpeakTime = "" as any;
|
||||||
|
let netWorkTime = "" as any;
|
||||||
Page({
|
Page({
|
||||||
behaviors: [computedBehavior],
|
behaviors: [computedBehavior],
|
||||||
data: {
|
data: {
|
||||||
|
|
@ -110,7 +111,8 @@ Page({
|
||||||
reconnecNumber: 0,
|
reconnecNumber: 0,
|
||||||
setting: {
|
setting: {
|
||||||
voiceStimulation: true, //语音激励
|
voiceStimulation: true, //语音激励
|
||||||
}
|
},
|
||||||
|
network: -1
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'roomUserList.**': function (roomUserList) {
|
'roomUserList.**': function (roomUserList) {
|
||||||
|
|
@ -350,9 +352,6 @@ Page({
|
||||||
}
|
}
|
||||||
agora.destroy(() => {
|
agora.destroy(() => {
|
||||||
this.startReconnec()
|
this.startReconnec()
|
||||||
reconnectTime = setInterval(() => {
|
|
||||||
this.startReconnec()
|
|
||||||
}, 3000)
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
async startReconnec() {
|
async startReconnec() {
|
||||||
|
|
@ -403,6 +402,9 @@ Page({
|
||||||
this.setData({
|
this.setData({
|
||||||
reconnecNumber: this.data.reconnecNumber + 1
|
reconnecNumber: this.data.reconnecNumber + 1
|
||||||
})
|
})
|
||||||
|
reconnectTime = setTimeout(() => {
|
||||||
|
this.startReconnec()
|
||||||
|
}, 3000)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
@ -413,7 +415,7 @@ Page({
|
||||||
refreshTime = ''
|
refreshTime = ''
|
||||||
}
|
}
|
||||||
if (reconnectTime) {
|
if (reconnectTime) {
|
||||||
clearInterval(reconnectTime)
|
clearTimeout(reconnectTime)
|
||||||
reconnectTime = ''
|
reconnectTime = ''
|
||||||
}
|
}
|
||||||
if (isAutoApplySpeakTime) {
|
if (isAutoApplySpeakTime) {
|
||||||
|
|
@ -424,6 +426,10 @@ Page({
|
||||||
clearInterval(isSpeakTime)
|
clearInterval(isSpeakTime)
|
||||||
isSpeakTime = ''
|
isSpeakTime = ''
|
||||||
}
|
}
|
||||||
|
if (netWorkTime) {
|
||||||
|
clearTimeout(netWorkTime)
|
||||||
|
netWorkTime = ''
|
||||||
|
}
|
||||||
},
|
},
|
||||||
// 显示聊天输入框
|
// 显示聊天输入框
|
||||||
showInputPopup() {
|
showInputPopup() {
|
||||||
|
|
@ -1047,6 +1053,33 @@ Page({
|
||||||
this.message('操作成功').success()
|
this.message('操作成功').success()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
measureSpeed() {
|
||||||
|
const startTime = Date.now();
|
||||||
|
wx.request({
|
||||||
|
url: 'https://meeting-api.23544.com/pc/room/checkout?roomNum=111111',
|
||||||
|
timeout: 10000,
|
||||||
|
header: {
|
||||||
|
'content-type': 'application/json',
|
||||||
|
},
|
||||||
|
success: res => {
|
||||||
|
const endTime = Date.now();
|
||||||
|
const duration = endTime - startTime;
|
||||||
|
this.setData({
|
||||||
|
network: Number((duration / 1000).toFixed(0))
|
||||||
|
})
|
||||||
|
},
|
||||||
|
fail: res => {
|
||||||
|
this.setData({
|
||||||
|
network: -1
|
||||||
|
})
|
||||||
|
},
|
||||||
|
complete: res => {
|
||||||
|
netWorkTime = setTimeout(() => {
|
||||||
|
this.measureSpeed()
|
||||||
|
}, 3000);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
// 关闭弹窗
|
// 关闭弹窗
|
||||||
async closeDialog(e) {
|
async closeDialog(e) {
|
||||||
const { type } = e.currentTarget.dataset;
|
const { type } = e.currentTarget.dataset;
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,11 @@
|
||||||
<!--pages/meeting/index.wxml-->
|
<!--pages/meeting/index.wxml-->
|
||||||
<view class="meeting">
|
<view class="meeting">
|
||||||
<view wx:if="{{!isFullscreen}}">
|
<view wx:if="{{!isFullscreen}}" style="position: relative;">
|
||||||
<header-tab title='会议号:{{roomInfo.roomNum}} 会议名称:{{roomInfo.roomName}}' backGround='rgb(35,36,38)' iconSize='24' color="white" titleStyle='padding:12rpx 0;font-size:16rpx' isStatusBarHeight="{{false}}" isBack='{{false}}'></header-tab>
|
<header-tab title='会议号:{{roomInfo.roomNum}} 会议名称:{{roomInfo.roomName}}' backGround='rgb(35,36,38)' iconSize='24' color="white" titleStyle='padding:12rpx 0;font-size:16rpx' isStatusBarHeight="{{false}}" isBack='{{false}}'></header-tab>
|
||||||
|
<!-- <image src="/assets/icon11.png" style="width: 20rpx;height: 20rpx;position: absolute;left: 20rpx;top: 50%;transform: translate(0,-50%);" wx:if="{{network >=0 && network < 4}}" />
|
||||||
|
<image src="/assets/icon12.png" style="width: 20rpx;height: 20rpx;position: absolute;left: 20rpx;top: 50%;transform: translate(0,-50%);" wx:elif="{{network > 4 && network < 7}}" />
|
||||||
|
<image src="/assets/icon14.png" style="width: 20rpx;height: 20rpx;position: absolute;left: 20rpx;top: 50%;transform: translate(0,-50%);" wx:elif="{{network === -1}}" />
|
||||||
|
<image src="/assets/icon13.png" style="width: 20rpx;height: 20rpx;position: absolute;left: 20rpx;top: 50%;transform: translate(0,-50%);" wx:else /> -->
|
||||||
</view>
|
</view>
|
||||||
<view class="meeting-content">
|
<view class="meeting-content">
|
||||||
<view class="meeting-content-noAdmin" wx:if="{{isAdmin === 0}}">
|
<view class="meeting-content-noAdmin" wx:if="{{isAdmin === 0}}">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue