修复了测试工单统计的错误

main
risingLee 2025-12-30 15:52:51 +08:00
parent 4f5540b814
commit 44522f2572
1 changed files with 2 additions and 2 deletions

View File

@ -59,10 +59,10 @@ class StatisticsService:
total_work_orders = len(all_work_orders)
# 统计已完成测试工单数量假设状态值2表示已完成
completed_work_orders = len([work_order for work_order in all_work_orders if work_order['test_status'] == 2])
completed_work_orders = len([work_order for work_order in all_work_orders if work_order.test_status == 2])
# 统计进行中测试工单数量假设状态值1表示进行中
processing_work_orders = len([work_order for work_order in all_work_orders if work_order['test_status'] == 1])
processing_work_orders = len([work_order for work_order in all_work_orders if work_order.test_status == 1])
return {
'totalWorkOrders': total_work_orders,