feat: 经理看板按归属日期汇总
This commit is contained in:
@@ -10,6 +10,7 @@ from app.models import (
|
||||
Personnel,
|
||||
Product,
|
||||
ProductionReport,
|
||||
ProductionReportAllocation,
|
||||
ProductionReportItem,
|
||||
ReportStatus,
|
||||
SessionStatus,
|
||||
@@ -92,7 +93,24 @@ def test_dashboard_rows_populate_source_report_dates_from_original_reports():
|
||||
scrap_qty=0,
|
||||
allocated_minutes=60,
|
||||
)
|
||||
db.add_all([session, report, item])
|
||||
allocation = ProductionReportAllocation(
|
||||
id=index,
|
||||
report_id=report.id,
|
||||
report_item_id=item.id,
|
||||
attendance_point_name=point_name,
|
||||
employee_phone=person.phone,
|
||||
allocation_date=report_date,
|
||||
day_minutes=60,
|
||||
overtime_minutes=0,
|
||||
night_minutes=0,
|
||||
effective_minutes=60,
|
||||
good_qty=10,
|
||||
defect_qty=0,
|
||||
scrap_qty=0,
|
||||
changeover_count=0,
|
||||
reference_wage=20,
|
||||
)
|
||||
db.add_all([session, report, item, allocation])
|
||||
db.commit()
|
||||
|
||||
rows = _dashboard_rows(db, report_date, report_date)
|
||||
|
||||
Reference in New Issue
Block a user