feat(steering): Epic Roll-up Read Model und Attention (ADP P4)
Test Suite / pytest-backend (push) Waiting to run
Test Suite / lint-backend (push) Waiting to run
Test Suite / compose-smoke (push) Waiting to run
Test Suite / k6 /api/health Baseline (push) Blocked by required conditions
Test Suite / playwright-smoke (push) Blocked by required conditions
Deploy Development / deploy (push) Has been cancelled
Test Suite / pytest-backend (push) Waiting to run
Test Suite / lint-backend (push) Waiting to run
Test Suite / compose-smoke (push) Waiting to run
Test Suite / k6 /api/health Baseline (push) Blocked by required conditions
Test Suite / playwright-smoke (push) Blocked by required conditions
Deploy Development / deploy (push) Has been cancelled
Schliesst den Backlog/Epic-Track mit kernel-basiertem Fortschritt pro Epic, Steuerungs-Attention und UI-Fortschrittsanzeige im Plan-Eingang ab. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
a13913f1a0
commit
ef5ee0d19b
13 files changed
+708
-5
No files matched your search
@@ -125,7 +125,8 @@ def get_initiative_steering_snapshot(
|
||||
|
||||
cur.execute(
|
||||
"""
|
||||
SELECT id, title, status, priority, converted_action_id, created_at, updated_at
|
||||
SELECT id, title, status, priority, converted_action_id, item_kind,
|
||||
parent_backlog_id, created_at, updated_at
|
||||
FROM backlog_items
|
||||
WHERE tenant_id = %s AND initiative_id = %s
|
||||
ORDER BY updated_at DESC
|
||||
@@ -297,6 +298,31 @@ def get_initiative_steering_snapshot(
|
||||
next_actions = evaluation.next_work
|
||||
kernel_attention = evaluation.attention
|
||||
|
||||
from services.operating_context import get_operating_context
|
||||
from steering.read_models.epic_rollup import compute_epic_rollup
|
||||
|
||||
operating = get_operating_context(
|
||||
tenant_id=ctx.tenant_id, initiative_id=initiative_id
|
||||
)
|
||||
epic_rollup: list[dict[str, Any]] = []
|
||||
if operating.get("backlog_vocabulary", {}).get("capabilities", {}).get(
|
||||
"epic_hierarchy"
|
||||
):
|
||||
epic_rollup = compute_epic_rollup(
|
||||
backlog_items=[
|
||||
{
|
||||
"id": _sid(b["id"]),
|
||||
"title": b["title"],
|
||||
"status": b["status"],
|
||||
"item_kind": b.get("item_kind"),
|
||||
"parent_backlog_id": _sid(b.get("parent_backlog_id")),
|
||||
"converted_action_id": _sid(b.get("converted_action_id")),
|
||||
}
|
||||
for b in backlog
|
||||
],
|
||||
actions=actions_raw,
|
||||
)
|
||||
|
||||
steering = get_steering_context_dto(ctx, initiative_id=initiative_id)
|
||||
metadata = steering.get("lifecycle_metadata") or {}
|
||||
if isinstance(metadata, str):
|
||||
@@ -355,6 +381,7 @@ def get_initiative_steering_snapshot(
|
||||
"upcoming_roadmap_items": upcoming_milestones,
|
||||
"next_actions": next_actions,
|
||||
"active_work_cycle": active_work_cycle,
|
||||
"epic_rollup": epic_rollup,
|
||||
"counts": {
|
||||
"actions_open": open_actions,
|
||||
"actions_blocked": blocked_actions,
|
||||
@@ -384,6 +411,8 @@ def get_initiative_steering_snapshot(
|
||||
"id": _sid(b["id"]),
|
||||
"title": b["title"],
|
||||
"status": b["status"],
|
||||
"item_kind": b.get("item_kind"),
|
||||
"parent_backlog_id": _sid(b.get("parent_backlog_id")),
|
||||
"converted_action_id": _sid(b.get("converted_action_id")),
|
||||
}
|
||||
for b in backlog
|
||||
|
||||
Reference in new issue
Block a user