This commit is contained in:
yj 2024-08-13 17:54:23 +08:00
parent 810c68bc96
commit d771aff700
1 changed files with 19 additions and 17 deletions

View File

@ -111,23 +111,25 @@ const App: React.FC = () => {
}, []) }, [])
useEffect(() => { useEffect(() => {
onOtherSignalr(async (item: any) => { setTimeout(() => {
switch (item.key) { onOtherSignalr(async (item: any) => {
case 'Invitation': switch (item.key) {
window.electron.joinNotification({ case 'Invitation':
body: item.roomName, window.electron.joinNotification({
name: item.InviterName, body: item.roomName,
}) name: item.InviterName,
joinMeetingModalRef.current.changeModal(item) })
break; joinMeetingModalRef.current.changeModal(item)
case 'ForceLogout': break;
message.error(item.message) case 'ForceLogout':
await leaveChannel(true) message.error(item.message)
toSrc('/login') await leaveChannel(true)
break; toSrc('/login')
} break;
}) }
}, [navigate]) })
}, 3000);
}, [])
useEffect(() => { useEffect(() => {
try { try {