react_hsbc_teller 1.2.6 → 1.2.7
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/lib/hsbc.js +1 -1
- package/package.json +1 -1
- package/packages/pages/foot/foot.jsx +12 -2
- package/packages/pages/video/video.jsx +215 -58
package/package.json
CHANGED
|
@@ -66,7 +66,7 @@ export default class foot extends Component {
|
|
|
66
66
|
);
|
|
67
67
|
const defaultList = (
|
|
68
68
|
<div className="total totalTwo">
|
|
69
|
-
{
|
|
69
|
+
{/* {
|
|
70
70
|
isWhiteboard&&<div className='footHover' onClick={this.switchExternal.bind(this)}>
|
|
71
71
|
<div className="one">
|
|
72
72
|
<img className="imgClass" src={require("../../assets/img/switchExternal.png").default} alt="" />
|
|
@@ -75,7 +75,7 @@ export default class foot extends Component {
|
|
|
75
75
|
</div>
|
|
76
76
|
</div>
|
|
77
77
|
</div>
|
|
78
|
-
}
|
|
78
|
+
} */}
|
|
79
79
|
|
|
80
80
|
{
|
|
81
81
|
menus.map((item,index)=>{
|
|
@@ -90,6 +90,16 @@ export default class foot extends Component {
|
|
|
90
90
|
</div>
|
|
91
91
|
} */}
|
|
92
92
|
{
|
|
93
|
+
item == 'BOARD'&&<div className='footHover' onClick={this.switchExternal.bind(this)}>
|
|
94
|
+
<div className="one">
|
|
95
|
+
<img className="imgClass" src={require("../../assets/img/switchExternal.png").default} alt="" />
|
|
96
|
+
<div className="text">
|
|
97
|
+
白板
|
|
98
|
+
</div>
|
|
99
|
+
</div>
|
|
100
|
+
</div>
|
|
101
|
+
}
|
|
102
|
+
{
|
|
93
103
|
item == 'SHARE' && <div className="one" onClick={this.sharedScreen.bind(this)}>
|
|
94
104
|
<img className="imgClass" src={require("../../assets/img/Projection_screen.png").default} alt="" />
|
|
95
105
|
<div className="text">
|
|
@@ -35,6 +35,7 @@ let pictureInPictureVideo
|
|
|
35
35
|
let mix_stream
|
|
36
36
|
let worker
|
|
37
37
|
let streamShare
|
|
38
|
+
let muteJson = new Map()
|
|
38
39
|
message.config({
|
|
39
40
|
getContainer: ()=>document.getElementById('allHSBC')
|
|
40
41
|
})
|
|
@@ -1443,7 +1444,9 @@ class Video extends Component {
|
|
|
1443
1444
|
|
|
1444
1445
|
} else if (Mival.typeId == 3100) {
|
|
1445
1446
|
if (Mival.data.sessionId == this.state.sessionId) {
|
|
1447
|
+
muteJson.set(Mival.data.userId, JSON.stringify(Mival))
|
|
1446
1448
|
if (Mival.data.userId == this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId1").innerText).uid) {
|
|
1449
|
+
muteJson.delete(Mival.data.userId)
|
|
1447
1450
|
if (Mival.muteStatus == 0) {
|
|
1448
1451
|
this.setState({
|
|
1449
1452
|
voiceVideoOne: false
|
|
@@ -1456,6 +1459,7 @@ class Video extends Component {
|
|
|
1456
1459
|
|
|
1457
1460
|
}
|
|
1458
1461
|
if (Mival.data.userId == (document.getElementById("feedId2").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId2").innerText).uid : '')) {
|
|
1462
|
+
muteJson.delete(Mival.data.userId)
|
|
1459
1463
|
if (Mival.muteStatus == 0) {
|
|
1460
1464
|
this.setState({
|
|
1461
1465
|
voiceVideoTwo: false
|
|
@@ -1468,6 +1472,7 @@ class Video extends Component {
|
|
|
1468
1472
|
|
|
1469
1473
|
}
|
|
1470
1474
|
if (Mival.data.userId == (document.getElementById("feedId3").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId3").innerText).uid : '')) {
|
|
1475
|
+
muteJson.delete(Mival.data.userId)
|
|
1471
1476
|
if (Mival.muteStatus == 0) {
|
|
1472
1477
|
this.setState({
|
|
1473
1478
|
voiceVideoThree: false
|
|
@@ -1480,6 +1485,7 @@ class Video extends Component {
|
|
|
1480
1485
|
|
|
1481
1486
|
}
|
|
1482
1487
|
if (Mival.data.userId == (document.getElementById("feedId4").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId4").innerText).uid : '')) {
|
|
1488
|
+
muteJson.delete(Mival.data.userId)
|
|
1483
1489
|
if (Mival.muteStatus == 0) {
|
|
1484
1490
|
this.setState({
|
|
1485
1491
|
voiceVideoFour: false
|
|
@@ -1492,6 +1498,7 @@ class Video extends Component {
|
|
|
1492
1498
|
|
|
1493
1499
|
}
|
|
1494
1500
|
if (Mival.data.userId == (document.getElementById("feedId5").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId5").innerText).uid : '')) {
|
|
1501
|
+
muteJson.delete(Mival.data.userId)
|
|
1495
1502
|
if (Mival.muteStatus == 0) {
|
|
1496
1503
|
this.setState({
|
|
1497
1504
|
voiceVideoFive: false
|
|
@@ -1504,6 +1511,7 @@ class Video extends Component {
|
|
|
1504
1511
|
|
|
1505
1512
|
}
|
|
1506
1513
|
if (Mival.data.userId == (document.getElementById("feedId6").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId6").innerText).uid : '')) {
|
|
1514
|
+
muteJson.delete(Mival.data.userId)
|
|
1507
1515
|
if (Mival.muteStatus == 0) {
|
|
1508
1516
|
this.setState({
|
|
1509
1517
|
voiceVideoSix: false
|
|
@@ -1516,31 +1524,8 @@ class Video extends Component {
|
|
|
1516
1524
|
|
|
1517
1525
|
}
|
|
1518
1526
|
|
|
1519
|
-
if (Mival.data.userId == (document.getElementById("feedId6").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId6").innerText).uid : '')) {
|
|
1520
|
-
if (Mival.muteStatus == 0) {
|
|
1521
|
-
this.setState({
|
|
1522
|
-
voiceVideoSix: false
|
|
1523
|
-
})
|
|
1524
|
-
} else if (Mival.muteStatus == 1) {
|
|
1525
|
-
this.setState({
|
|
1526
|
-
voiceVideoSix: true
|
|
1527
|
-
})
|
|
1528
|
-
}
|
|
1529
|
-
|
|
1530
|
-
}
|
|
1531
|
-
if (Mival.data.userId == (document.getElementById("feedId6").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId6").innerText).uid : '')) {
|
|
1532
|
-
if (Mival.muteStatus == 0) {
|
|
1533
|
-
this.setState({
|
|
1534
|
-
voiceVideoSix: false
|
|
1535
|
-
})
|
|
1536
|
-
} else if (Mival.muteStatus == 1) {
|
|
1537
|
-
this.setState({
|
|
1538
|
-
voiceVideoSix: true
|
|
1539
|
-
})
|
|
1540
|
-
}
|
|
1541
|
-
|
|
1542
|
-
}
|
|
1543
1527
|
if (Mival.data.userId == (document.getElementById("feedId7").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId7").innerText).uid : '')) {
|
|
1528
|
+
muteJson.delete(Mival.data.userId)
|
|
1544
1529
|
if (Mival.muteStatus == 0) {
|
|
1545
1530
|
this.setState({
|
|
1546
1531
|
voiceVideoSeven: false
|
|
@@ -1553,6 +1538,7 @@ class Video extends Component {
|
|
|
1553
1538
|
|
|
1554
1539
|
}
|
|
1555
1540
|
if (Mival.data.userId == (document.getElementById("feedId8").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId8").innerText).uid : '')) {
|
|
1541
|
+
muteJson.delete(Mival.data.userId)
|
|
1556
1542
|
if (Mival.muteStatus == 0) {
|
|
1557
1543
|
this.setState({
|
|
1558
1544
|
voiceVideoEight: false
|
|
@@ -1565,6 +1551,7 @@ class Video extends Component {
|
|
|
1565
1551
|
|
|
1566
1552
|
}
|
|
1567
1553
|
if (Mival.data.userId == (document.getElementById("feedId9").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId9").innerText).uid : '')) {
|
|
1554
|
+
muteJson.delete(Mival.data.userId)
|
|
1568
1555
|
if (Mival.muteStatus == 0) {
|
|
1569
1556
|
this.setState({
|
|
1570
1557
|
voiceVideoNine: false
|
|
@@ -1577,6 +1564,7 @@ class Video extends Component {
|
|
|
1577
1564
|
|
|
1578
1565
|
}
|
|
1579
1566
|
if (Mival.data.userId == (document.getElementById("feedId10").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId10").innerText).uid : '')) {
|
|
1567
|
+
muteJson.delete(Mival.data.userId)
|
|
1580
1568
|
if (Mival.muteStatus == 0) {
|
|
1581
1569
|
this.setState({
|
|
1582
1570
|
voiceVideoTen: false
|
|
@@ -1589,6 +1577,7 @@ class Video extends Component {
|
|
|
1589
1577
|
|
|
1590
1578
|
}
|
|
1591
1579
|
if (Mival.data.userId == (document.getElementById("feedId11").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId11").innerText).uid : '')) {
|
|
1580
|
+
muteJson.delete(Mival.data.userId)
|
|
1592
1581
|
if (Mival.muteStatus == 0) {
|
|
1593
1582
|
this.setState({
|
|
1594
1583
|
voiceVideoEleven: false
|
|
@@ -1601,6 +1590,7 @@ class Video extends Component {
|
|
|
1601
1590
|
|
|
1602
1591
|
}
|
|
1603
1592
|
if (Mival.data.userId == (document.getElementById("feedId12").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId12").innerText).uid : '')) {
|
|
1593
|
+
muteJson.delete(Mival.data.userId)
|
|
1604
1594
|
if (Mival.muteStatus == 0) {
|
|
1605
1595
|
this.setState({
|
|
1606
1596
|
voiceVideoTwelve: false
|
|
@@ -1873,6 +1863,12 @@ class Video extends Component {
|
|
|
1873
1863
|
};
|
|
1874
1864
|
this.mpaasSig(data);
|
|
1875
1865
|
};
|
|
1866
|
+
this.test_controller.OnSendTextMsgSucc = (msgId)=>{
|
|
1867
|
+
console.log('发送成功',msgId)
|
|
1868
|
+
}
|
|
1869
|
+
this.test_controller.OnSendTextMsgFailed =(msgId, code, msg)=>{
|
|
1870
|
+
console.log('发送失败',msgId,code, msg)
|
|
1871
|
+
}
|
|
1876
1872
|
// 发布媒体流成功
|
|
1877
1873
|
this.test_controller.OnPublishSucc = (sid) => {
|
|
1878
1874
|
console.log('发布媒体流成功', sid)
|
|
@@ -1901,6 +1897,16 @@ class Video extends Component {
|
|
|
1901
1897
|
this.timer = setInterval(
|
|
1902
1898
|
() => {
|
|
1903
1899
|
if(!this.state.voiceStatue && this.state.analyserHeight.get(sid).toFixed(2) > 0.1) {
|
|
1900
|
+
// this.test_controller.SendTextMsg(JSON.stringify({
|
|
1901
|
+
// 'typeId': 3200,
|
|
1902
|
+
// 'decibelValue': this.state.analyserHeight.get(sid).toFixed(2),
|
|
1903
|
+
// "data": {
|
|
1904
|
+
// 'sessionId': this.state.sessionId,
|
|
1905
|
+
// 'userId': this.props.tellerAccount,
|
|
1906
|
+
// 'data': (new Date()).valueOf()
|
|
1907
|
+
// }
|
|
1908
|
+
|
|
1909
|
+
// }))
|
|
1904
1910
|
callNimIM('sendCustomCmdMsg', {
|
|
1905
1911
|
customId: this.state.imRoomId,
|
|
1906
1912
|
content: JSON.stringify({
|
|
@@ -1935,6 +1941,171 @@ class Video extends Component {
|
|
|
1935
1941
|
this.test_controller.OnSubscribeSucc = (feed, sid) => {
|
|
1936
1942
|
console.log('订阅媒体流成功', feed, sid);
|
|
1937
1943
|
this.appGetUsername(sid)
|
|
1944
|
+
console.log(muteJson,muteJson.size)
|
|
1945
|
+
if(muteJson.size > 0) {
|
|
1946
|
+
let userId = ''
|
|
1947
|
+
if (muteJson.get(this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId1").innerText).uid)) {
|
|
1948
|
+
userId = this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId1").innerText).uid
|
|
1949
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
1950
|
+
this.setState({
|
|
1951
|
+
voiceVideoOne: false
|
|
1952
|
+
})
|
|
1953
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
1954
|
+
this.setState({
|
|
1955
|
+
voiceVideoOne: true
|
|
1956
|
+
})
|
|
1957
|
+
}
|
|
1958
|
+
muteJson.delete(userId)
|
|
1959
|
+
}
|
|
1960
|
+
if (muteJson.get(document.getElementById("feedId2").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId2").innerText).uid : '')) {
|
|
1961
|
+
userId = document.getElementById("feedId2").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId2").innerText).uid : ''
|
|
1962
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
1963
|
+
this.setState({
|
|
1964
|
+
voiceVideoTwo: false
|
|
1965
|
+
})
|
|
1966
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
1967
|
+
this.setState({
|
|
1968
|
+
voiceVideoTwo: true
|
|
1969
|
+
})
|
|
1970
|
+
}
|
|
1971
|
+
muteJson.delete(userId)
|
|
1972
|
+
}
|
|
1973
|
+
if (muteJson.get(document.getElementById("feedId3").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId3").innerText).uid : '')) {
|
|
1974
|
+
userId = document.getElementById("feedId3").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId3").innerText).uid : ''
|
|
1975
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
1976
|
+
this.setState({
|
|
1977
|
+
voiceVideoThree: false
|
|
1978
|
+
})
|
|
1979
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
1980
|
+
this.setState({
|
|
1981
|
+
voiceVideoThree: true
|
|
1982
|
+
})
|
|
1983
|
+
}
|
|
1984
|
+
muteJson.delete(userId)
|
|
1985
|
+
}
|
|
1986
|
+
if (muteJson.get(document.getElementById("feedId4").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId4").innerText).uid : '')) {
|
|
1987
|
+
userId = document.getElementById("feedId4").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId4").innerText).uid : ''
|
|
1988
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
1989
|
+
this.setState({
|
|
1990
|
+
voiceVideoFour: false
|
|
1991
|
+
})
|
|
1992
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
1993
|
+
this.setState({
|
|
1994
|
+
voiceVideoFour: true
|
|
1995
|
+
})
|
|
1996
|
+
}
|
|
1997
|
+
muteJson.delete(userId)
|
|
1998
|
+
}
|
|
1999
|
+
if (muteJson.get(document.getElementById("feedId5").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId5").innerText).uid : '')) {
|
|
2000
|
+
userId = document.getElementById("feedId5").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId5").innerText).uid : ''
|
|
2001
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
2002
|
+
this.setState({
|
|
2003
|
+
voiceVideoFive: false
|
|
2004
|
+
})
|
|
2005
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
2006
|
+
this.setState({
|
|
2007
|
+
voiceVideoFive: true
|
|
2008
|
+
})
|
|
2009
|
+
}
|
|
2010
|
+
muteJson.delete(userId)
|
|
2011
|
+
}
|
|
2012
|
+
if (muteJson.get(document.getElementById("feedId6").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId6").innerText).uid : '')) {
|
|
2013
|
+
userId = document.getElementById("feedId6").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId6").innerText).uid : ''
|
|
2014
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
2015
|
+
this.setState({
|
|
2016
|
+
voiceVideoSix: false
|
|
2017
|
+
})
|
|
2018
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
2019
|
+
this.setState({
|
|
2020
|
+
voiceVideoSix: true
|
|
2021
|
+
})
|
|
2022
|
+
}
|
|
2023
|
+
muteJson.delete(userId)
|
|
2024
|
+
}
|
|
2025
|
+
if (muteJson.get(document.getElementById("feedId7").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId7").innerText).uid : '')) {
|
|
2026
|
+
userId = document.getElementById("feedId7").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId7").innerText).uid : ''
|
|
2027
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
2028
|
+
this.setState({
|
|
2029
|
+
voiceVideoSeven: false
|
|
2030
|
+
})
|
|
2031
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
2032
|
+
this.setState({
|
|
2033
|
+
voiceVideoSeven: true
|
|
2034
|
+
})
|
|
2035
|
+
}
|
|
2036
|
+
muteJson.delete(userId)
|
|
2037
|
+
}
|
|
2038
|
+
if (muteJson.get(document.getElementById("feedId8").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId8").innerText).uid : '')) {
|
|
2039
|
+
userId = document.getElementById("feedId8").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId8").innerText).uid : ''
|
|
2040
|
+
|
|
2041
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
2042
|
+
this.setState({
|
|
2043
|
+
voiceVideoEight: false
|
|
2044
|
+
})
|
|
2045
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
2046
|
+
this.setState({
|
|
2047
|
+
voiceVideoEight: true
|
|
2048
|
+
})
|
|
2049
|
+
}
|
|
2050
|
+
muteJson.delete(userId)
|
|
2051
|
+
}
|
|
2052
|
+
if (muteJson.get(document.getElementById("feedId9").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId9").innerText).uid : '')) {
|
|
2053
|
+
userId = document.getElementById("feedId9").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId9").innerText).uid : ''
|
|
2054
|
+
|
|
2055
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
2056
|
+
this.setState({
|
|
2057
|
+
voiceVideoNine: false
|
|
2058
|
+
})
|
|
2059
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
2060
|
+
this.setState({
|
|
2061
|
+
voiceVideoNine: true
|
|
2062
|
+
})
|
|
2063
|
+
}
|
|
2064
|
+
muteJson.delete(userId)
|
|
2065
|
+
}
|
|
2066
|
+
if (muteJson.get(document.getElementById("feedId10").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId10").innerText).uid : '')) {
|
|
2067
|
+
userId = document.getElementById("feedId10").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId10").innerText).uid : ''
|
|
2068
|
+
|
|
2069
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
2070
|
+
this.setState({
|
|
2071
|
+
voiceVideoTen: false
|
|
2072
|
+
})
|
|
2073
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
2074
|
+
this.setState({
|
|
2075
|
+
voiceVideoTen: true
|
|
2076
|
+
})
|
|
2077
|
+
}
|
|
2078
|
+
muteJson.delete(userId)
|
|
2079
|
+
}
|
|
2080
|
+
if (muteJson.get(document.getElementById("feedId11").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId11").innerText).uid : '')) {
|
|
2081
|
+
userId = document.getElementById("feedId11").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId11").innerText).uid : ''
|
|
2082
|
+
|
|
2083
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
2084
|
+
this.setState({
|
|
2085
|
+
voiceVideoEleven: false
|
|
2086
|
+
})
|
|
2087
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
2088
|
+
this.setState({
|
|
2089
|
+
voiceVideoEleven: true
|
|
2090
|
+
})
|
|
2091
|
+
}
|
|
2092
|
+
muteJson.delete(userId)
|
|
2093
|
+
}
|
|
2094
|
+
if (muteJson.get(document.getElementById("feedId12").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId12").innerText).uid : '')) {
|
|
2095
|
+
userId = document.getElementById("feedId12").innerText ? this.seeList(this.state.roomCustomerList, 'feedId', document.getElementById("feedId12").innerText).uid : ''
|
|
2096
|
+
if (JSON.parse(muteJson.get(userId)).muteStatus == 0) {
|
|
2097
|
+
this.setState({
|
|
2098
|
+
voiceVideoTwelve: false
|
|
2099
|
+
})
|
|
2100
|
+
} else if (JSON.parse(muteJson.get(userId)).muteStatus == 1) {
|
|
2101
|
+
this.setState({
|
|
2102
|
+
voiceVideoTwelve: true
|
|
2103
|
+
})
|
|
2104
|
+
}
|
|
2105
|
+
muteJson.delete(userId)
|
|
2106
|
+
}
|
|
2107
|
+
console.log(muteJson,muteJson.length)
|
|
2108
|
+
}
|
|
1938
2109
|
};
|
|
1939
2110
|
// 订阅媒体流失败
|
|
1940
2111
|
this.test_controller.OnSubscribeFailed = (
|
|
@@ -2089,7 +2260,9 @@ class Video extends Component {
|
|
|
2089
2260
|
if (config_param !== undefined) {
|
|
2090
2261
|
config_param.need_volume_analyser = true
|
|
2091
2262
|
console.log(config_param)
|
|
2092
|
-
|
|
2263
|
+
setTimeout(() => {
|
|
2264
|
+
this.test_controller.Subscribe(config_param)
|
|
2265
|
+
}, 2000);
|
|
2093
2266
|
}
|
|
2094
2267
|
})
|
|
2095
2268
|
}
|
|
@@ -2122,12 +2295,11 @@ class Video extends Component {
|
|
|
2122
2295
|
})
|
|
2123
2296
|
}, function (code, message, data) {
|
|
2124
2297
|
})
|
|
2125
|
-
if(this.state.voiceStatue) {
|
|
2126
2298
|
callNimIM('sendCustomCmdMsg', {
|
|
2127
2299
|
customId: this.state.imRoomId,
|
|
2128
2300
|
content: JSON.stringify({
|
|
2129
2301
|
'typeId': 1013,
|
|
2130
|
-
'muteStatus': 1,
|
|
2302
|
+
'muteStatus': this.state.voiceStatue ? 1 : 0,
|
|
2131
2303
|
'data': {
|
|
2132
2304
|
'sessionId': this.state.sessionId,
|
|
2133
2305
|
'userId': this.props.tellerAccount
|
|
@@ -2136,7 +2308,7 @@ class Video extends Component {
|
|
|
2136
2308
|
}, function (code, message, data) {
|
|
2137
2309
|
console.log(data)
|
|
2138
2310
|
})
|
|
2139
|
-
|
|
2311
|
+
|
|
2140
2312
|
let array = this.state.roomCustomerList;
|
|
2141
2313
|
let newArray = [...array];
|
|
2142
2314
|
newArray.push({
|
|
@@ -2303,7 +2475,9 @@ class Video extends Component {
|
|
|
2303
2475
|
config_param.need_volume_analyser = true
|
|
2304
2476
|
console.log(config_param)
|
|
2305
2477
|
|
|
2306
|
-
|
|
2478
|
+
setTimeout(() => {
|
|
2479
|
+
this.test_controller.Subscribe(config_param)
|
|
2480
|
+
}, 2000);
|
|
2307
2481
|
|
|
2308
2482
|
}
|
|
2309
2483
|
// })
|
|
@@ -2784,7 +2958,7 @@ class Video extends Component {
|
|
|
2784
2958
|
let number = 0
|
|
2785
2959
|
for (var i = 0; i < 40; i++) {
|
|
2786
2960
|
|
|
2787
|
-
let energy = (dataArray[step * i] / 256.0) *
|
|
2961
|
+
let energy = (dataArray[step * i] / 256.0) * 100;
|
|
2788
2962
|
number = number + energy
|
|
2789
2963
|
ctx.beginPath();
|
|
2790
2964
|
ctx.fillStyle = this.props.voiceColor;
|
|
@@ -2795,7 +2969,6 @@ class Video extends Component {
|
|
|
2795
2969
|
let startY = y1 - height // 绘制起始点y
|
|
2796
2970
|
ctx.fillRect(startX, startY, width, height)
|
|
2797
2971
|
if(document.getElementById('publish_video1').name == sid && i == 39) {
|
|
2798
|
-
console.log(number / 40 / 70,number / 40)
|
|
2799
2972
|
this.state.analyserHeight.set(sid,number / 40 / 70)
|
|
2800
2973
|
this.state.analyserHeight = this.state.analyserHeight
|
|
2801
2974
|
}
|
|
@@ -3772,35 +3945,19 @@ class Video extends Component {
|
|
|
3772
3945
|
this.signCanvas.current.canvas.drawing.toDataURL('image/png').replace(/data.+?;base64,/, "")
|
|
3773
3946
|
)
|
|
3774
3947
|
}
|
|
3775
|
-
switchExternalAge = ()=>{
|
|
3776
|
-
if(this.state.isSharedScreen) {
|
|
3777
|
-
this.state.isSharedScreen = false
|
|
3778
|
-
this.setState({
|
|
3779
|
-
|
|
3780
|
-
screenName: '共享模式'
|
|
3781
|
-
});
|
|
3782
|
-
this.tabTitlesClick('RMScreen', 'delect')
|
|
3783
|
-
if (this.state.isPictureInPicture) {
|
|
3784
|
-
document.exitPictureInPicture()
|
|
3785
|
-
}
|
|
3786
|
-
}
|
|
3787
3948
|
|
|
3788
|
-
this.navigatorClick()
|
|
3789
|
-
|
|
3790
|
-
}
|
|
3791
3949
|
navigatorClick=()=>{
|
|
3792
3950
|
const that = this
|
|
3793
3951
|
const publish_config = {};
|
|
3794
3952
|
const canvas = document.createElement('canvas');
|
|
3795
3953
|
const videoMedia = document.getElementById('manedvideo');
|
|
3796
3954
|
const cobj = canvas.getContext('2d'); // 获取绘图环境
|
|
3797
|
-
const left =document.getElementById("
|
|
3955
|
+
const left =document.getElementById("whiteboardDIV").getBoundingClientRect().left;
|
|
3798
3956
|
const right = document.getElementById("whiteboardDIV").getBoundingClientRect().right
|
|
3799
3957
|
const top = document.getElementById("whiteboardDIV").getBoundingClientRect().top
|
|
3800
3958
|
const bottom = document.getElementById("whiteboardDIV").getBoundingClientRect().bottom
|
|
3801
|
-
const width = right - left
|
|
3802
|
-
const height = bottom - top
|
|
3803
|
-
const x = left - 20 > 0 ? left - 20 : 0
|
|
3959
|
+
const width = right - left + 50
|
|
3960
|
+
const height = bottom - top
|
|
3804
3961
|
canvas.width = width;
|
|
3805
3962
|
canvas.height = height;
|
|
3806
3963
|
videoMedia.addEventListener('play', (event) =>{
|
|
@@ -3809,7 +3966,7 @@ class Video extends Component {
|
|
|
3809
3966
|
loop()
|
|
3810
3967
|
function loop() {
|
|
3811
3968
|
if (!$this.paused && !$this.ended) {
|
|
3812
|
-
cobj.drawImage(videoMedia,
|
|
3969
|
+
cobj.drawImage(videoMedia, left, top, width, height, 0, 0,width, height,);
|
|
3813
3970
|
setTimeout(loop, 1000 / 10); // drawing at 30fps
|
|
3814
3971
|
}
|
|
3815
3972
|
}
|
|
@@ -3844,6 +4001,9 @@ class Video extends Component {
|
|
|
3844
4001
|
preferCurrentTab:true,
|
|
3845
4002
|
})
|
|
3846
4003
|
.then((stream) => {
|
|
4004
|
+
if(streamShare) {
|
|
4005
|
+
streamShare.getTracks().forEach(track => track.stop());
|
|
4006
|
+
}
|
|
3847
4007
|
videoMedia.srcObject = stream;
|
|
3848
4008
|
stream.getVideoTracks()[0].applyConstraints({
|
|
3849
4009
|
width: document.body.offsetWidth,
|
|
@@ -3881,12 +4041,9 @@ class Video extends Component {
|
|
|
3881
4041
|
document.exitPictureInPicture()
|
|
3882
4042
|
}
|
|
3883
4043
|
}
|
|
3884
|
-
this.navigatorClick()
|
|
3885
|
-
} else {
|
|
3886
|
-
this.messageClick('当前已经切换RM白板','success')
|
|
3887
|
-
|
|
3888
4044
|
}
|
|
3889
|
-
|
|
4045
|
+
|
|
4046
|
+
this.navigatorClick()
|
|
3890
4047
|
}
|
|
3891
4048
|
}
|
|
3892
4049
|
switchSelect = (value) => {
|
|
@@ -4677,7 +4834,7 @@ class Video extends Component {
|
|
|
4677
4834
|
invitationClick={this.invitationClick}
|
|
4678
4835
|
customerFaceClick={this.customerFaceClick}
|
|
4679
4836
|
ocrClick={this.ocrClick}
|
|
4680
|
-
switchExternal={this.
|
|
4837
|
+
switchExternal={this.switchExternal}
|
|
4681
4838
|
inspection={this.inspection}
|
|
4682
4839
|
></Foot>
|
|
4683
4840
|
<Modal cancelText="取消" okText="确定" visible={this.state.isModalVisible} onOk={this.handleOk}
|
|
@@ -4827,7 +4984,7 @@ sessionId: "",
|
|
|
4827
4984
|
microphoneSize: 25,
|
|
4828
4985
|
fontSize: '14',
|
|
4829
4986
|
fontFamily: 'auto',
|
|
4830
|
-
menus: ['SHARE', 'FRIES', 'OCR', 'INVITE', 'PIP'],
|
|
4987
|
+
menus: ['BOARD','SHARE', 'FRIES', 'OCR', 'INVITE', 'PIP'],
|
|
4831
4988
|
customLeaveRoom: '客户离开房间',
|
|
4832
4989
|
meetingInfo: {
|
|
4833
4990
|
title: '--',
|