项目整理:添加Cookie Cloud下载功能、优化前端界面、配置改为config.json、打包脚本、清理无用文件
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
<el-container>
|
||||
<el-header>
|
||||
<div class="header-left">
|
||||
<h1>Cookie监控管理系统</h1>
|
||||
<h1>网站监控仪表板</h1>
|
||||
<el-button v-if="activeTab === 'settings'" @click="activeTab = 'dashboard'" type="primary" plain>返回监控首页</el-button>
|
||||
</div>
|
||||
<div class="header-right">
|
||||
@@ -24,8 +24,17 @@
|
||||
<el-icon class="rotating-icon"><Refresh /></el-icon>
|
||||
<span class="refresh-text">{{ countdown }}秒后自动刷新</span>
|
||||
</div>
|
||||
<el-button v-if="activeTab === 'dashboard'" @click="loadDashboard" type="primary" plain>刷新</el-button>
|
||||
<el-button @click="showAdminLogin" type="warning" plain v-if="!isAdmin">登录后台</el-button>
|
||||
<span class="header-stat" v-if="activeTab === 'dashboard'">网站总数:<b>{{ stats.totalWebsites }}</b></span>
|
||||
<el-dropdown @command="handleDropdownCommand" v-if="!isAdmin">
|
||||
<el-button link type="text" style="color: rgba(255,255,255,0.8); font-size: 18px">
|
||||
<el-icon><arrow-down /></el-icon>
|
||||
</el-button>
|
||||
<template #dropdown>
|
||||
<el-dropdown-menu>
|
||||
<el-dropdown-item command="login"><el-icon><Lock /></el-icon> 登录后台</el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
</template>
|
||||
</el-dropdown>
|
||||
<el-dropdown @command="handleAdminCommand" v-else>
|
||||
<el-button type="success" plain>后台管理 <el-icon><arrow-down /></el-icon></el-button>
|
||||
<template #dropdown>
|
||||
@@ -42,19 +51,6 @@
|
||||
<el-main>
|
||||
<!-- 监控仪表板 -->
|
||||
<div v-if="activeTab === 'dashboard'">
|
||||
<div class="dashboard-header">
|
||||
<h2>网站监控仪表板</h2>
|
||||
<div class="dashboard-stats">
|
||||
<el-statistic title="网站总数" :value="stats.totalWebsites" />
|
||||
<el-statistic title="在线" :value="stats.onlineCount">
|
||||
<template #suffix><el-icon><circle-check /></el-icon></template>
|
||||
</el-statistic>
|
||||
<el-statistic title="离线" :value="stats.offlineCount">
|
||||
<template #suffix><el-icon><circle-close /></el-icon></template>
|
||||
</el-statistic>
|
||||
<el-statistic title="未检测" :value="stats.unknownCount" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-for="user in dashboardData" :key="user.id" class="user-section">
|
||||
<div class="user-header">
|
||||
@@ -65,6 +61,13 @@
|
||||
</div>
|
||||
|
||||
<el-table :data="user.websites" style="width: 100%; margin-bottom: 20px">
|
||||
<el-table-column label="启用状态" width="90">
|
||||
<template #default="scope">
|
||||
<el-tag :type="scope.row.status === 1 ? 'success' : 'danger'" size="small">
|
||||
{{ scope.row.status === 1 ? '启用' : '禁用' }}
|
||||
</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="name" label="网站名称" width="150"></el-table-column>
|
||||
<el-table-column prop="url" label="URL" width="250">
|
||||
<template #default="scope">
|
||||
@@ -98,6 +101,10 @@
|
||||
</div>
|
||||
|
||||
<el-empty v-if="dashboardData.length === 0" description="暂无网站数据"></el-empty>
|
||||
|
||||
<div class="dashboard-footer">
|
||||
<p>免责声明:本系统仅用于Cookie状态监控和自动化管理,不对任何网站数据承担责任。请确保您有权访问和管理相关网站账号。</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 网站管理 -->
|
||||
|
||||
Reference in New Issue
Block a user