152 lines
5.7 KiB
HTML
152 lines
5.7 KiB
HTML
<!doctype html>
|
|
<html lang="zh-CN">
|
|
<head>
|
|
<meta charset="UTF-8" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
<title>{{ app_name }} · 超级管理后台</title>
|
|
<link rel="stylesheet" href="/static/style.css?v=20260428z" />
|
|
</head>
|
|
<body>
|
|
<main class="app-shell">
|
|
<aside class="side-nav">
|
|
<div class="side-brand">{{ app_name }}</div>
|
|
<nav>
|
|
<a href="/">内容生产</a>
|
|
<a href="/settings">账号与模型</a>
|
|
<a href="/billing">账单中心</a>
|
|
<a href="/upgrade">升级订阅</a>
|
|
<a href="/profile">个人中心</a>
|
|
<a href="/guide">新手指引</a>
|
|
<a class="active" href="/admin?token={{ request.query_params.get('token','') }}">超级管理</a>
|
|
</nav>
|
|
</aside>
|
|
|
|
<section class="main-wrap">
|
|
<header class="topbar topbar-compact">
|
|
<h1>超级管理后台</h1>
|
|
<span class="global-mode-hint mode-badge">平台模型与数据库管理</span>
|
|
</header>
|
|
|
|
<section class="panel-scroll">
|
|
<article class="settings-card">
|
|
<h3>用户注册总览</h3>
|
|
<div class="grid-2" style="margin-top: 12px;">
|
|
<label>
|
|
总用户数
|
|
<input id="adminTotalUsers" type="text" value="0" readonly />
|
|
</label>
|
|
<label>
|
|
当前有效用户
|
|
<input id="adminActiveUsers" type="text" value="0" readonly />
|
|
</label>
|
|
<label>
|
|
今日新增
|
|
<input id="adminTodayUsers" type="text" value="0" readonly />
|
|
</label>
|
|
<label>
|
|
已注销用户
|
|
<input id="adminDeletedUsers" type="text" value="0" readonly />
|
|
</label>
|
|
</div>
|
|
<div style="margin-top: 12px; display: flex; gap: 8px; flex-wrap: wrap;">
|
|
<button id="adminUserRefreshBtn" class="button secondary">刷新用户统计</button>
|
|
</div>
|
|
</article>
|
|
|
|
<article class="settings-card">
|
|
<h3>最近注册记录</h3>
|
|
<div class="billing-table-wrap" style="margin-top: 12px;">
|
|
<table class="billing-table">
|
|
<thead>
|
|
<tr>
|
|
<th>ID</th>
|
|
<th>用户名</th>
|
|
<th>注册时间</th>
|
|
<th>状态</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody id="adminRecentUsersRows">
|
|
<tr><td colspan="4" class="muted">暂无记录</td></tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</article>
|
|
|
|
<article class="settings-card">
|
|
<h3>平台模型配置</h3>
|
|
<div class="grid-2" style="margin-top: 12px;">
|
|
<label>
|
|
API Key
|
|
<input id="platformApiKey" type="password" placeholder="sk-..." />
|
|
</label>
|
|
<label>
|
|
Base URL
|
|
<input id="platformBaseUrl" type="text" placeholder="https://dashscope.aliyuncs.com/compatible-mode/v1" />
|
|
</label>
|
|
<label>
|
|
文本模型
|
|
<input id="platformTextModel" type="text" placeholder="qwen-plus" list="platformTextModelOptions" />
|
|
<datalist id="platformTextModelOptions"></datalist>
|
|
</label>
|
|
<label>
|
|
生图模型
|
|
<input id="platformImageModel" type="text" placeholder="wanx2.0-t2i-turbo" list="platformImageModelOptions" />
|
|
<datalist id="platformImageModelOptions"></datalist>
|
|
</label>
|
|
<label>
|
|
超时(秒)
|
|
<input id="platformTimeoutSec" type="number" min="5" max="600" value="120" />
|
|
</label>
|
|
<label>
|
|
最大输出 tokens
|
|
<input id="platformMaxOutputTokens" type="number" min="256" max="65535" value="8192" />
|
|
</label>
|
|
</div>
|
|
<div style="margin-top: 12px; display: flex; gap: 8px; flex-wrap: wrap;">
|
|
<button id="platformSaveBtn" class="button">保存平台模型配置</button>
|
|
<button id="platformReloadBtn" class="button secondary">重新加载</button>
|
|
</div>
|
|
</article>
|
|
|
|
<article class="settings-card">
|
|
<h3>数据库总览</h3>
|
|
<div class="grid-2" style="margin-top: 12px;">
|
|
<label>
|
|
选择数据表
|
|
<select id="adminTableSelect" class="ui-select"></select>
|
|
</label>
|
|
<label>
|
|
每页条数
|
|
<input id="adminLimit" type="number" min="1" max="500" value="100" />
|
|
</label>
|
|
</div>
|
|
<div style="margin-top: 12px; display: flex; gap: 8px; flex-wrap: wrap;">
|
|
<button id="adminPrevBtn" class="button secondary">上一页</button>
|
|
<button id="adminNextBtn" class="button secondary">下一页</button>
|
|
<button id="adminRefreshBtn" class="button">刷新</button>
|
|
</div>
|
|
<p id="adminStatus" class="muted" style="margin-top: 10px;">准备就绪</p>
|
|
</article>
|
|
|
|
<article class="settings-card">
|
|
<h3>表数据</h3>
|
|
<div class="billing-table-wrap" style="margin-top: 12px;">
|
|
<table class="billing-table" id="adminTableData">
|
|
<thead>
|
|
<tr id="adminHeadRow"><th>暂无数据</th></tr>
|
|
</thead>
|
|
<tbody id="adminBodyRows">
|
|
<tr><td class="muted">请选择一个表后加载数据</td></tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</article>
|
|
</section>
|
|
</section>
|
|
</main>
|
|
|
|
<script src="/static/ui-dialog.js?v=20260428p"></script>
|
|
<script src="/static/admin.js?v=20260428b"></script>
|
|
</body>
|
|
</html>
|