fix(AP0.8): UI-Sichtbarkeit Attention und OM-Sektionen verbessern
Deploy Development / deploy (push) Successful in 45s
Test Suite / pytest-backend (push) Successful in 57s
Test Suite / lint-backend (push) Successful in 2s
Test Suite / compose-smoke (push) Has been skipped
Test Suite / k6 /api/health Baseline (push) Successful in 18s
Test Suite / playwright-smoke (push) Successful in 12s
Deploy Development / deploy (push) Successful in 45s
Test Suite / pytest-backend (push) Successful in 57s
Test Suite / lint-backend (push) Successful in 2s
Test Suite / compose-smoke (push) Has been skipped
Test Suite / k6 /api/health Baseline (push) Successful in 18s
Test Suite / playwright-smoke (push) Successful in 12s
Attention-Widget an workspace.read koppeln, Vorhaben-Detail-Sektionen bei initiative.read anzeigen, App-Version im Kontext-Widget, Session-Loading-Race behoben. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
fe3bc4f057
commit
c9101db1e1
4 files changed
+29
-12
No files matched your search
@@ -41,7 +41,7 @@ import { useSession } from '../context/SessionContext.jsx'
|
||||
|
||||
export function InitiativeDetailPage() {
|
||||
const { id } = useParams()
|
||||
const { context } = useSession()
|
||||
const { context, loading: sessionLoading } = useSession()
|
||||
const { capabilities } = useCapabilities()
|
||||
const {
|
||||
actors,
|
||||
@@ -64,6 +64,7 @@ export function InitiativeDetailPage() {
|
||||
const [hideDone, setHideDone] = useState(true)
|
||||
|
||||
const load = useCallback(async () => {
|
||||
if (sessionLoading) return
|
||||
setLoading(true)
|
||||
setError(null)
|
||||
try {
|
||||
@@ -75,13 +76,12 @@ export function InitiativeDetailPage() {
|
||||
setActions(actionData)
|
||||
|
||||
const loads = []
|
||||
if (capabilities.has('kairo.blocker.read')) {
|
||||
const canReadOm =
|
||||
capabilities.has('kairo.initiative.read') ||
|
||||
capabilities.has('kairo.blocker.read')
|
||||
if (canReadOm) {
|
||||
loads.push(listInitiativeBlockers(id).then(setBlockers).catch(() => setBlockers([])))
|
||||
}
|
||||
if (capabilities.has('kairo.backlog.read')) {
|
||||
loads.push(listInitiativeBacklog(id).then(setBacklogItems).catch(() => setBacklogItems([])))
|
||||
}
|
||||
if (capabilities.has('kairo.milestone.read')) {
|
||||
loads.push(listInitiativeMilestones(id).then(setMilestones).catch(() => setMilestones([])))
|
||||
}
|
||||
await Promise.all(loads)
|
||||
@@ -90,7 +90,7 @@ export function InitiativeDetailPage() {
|
||||
} finally {
|
||||
setLoading(false)
|
||||
}
|
||||
}, [id, capabilities])
|
||||
}, [id, capabilities, sessionLoading])
|
||||
|
||||
useEffect(() => {
|
||||
load()
|
||||
@@ -405,7 +405,7 @@ export function InitiativeDetailPage() {
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
{capabilities.has('kairo.milestone.read') && (
|
||||
{capabilities.has('kairo.initiative.read') && (
|
||||
<MilestonesSection
|
||||
milestones={milestones}
|
||||
canManage={capabilities.has('kairo.milestone.manage')}
|
||||
@@ -416,7 +416,7 @@ export function InitiativeDetailPage() {
|
||||
/>
|
||||
)}
|
||||
|
||||
{capabilities.has('kairo.backlog.read') && (
|
||||
{capabilities.has('kairo.initiative.read') && (
|
||||
<BacklogSection
|
||||
items={backlogItems}
|
||||
canManage={capabilities.has('kairo.backlog.manage')}
|
||||
@@ -428,7 +428,7 @@ export function InitiativeDetailPage() {
|
||||
/>
|
||||
)}
|
||||
|
||||
{capabilities.has('kairo.blocker.read') && (
|
||||
{capabilities.has('kairo.initiative.read') && (
|
||||
<BlockersSection
|
||||
blockers={blockers}
|
||||
canManage={capabilities.has('kairo.blocker.manage')}
|
||||
|
||||
Reference in new issue
Block a user