fix: regenerate OpenAPI types, fix search scoping by applicationId
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:
File diff suppressed because one or more lines are too long
927
ui/src/api/schema.d.ts
vendored
927
ui/src/api/schema.d.ts
vendored
File diff suppressed because it is too large
Load Diff
@@ -98,11 +98,17 @@ function LayoutContent() {
|
|||||||
const { open: paletteOpen, setOpen: setPaletteOpen } = useCommandPalette();
|
const { open: paletteOpen, setOpen: setPaletteOpen } = useCommandPalette();
|
||||||
const { scope, setTab } = useScope();
|
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 [paletteQuery, setPaletteQuery] = useState('');
|
||||||
const debouncedQuery = useDebouncedValue(paletteQuery, 300);
|
const debouncedQuery = useDebouncedValue(paletteQuery, 300);
|
||||||
const { data: exchangeResults } = useSearchExecutions(
|
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,
|
false,
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -243,13 +249,16 @@ function LayoutContent() {
|
|||||||
navigate(`${baseParts.join('/')}?text=${encodeURIComponent(query)}`);
|
navigate(`${baseParts.join('/')}?text=${encodeURIComponent(query)}`);
|
||||||
}, [navigate, scope.appId, scope.routeId]);
|
}, [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 handleSidebarNavigate = useCallback((path: string) => {
|
||||||
|
const state = { sidebarReveal: path };
|
||||||
|
|
||||||
// /apps/:appId and /apps/:appId/:routeId → current tab
|
// /apps/:appId and /apps/:appId/:routeId → current tab
|
||||||
const appMatch = path.match(/^\/apps\/([^/]+)(?:\/(.+))?$/);
|
const appMatch = path.match(/^\/apps\/([^/]+)(?:\/(.+))?$/);
|
||||||
if (appMatch) {
|
if (appMatch) {
|
||||||
const [, sAppId, sRouteId] = 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;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -257,11 +266,11 @@ function LayoutContent() {
|
|||||||
const agentMatch = path.match(/^\/agents\/([^/]+)(?:\/(.+))?$/);
|
const agentMatch = path.match(/^\/agents\/([^/]+)(?:\/(.+))?$/);
|
||||||
if (agentMatch) {
|
if (agentMatch) {
|
||||||
const [, sAppId, sInstanceId] = agentMatch;
|
const [, sAppId, sInstanceId] = agentMatch;
|
||||||
navigate(sInstanceId ? `/runtime/${sAppId}/${sInstanceId}` : `/runtime/${sAppId}`);
|
navigate(sInstanceId ? `/runtime/${sAppId}/${sInstanceId}` : `/runtime/${sAppId}`, { state });
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
navigate(path);
|
navigate(path, { state });
|
||||||
}, [navigate, scope.tab]);
|
}, [navigate, scope.tab]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@@ -199,7 +199,7 @@ export default function Dashboard({ onExchangeSelect }: DashboardProps = {}) {
|
|||||||
timeFrom,
|
timeFrom,
|
||||||
timeTo,
|
timeTo,
|
||||||
routeId: routeId || undefined,
|
routeId: routeId || undefined,
|
||||||
application: appId || undefined,
|
applicationId: appId || undefined,
|
||||||
status: statusParam,
|
status: statusParam,
|
||||||
text: textFilter,
|
text: textFilter,
|
||||||
sortField,
|
sortField,
|
||||||
|
|||||||
@@ -309,7 +309,7 @@ export default function RouteDetail() {
|
|||||||
timeFrom,
|
timeFrom,
|
||||||
timeTo,
|
timeTo,
|
||||||
routeId: routeId || undefined,
|
routeId: routeId || undefined,
|
||||||
application: appId || undefined,
|
applicationId: appId || undefined,
|
||||||
sortField: recentSortField,
|
sortField: recentSortField,
|
||||||
sortDir: recentSortDir,
|
sortDir: recentSortDir,
|
||||||
offset: 0,
|
offset: 0,
|
||||||
@@ -319,7 +319,7 @@ export default function RouteDetail() {
|
|||||||
timeFrom,
|
timeFrom,
|
||||||
timeTo,
|
timeTo,
|
||||||
routeId: routeId || undefined,
|
routeId: routeId || undefined,
|
||||||
application: appId || undefined,
|
applicationId: appId || undefined,
|
||||||
status: 'FAILED',
|
status: 'FAILED',
|
||||||
offset: 0,
|
offset: 0,
|
||||||
limit: 200,
|
limit: 200,
|
||||||
|
|||||||
Reference in New Issue
Block a user