feat(export/dashboard): 导出增强与大屏公开化
导出-每次考试/多考试对比: - 合格次数阈值等标记项抽为常显区块,三类成绩表共用 - 附缺考名单扩展到多考试导出(取所选考试全都没交的人) - 块表每场固定2列(成绩+合并空位),修复漏推空串导致的整行左移/串列 - 列宽按实际内容估算,合并区空位只给最小宽度 - 合格次数始终显示实际次数(含0),仅 ≥ 阈值标绿底 - 打印标题改为「成绩明细」,缺考名单分页单独成页 - 打印样式加 print-color-adjust:exact,绿底/红字可正常印出 数据大屏: - ?class= 班级大屏免登录公开访问,接口侧放行并按班级裁剪后回传 - 单班大屏移除退出按钮,仅首页保留 - 修复红绿判定真bug:membersTable 误用 window.DASH(DASH为let声明取不到) 改为 scoreGrade() 直接读自由变量,按后台合格率正确判红/黄/绿 测试/样例/文档同步更新,全量回归通过。
This commit is contained in:
+118
-1
@@ -431,7 +431,76 @@ table.grid tbody tr.new.clickable:hover td { background: #d6f2e2; }
|
||||
/* 弹窗内的表格不做吸顶:弹窗自身是滚动容器,吸顶表头会与内容错层(且贴边观感差) */
|
||||
.modal-body table.grid th { position: static; }
|
||||
.modal-body table.grid { box-shadow: inset 0 0 0 1px var(--border-2); border-radius: 8px; }
|
||||
/* 多考试对比导出:顶部工具条 */
|
||||
/* ================= 统一导出 / 打印弹窗 ================= */
|
||||
.ex-sec {
|
||||
padding: 12px 14px; margin: 0 0 12px;
|
||||
border: 1px solid var(--border); border-radius: 10px; background: #fbfcfe;
|
||||
}
|
||||
.ex-sec[hidden] { display: none; }
|
||||
.ex-sec-title {
|
||||
font-size: 12px; font-weight: 700; color: var(--text-2);
|
||||
letter-spacing: .3px; margin: 0 0 10px;
|
||||
display: flex; align-items: center; gap: 8px;
|
||||
}
|
||||
.ex-sec-title small { font-weight: 500; color: var(--text-3, #8b93a1); }
|
||||
|
||||
/* 导出内容:2×2 卡片单选,一眼看清四种导出各是什么 */
|
||||
.ex-types { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
|
||||
.ex-type {
|
||||
display: flex; align-items: flex-start; gap: 9px; padding: 10px 12px;
|
||||
border: 1px solid var(--border); border-radius: 9px; background: #fff;
|
||||
cursor: pointer; transition: border-color .15s, box-shadow .15s, background .15s;
|
||||
}
|
||||
.ex-type:hover { border-color: #b9c2d0; }
|
||||
.ex-type:has(input:checked) {
|
||||
border-color: var(--primary, #2f6fed); background: #f3f7ff;
|
||||
box-shadow: 0 0 0 1px var(--primary, #2f6fed) inset;
|
||||
}
|
||||
.ex-type input { margin-top: 3px; flex: none; }
|
||||
.ex-type-t { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
|
||||
.ex-type-t b { font-size: 13px; color: var(--text); }
|
||||
.ex-type-t small { font-size: 11.5px; color: var(--text-3, #8b93a1); line-height: 1.45; }
|
||||
|
||||
/* 字段行 */
|
||||
.ex-row { display: flex; flex-wrap: wrap; gap: 14px 18px; align-items: flex-start; }
|
||||
.ex-field {
|
||||
display: flex; flex-direction: column; gap: 6px; min-width: 150px;
|
||||
font-size: 12px; font-weight: 600; color: var(--text-2);
|
||||
}
|
||||
.ex-field select, .ex-field input[type=text], .ex-field input[type=number] {
|
||||
font-size: 13px; font-weight: 400; color: var(--text);
|
||||
}
|
||||
.ex-field-tip {
|
||||
min-width: 200px; flex: 1 1 240px; font-weight: 400;
|
||||
display: flex; flex-direction: column; gap: 4px; justify-content: flex-end;
|
||||
}
|
||||
.ex-field-grow { flex: 1 1 240px; }
|
||||
.ex-field-grow input { width: 100%; }
|
||||
|
||||
/* 班级 / 组别多选:竖排标签 + 列表,便于 Ctrl 多选 */
|
||||
#exClsSel, #exGrpSel {
|
||||
width: 168px; height: 96px; padding: 4px 6px; font-size: 12px;
|
||||
border: 1px solid var(--border); border-radius: 8px;
|
||||
background: #fff; color: var(--text); outline: none;
|
||||
}
|
||||
#exGrpSel { width: 132px; }
|
||||
|
||||
.ex-checks {
|
||||
display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 12px;
|
||||
font-size: 12.5px; color: var(--text);
|
||||
}
|
||||
.ex-checks label { display: flex; align-items: center; gap: 6px; cursor: pointer; }
|
||||
|
||||
/* 多考试:勾选列表 */
|
||||
.ex-pick { margin-top: 12px; }
|
||||
.ex-pick-head {
|
||||
display: flex; align-items: center; gap: 10px; margin: 0 0 8px;
|
||||
font-size: 12.5px; font-weight: 600; color: var(--text-2);
|
||||
}
|
||||
.ex-pick-head small { font-weight: 500; color: var(--text-3, #8b93a1); }
|
||||
.table-scroll.mid { max-height: 208px; overflow: auto; }
|
||||
|
||||
/* 合规的旧类名保留(其它地方仍在用 .me-bar 之类的排版习惯) */
|
||||
.me-bar { display: flex; align-items: center; gap: 16px; margin: 0 0 10px; }
|
||||
.me-bar .chk { margin: 0; white-space: nowrap; }
|
||||
.modal-foot {
|
||||
@@ -626,6 +695,51 @@ body.fs-on .topbar { padding-top: 8px; padding-bottom: 8px; }
|
||||
.dash-controls .inline { color: #fff; }
|
||||
.dash-controls .btn { background: rgba(255, 255, 255, .14); border-color: transparent; color: #fff; }
|
||||
.dash-controls .btn:hover { background: rgba(255, 255, 255, .24); }
|
||||
/* 单班大屏:顶栏只保留「试卷 / 自动刷新 / 全屏」,班级选择与「← 主系统」隐藏
|
||||
(退出按钮本形态下不再渲染,这里不再靠 CSS 藏) */
|
||||
body.dash-class #classSelWrap,
|
||||
body.dash-class #linkIndex { display: none !important; }
|
||||
/* 公开(免登录)班级大屏的角标 */
|
||||
.pub-tag {
|
||||
display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 12px;
|
||||
background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .38); color: #fff;
|
||||
}
|
||||
/* 首页汇总卡(5 卡)在该形态下无意义 */
|
||||
body.dash-home #boardSummary { display: none; }
|
||||
.dash-hero .brand-cls {
|
||||
display: inline-block; margin-left: 2px; padding: 2px 10px; border-radius: 999px;
|
||||
background: rgba(255, 255, 255, .18); font-size: 13px; font-weight: 600;
|
||||
}
|
||||
|
||||
/* ---------- 首页:班级入口卡片 ---------- */
|
||||
.cls-grid {
|
||||
display: grid; grid-template-columns: repeat(auto-fill, minmax(248px, 1fr));
|
||||
gap: 14px; margin-top: 12px;
|
||||
}
|
||||
.cls-card {
|
||||
min-width: 0; cursor: pointer; user-select: none;
|
||||
background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius);
|
||||
padding: 14px 16px 12px; box-shadow: var(--shadow);
|
||||
transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
|
||||
}
|
||||
.cls-card:hover { transform: translateY(-3px); border-color: var(--primary); box-shadow: var(--shadow-lg); }
|
||||
.cls-card:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
|
||||
.cls-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
|
||||
.cls-name { font-size: 16px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
||||
.cls-go { flex: none; font-size: 12px; font-weight: 700; color: var(--primary); }
|
||||
.cls-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px 8px; margin-top: 10px; }
|
||||
.cls-kpi { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
|
||||
.cls-kpi span { font-size: 11px; color: var(--text-3); }
|
||||
.cls-kpi b { font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
|
||||
.cls-kpi.k-ok b { color: var(--ok); }
|
||||
.cls-kpi.k-warn b { color: var(--warn); }
|
||||
.cls-bar { height: 8px; border-radius: 999px; background: var(--border-2); overflow: hidden; margin-top: 12px; }
|
||||
.cls-bar > i { display: block; height: 100%; border-radius: 999px; transition: width .5s ease; }
|
||||
.cls-sub {
|
||||
margin-top: 7px; font-size: 11.5px; color: var(--text-3);
|
||||
display: flex; justify-content: space-between; gap: 8px;
|
||||
}
|
||||
@media (max-width: 860px) { .cls-grid { grid-template-columns: 1fr; } }
|
||||
|
||||
.sec-title { margin: 22px 0 4px; font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
|
||||
.sec-title .tag-gray { background: var(--border-2); color: var(--text-3); padding: 1px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; }
|
||||
@@ -692,6 +806,9 @@ body.dash.fs-on .card b { font-size: 20px; }
|
||||
body.dash.fs-on .group-compare { gap: 12px; }
|
||||
body.dash.fs-on .gpanel { padding: 12px 14px; }
|
||||
body.dash.fs-on .member-list { max-height: none; }
|
||||
body.dash.fs-on .cls-grid { grid-template-columns: repeat(auto-fill, minmax(212px, 1fr)); gap: 10px; }
|
||||
body.dash.fs-on .cls-card { padding: 10px 12px; }
|
||||
body.dash.fs-on .cls-kpi b { font-size: 15px; }
|
||||
|
||||
|
||||
/* ================= 随机抽取页 ================= */
|
||||
|
||||
Reference in New Issue
Block a user