|
|
|
@ -1,6 +1,6 @@
|
|
|
|
|
import { Outlet, Link, useHref, useNavigate, NavLink } from 'react-router-dom'
|
|
|
|
|
import { useEffect, useState } from 'react'
|
|
|
|
|
import { Layout, Menu, ConfigProvider, theme, Dropdown, FloatButton, Space, Row, Col, Badge, App as AntApp } from 'antd'
|
|
|
|
|
import { Layout, Menu, ConfigProvider, theme, Dropdown, message, FloatButton, Space, Row, Col, Badge, App as AntApp } from 'antd'
|
|
|
|
|
import { DownOutlined } from '@ant-design/icons'
|
|
|
|
|
import 'antd/dist/reset.css'
|
|
|
|
|
import AppLogo from '@/assets/logo-gh.png'
|
|
|
|
@ -34,7 +34,7 @@ function App() {
|
|
|
|
|
|
|
|
|
|
const { loginToken } = usingStorage()
|
|
|
|
|
|
|
|
|
|
const { message, notification } = AntApp.useApp()
|
|
|
|
|
const [messageApi, contextHolder] = message.useMessage()
|
|
|
|
|
|
|
|
|
|
const noticeUnRead = useNoticeStore((state) => state.noticeUnRead)
|
|
|
|
|
const href = useHref()
|
|
|
|
@ -65,9 +65,9 @@ function App() {
|
|
|
|
|
const uploadLog = () => {
|
|
|
|
|
if (window.$pageSpy) {
|
|
|
|
|
window.$pageSpy.triggerPlugins('onOfflineLog', 'upload')
|
|
|
|
|
alert('Success.')
|
|
|
|
|
messageApi.info('Success')
|
|
|
|
|
} else {
|
|
|
|
|
alert('Failure.')
|
|
|
|
|
messageApi.error('Failure')
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -83,6 +83,7 @@ function App() {
|
|
|
|
|
}}>
|
|
|
|
|
<AntApp>
|
|
|
|
|
<FloatButton icon={<BugOutlined />} onClick={() => uploadLog()} />
|
|
|
|
|
{contextHolder}
|
|
|
|
|
<ErrorBoundary>
|
|
|
|
|
<Layout className='min-h-screen'>
|
|
|
|
|
<Header className='sticky top-0 z-10 w-full'>
|
|
|
|
|