fix: regenerate OpenAPI types, fix search scoping by applicationId
All checks were successful
CI / cleanup-branch (push) Has been skipped
CI / build (push) Successful in 1m10s
CI / docker (push) Successful in 59s
CI / deploy-feature (push) Has been skipped
CI / deploy (push) Successful in 40s

The identity rename (application→applicationId) broke search filtering
because the stale schema.d.ts still had 'application' as the field name.
The backend silently ignored the unknown field, returning unfiltered results.

- Regenerate openapi.json and schema.d.ts from live backend
- Fix Dashboard: application→applicationId in search request
- Fix RouteDetail: application→applicationId in search request (2 places)
- LayoutShell: scope command palette search by appId/routeId
- LayoutShell: pass sidebarReveal state on sidebar click navigation

Note for DS team: the Sidebar selectedPath logic (line 5451 in dist)
has a hardcoded pathname.startsWith("/exchanges/") guard. This should
be broadened to simply `S ? S : $.pathname` so sidebarReveal works on
all tabs (dashboard, runtime), not just exchanges.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
hsiegeln
2026-04-01 20:55:19 +02:00
parent 178bc40706
commit e26266532a
5 changed files with 526 additions and 430 deletions

File diff suppressed because one or more lines are too long

927
ui/src/api/schema.d.ts vendored

File diff suppressed because it is too large Load Diff

View File

@@ -98,11 +98,17 @@ function LayoutContent() {
const { open: paletteOpen, setOpen: setPaletteOpen } = useCommandPalette();
const { scope, setTab } = useScope();
// Exchange full-text search via command palette
// Exchange full-text search via command palette (scoped to current sidebar selection)
const [paletteQuery, setPaletteQuery] = useState('');
const debouncedQuery = useDebouncedValue(paletteQuery, 300);
const { data: exchangeResults } = useSearchExecutions(
{ text: debouncedQuery || undefined, offset: 0, limit: 10 },
{
text: debouncedQuery || undefined,
applicationId: scope.appId || undefined,
routeId: scope.routeId || undefined,
offset: 0,
limit: 10,
},
false,
);
@@ -243,13 +249,16 @@ function LayoutContent() {
navigate(`${baseParts.join('/')}?text=${encodeURIComponent(query)}`);
}, [navigate, scope.appId, scope.routeId]);
// Translate Sidebar's internal paths to our URL structure
// Translate Sidebar's internal paths to our URL structure.
// Pass sidebarReveal state so the DS Sidebar can highlight the clicked entry.
const handleSidebarNavigate = useCallback((path: string) => {
const state = { sidebarReveal: path };
// /apps/:appId and /apps/:appId/:routeId → current tab
const appMatch = path.match(/^\/apps\/([^/]+)(?:\/(.+))?$/);
if (appMatch) {
const [, sAppId, sRouteId] = appMatch;
navigate(sRouteId ? `/${scope.tab}/${sAppId}/${sRouteId}` : `/${scope.tab}/${sAppId}`);
navigate(sRouteId ? `/${scope.tab}/${sAppId}/${sRouteId}` : `/${scope.tab}/${sAppId}`, { state });
return;
}
@@ -257,11 +266,11 @@ function LayoutContent() {
const agentMatch = path.match(/^\/agents\/([^/]+)(?:\/(.+))?$/);
if (agentMatch) {
const [, sAppId, sInstanceId] = agentMatch;
navigate(sInstanceId ? `/runtime/${sAppId}/${sInstanceId}` : `/runtime/${sAppId}`);
navigate(sInstanceId ? `/runtime/${sAppId}/${sInstanceId}` : `/runtime/${sAppId}`, { state });
return;
}
navigate(path);
navigate(path, { state });
}, [navigate, scope.tab]);
return (

View File

@@ -199,7 +199,7 @@ export default function Dashboard({ onExchangeSelect }: DashboardProps = {}) {
timeFrom,
timeTo,
routeId: routeId || undefined,
application: appId || undefined,
applicationId: appId || undefined,
status: statusParam,
text: textFilter,
sortField,

View File

@@ -309,7 +309,7 @@ export default function RouteDetail() {
timeFrom,
timeTo,
routeId: routeId || undefined,
application: appId || undefined,
applicationId: appId || undefined,
sortField: recentSortField,
sortDir: recentSortDir,
offset: 0,
@@ -319,7 +319,7 @@ export default function RouteDetail() {
timeFrom,
timeTo,
routeId: routeId || undefined,
application: appId || undefined,
applicationId: appId || undefined,
status: 'FAILED',
offset: 0,
limit: 200,