From b2ee6aa008abfb9d4eed6256dc3610cfdfb7a9a5 Mon Sep 17 00:00:00 2001 From: yj <1336058017@qq.com> Date: Fri, 27 Sep 2024 15:16:54 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E9=80=80=E5=87=BA=E6=88=BF=E9=97=B4?= =?UTF-8?q?=E4=BC=98=E5=8C=96&=E5=AF=BC=E5=87=BA=E5=8F=82=E4=BC=9A?= =?UTF-8?q?=E8=AE=B0=E5=BD=95=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/page/Home/Index/index.tsx | 19 ++++++++++++++----- src/page/Meeting/index.tsx | 7 +++++-- src/utils/package/signalr.ts | 15 ++++++--------- src/utils/styles/App.scss | 6 +++++- 4 files changed, 30 insertions(+), 17 deletions(-) diff --git a/src/page/Home/Index/index.tsx b/src/page/Home/Index/index.tsx index 765597c..349390b 100644 --- a/src/page/Home/Index/index.tsx +++ b/src/page/Home/Index/index.tsx @@ -34,6 +34,7 @@ const Index: React.FC = () => { const stupWizardRef = useRef(); const [user, setUser] = useState({}); const [currentRoomInfo, setCurrentRoomInfo] = useState({}); + const [timeData, setTimeData] = useState([]); const userInfo = JSON.parse(storage.getItem('user') as string) useEffect(() => { setUser(userInfo) @@ -386,15 +387,23 @@ const Index: React.FC = () => { - setTimeSelectModal(false)} centered width={'400px'}> + setTimeSelectModal(false)} centered maskClosable={false} width={'400px'}>
{ + setTimeData(dateString) + }} + /> +
+ + +
diff --git a/src/page/Meeting/index.tsx b/src/page/Meeting/index.tsx index 1d19ec4..9a075bf 100644 --- a/src/page/Meeting/index.tsx +++ b/src/page/Meeting/index.tsx @@ -1207,8 +1207,11 @@ const Meeting: React.FC = () => { // 退出房间 const leaveChannel = async (bool: boolean = true): Promise => { await stopRecorderMedia() - if (bool) { - await getLeave() + try { + if (bool) { + await getLeave() + } + } catch (error) { } await agora.leaveChannel() if (user.isAnonymous) { diff --git a/src/utils/package/signalr.ts b/src/utils/package/signalr.ts index 0f7dd9d..0d0652b 100644 --- a/src/utils/package/signalr.ts +++ b/src/utils/package/signalr.ts @@ -22,15 +22,12 @@ export const startSignalr = async () => { }); } -export const onStart = async (callBack?: Function) => { - if (connection.state !== signalR.HubConnectionState.Connected) { - try { - await connection.start(); - if (callBack) { - callBack() - } - } catch (err) { - setTimeout(onStart, 5000); +export const onStart = async () => { + if (connection) { + if (connection.state !== signalR.HubConnectionState.Connected) { + connection.start(); + } else { + setTimeout(onStart, 3000); } } } diff --git a/src/utils/styles/App.scss b/src/utils/styles/App.scss index f14107f..eeef848 100644 --- a/src/utils/styles/App.scss +++ b/src/utils/styles/App.scss @@ -381,7 +381,11 @@ $pagination-hover-background-color: #5575F2; .ant-message { -webkit-app-region: no-drag; } - +// ant-spin-fullscreen .ant-spin-fullscreen { z-index: 10000; +} + +.ant-picker-dropdown { + -webkit-app-region: no-drag; } \ No newline at end of file From 088b4e01aa730e605bb1349d39a2a27726ba234b Mon Sep 17 00:00:00 2001 From: youngq Date: Fri, 27 Sep 2024 15:35:48 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=BF=AB=E9=80=9F?= =?UTF-8?q?=E9=80=80=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/page/Meeting/index.tsx | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/page/Meeting/index.tsx b/src/page/Meeting/index.tsx index dd3dfe0..8371a81 100644 --- a/src/page/Meeting/index.tsx +++ b/src/page/Meeting/index.tsx @@ -998,11 +998,13 @@ const Meeting: React.FC = () => { } // 全员观看 const getShowUser = async (): Promise => { - await GetShowUser(state.channelId).then(async (res) => { - if (res.code === 200 && res.data) { - renderVideo(res.data) - } - }) + if (location.href.indexOf('/meeting') !== -1) { + await GetShowUser(state.channelId).then(async (res) => { + if (res.code === 200 && res.data) { + renderVideo(res.data) + } + }) + } } // 加入房间时间 const changeCurrentSeconds = (): string => {