fix: 部门费用计算排除「暂不计入」状态

- t_expense_sum 和 expense_sum 新增状态过滤
- 首页部门费用指标不再累加 status='暂不计入' 的记录
- 版本号 v1.0.0.7
This commit is contained in:
mac
2026-07-07 18:44:10 +08:00
parent e7e93c06f8
commit 76da3a2106
2 changed files with 3 additions and 1 deletions

View File

@@ -331,6 +331,7 @@ def bootstrap():
def t_expense_sum(m_range):
total = 0
for r in t_expense:
if (r.get("status") or "") == "暂不计入": continue
m = (r.get("expense_month") or "").strip()
if not m or "-" not in m: continue
try:
@@ -459,6 +460,7 @@ def bootstrap():
def expense_sum(month_range):
total = 0
for r in expense:
if (r.get("status") or "") == "暂不计入": continue
m = (r.get("expense_month") or "").strip()
if not m or "-" not in m: continue
try: