feat: add data_date to project summary response
Include the schedule data date (last_recalc_date from XER) in the get_project_summary tool response. This shows when the schedule was last calculated in P6. Changes: - Add last_recalc_date column to projects table schema - Parse last_recalc_date in PROJECT table handler - Include last_recalc_date in db loader - Return data_date field in get_project_summary query - Update contract test to verify data_date presence
This commit is contained in:
@@ -290,7 +290,7 @@ def get_project_summary(project_id: str) -> dict | None:
|
||||
with db.cursor() as cur:
|
||||
cur.execute(
|
||||
"""
|
||||
SELECT proj_id, proj_short_name, plan_start_date, plan_end_date
|
||||
SELECT proj_id, proj_short_name, plan_start_date, plan_end_date, last_recalc_date
|
||||
FROM projects
|
||||
WHERE proj_id = ?
|
||||
""",
|
||||
@@ -319,6 +319,7 @@ def get_project_summary(project_id: str) -> dict | None:
|
||||
return {
|
||||
"project_id": project_row[0],
|
||||
"project_name": project_row[1],
|
||||
"data_date": project_row[4],
|
||||
"plan_start_date": project_row[2],
|
||||
"plan_end_date": project_row[3],
|
||||
"activity_count": activity_count,
|
||||
|
||||
Reference in New Issue
Block a user