main
mula.liu 2026-11-23 09:34:17 +08:00
parent a907d362fc
commit 3f81b6f377
2 changed files with 8 additions and 5 deletions

View File

@ -218,11 +218,13 @@ def _finance_table(data: dict) -> str:
_esc(item.get("sign_count", 0)), _wan(item.get("sign_amount")),
target, rate_text,
], cls))
body.append(row([
"未分季", _esc(unscheduled.get("acc_count", 0)), _wan(unscheduled.get("acc_amount")),
_esc(unscheduled.get("sign_count", 0)), _wan(unscheduled.get("sign_amount")),
"—", "—",
]))
if (int(unscheduled.get("acc_count") or 0) > 0
or int(unscheduled.get("sign_count") or 0) > 0):
body.append(row([
"未分季", _esc(unscheduled.get("acc_count", 0)), _wan(unscheduled.get("acc_amount")),
_esc(unscheduled.get("sign_count", 0)), _wan(unscheduled.get("sign_amount")),
"—", "—",
]))
body.append(row([
"<strong>合计</strong>", f"<strong>{_esc(total.get('acc_count', 0))}</strong>",
f"<strong>{_wan(total.get('acc_amount'))}</strong>",

View File

@ -51,6 +51,7 @@ def test_看板导出完整工作汇报页(h):
assert "高风险戊" not in body
assert "本期没有重点工作" not in body
assert "2028 Q1" in body
assert "未分季" not in body
assert "35.00" in body and "225.00" in body and "160.00" in body and "260.00" in body
assert "历史遗留任务" not in body
assert body.index("自研乙") < body.index("方案评审通过") < body.index("自研甲") < body.index("联调完成")