You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
857 B
JavaScript
36 lines
857 B
JavaScript
import useAuthStore from '@/stores/AuthStore'
|
|
import useConversationStore from '@/stores/ConversationStore'
|
|
import { Flex, Result, Spin, Typography } from 'antd'
|
|
import { useEffect } from 'react'
|
|
import { useNavigate } from 'react-router-dom'
|
|
|
|
|
|
function Logout() {
|
|
|
|
const navigate = useNavigate()
|
|
|
|
const logout = useAuthStore(state => state.logout)
|
|
const reset = useConversationStore((state) => state.reset);
|
|
|
|
useEffect(() => {
|
|
logout()
|
|
reset();
|
|
navigate('/p/dingding/qrcode')
|
|
}, [])
|
|
|
|
return (
|
|
<Flex justify='center' align='center' gap='middle' vertical>
|
|
<Result
|
|
status='success'
|
|
title='退出成功'
|
|
subTitle='正在跳转登陆页面'
|
|
extra={[
|
|
<Spin size='small' />
|
|
]}
|
|
/>
|
|
</Flex>
|
|
)
|
|
}
|
|
|
|
export default Logout
|