mirror of
https://github.com/router-for-me/Cli-Proxy-API-Management-Center.git
synced 2026-06-16 21:03:58 +08:00
feat(logs): enhance logging functionality and UI updates
- Refactored MainLayout to always show logs in the sidebar. - Updated i18n files for English, Russian, Simplified Chinese, and Traditional Chinese to include new log-related messages. - Improved LogsPage styling for better layout and added runtime notices. - Enhanced LogsPage logic to handle different server runtime kinds (CPA and Home). - Added new API methods to handle logs fetching and request log downloading with runtime checks. - Introduced runtime kind detection during authentication and connection status updates. - Updated types to include server runtime kind and adjusted API responses accordingly.
This commit is contained in:
@@ -213,7 +213,6 @@ export function MainLayout() {
|
||||
|
||||
const logout = useAuthStore((state) => state.logout);
|
||||
|
||||
const config = useConfigStore((state) => state.config);
|
||||
const fetchConfig = useConfigStore((state) => state.fetchConfig);
|
||||
const clearCache = useConfigStore((state) => state.clearCache);
|
||||
|
||||
@@ -431,16 +430,12 @@ export function MainLayout() {
|
||||
metaKey: 'nav_meta.quota_management',
|
||||
icon: sidebarIcons.quota,
|
||||
},
|
||||
...(config?.loggingToFile
|
||||
? [
|
||||
{
|
||||
path: '/logs',
|
||||
labelKey: 'nav.logs',
|
||||
metaKey: 'nav_meta.logs',
|
||||
icon: sidebarIcons.logs,
|
||||
},
|
||||
]
|
||||
: []),
|
||||
{
|
||||
path: '/logs',
|
||||
labelKey: 'nav.logs',
|
||||
metaKey: 'nav_meta.logs',
|
||||
icon: sidebarIcons.logs,
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user