feat: 管理界面新增数据浏览页(服务端分页)
- 新增「数据」页:按制式筛选、CGI/小区名称搜索、四种排序,每页 20/50/100 条,数据库端 LIMIT/OFFSET 分页,越界页自动回退到最后一页 - 点击行查看详情:基础字段与 1 公里内高干扰小区数的本期/上期分制式对比 - 首次打开该页才加载,新批次入库后自动刷新;加载中状态与过期请求丢弃,避免界面卡顿 - 新增 GET /api/data 接口(仅管理员),读取失败返回 502 - MySQL 直连与 Metrix 接口两种模式都支持只读查询,接口模式浏览查询超时 20 秒;两种模式数值格式统一 - 搜索词转义引号与 LIKE 通配符,制式、排序、页大小走白名单 - 补充单元测试与中英文文案
This commit is contained in:
@@ -193,6 +193,42 @@ body.body--dark {
|
||||
.etl-badge.tone-neutral { background: var(--etl-neutral-soft); }
|
||||
.etl-runs-footer { display: flex; justify-content: flex-end; padding: 10px 16px; border-top: 1px solid var(--etl-border); }
|
||||
|
||||
.etl-data-tools { flex-wrap: wrap; justify-content: flex-end; }
|
||||
.etl-data-search { width: 260px; }
|
||||
.etl-data-sort { width: 200px; }
|
||||
.etl-data-summary {
|
||||
padding: 10px 20px; font-size: 13px; color: var(--etl-muted); border-bottom: 1px solid var(--etl-border);
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
.etl-data-summary.tone-danger { color: var(--etl-danger); }
|
||||
.etl-data-table .q-table__middle { overflow-x: auto; }
|
||||
.etl-data-table tbody td { white-space: nowrap; }
|
||||
.etl-cell-name { max-width: 280px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
||||
.etl-net {
|
||||
display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 6px;
|
||||
font-size: 12px; font-weight: 600; white-space: nowrap; background: var(--etl-neutral-soft); color: var(--etl-text);
|
||||
}
|
||||
.etl-net.net-26g { background: rgba(37, 99, 235, 0.12); color: #2563eb; }
|
||||
.etl-net.net-700m { background: rgba(124, 58, 237, 0.12); color: #7c3aed; }
|
||||
.etl-net.net-tdd { background: rgba(13, 148, 136, 0.13); color: #0d9488; }
|
||||
.etl-net.net-fdd { background: rgba(217, 119, 6, 0.13); color: #b45309; }
|
||||
.body--dark .etl-net.net-26g { color: #7aa7ff; }
|
||||
.body--dark .etl-net.net-700m { color: #b69cff; }
|
||||
.body--dark .etl-net.net-tdd { color: #5eead4; }
|
||||
.body--dark .etl-net.net-fdd { color: #fbbf24; }
|
||||
.etl-data-footer { justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
|
||||
.etl-data-size { display: flex; align-items: center; gap: 8px; font-size: 13px; }
|
||||
.etl-page-size { width: 84px; }
|
||||
.etl-dialog.etl-data-dialog { width: min(760px, 94vw); }
|
||||
.etl-detail { width: 100%; padding: 6px 20px 20px; }
|
||||
.etl-detail-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 20px; padding: 12px 0 16px; }
|
||||
.etl-detail-grid .etl-meta-value { word-break: break-all; }
|
||||
.etl-detail-title { font-size: 13px; font-weight: 600; padding: 14px 0 10px; border-top: 1px solid var(--etl-border); }
|
||||
.etl-detail-matrix {
|
||||
display: grid; grid-template-columns: 72px repeat(5, minmax(0, 1fr)); gap: 10px 12px; align-items: center;
|
||||
padding: 12px 14px; border-radius: 8px; background: var(--etl-soft); font-variant-numeric: tabular-nums;
|
||||
}
|
||||
|
||||
.etl-dialog {
|
||||
width: min(960px, 94vw); max-width: none !important; padding: 0 !important; gap: 0 !important;
|
||||
border-radius: 12px !important; background: var(--etl-panel) !important; color: var(--etl-text);
|
||||
@@ -254,6 +290,8 @@ body.body--dark {
|
||||
.etl-cards { grid-template-columns: 1fr; }
|
||||
.etl-field { grid-template-columns: 1fr; gap: 8px; }
|
||||
.etl-dialog-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
.etl-detail-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
.etl-data-search, .etl-data-sort { width: 100%; }
|
||||
}
|
||||
</style>
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user