Add reports to command bar (#7002)

* Add reports to command bar

* Add release notes
This commit is contained in:
Roy
2026-02-17 21:03:44 +01:00
committed by GitHub
parent c7efb61b84
commit d3f2f1f7ae
2 changed files with 17 additions and 0 deletions

View File

@@ -25,6 +25,7 @@ import { Command } from 'cmdk';
import { CellValue, CellValueText } from './spreadsheet/CellValue';
import { useAccounts } from '@desktop-client/hooks/useAccounts';
import { useDashboardPages } from '@desktop-client/hooks/useDashboardPages';
import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref';
import { useModalState } from '@desktop-client/hooks/useModalState';
import { useNavigate } from '@desktop-client/hooks/useNavigate';
@@ -143,6 +144,7 @@ export function CommandBar() {
const allAccounts = useAccounts();
const { data: customReports = [] } = useReports();
const { data: dashboardPages = [] } = useDashboardPages();
const accounts = allAccounts.filter(acc => !acc.closed);
@@ -220,6 +222,15 @@ export function CommandBar() {
],
onSelect: ({ id }) => handleNavigate(`/accounts/${id}`),
},
{
key: 'reports',
heading: t('Reports'),
items: dashboardPages.map(dashboardPage => ({
...dashboardPage,
Icon: SvgReports,
})),
onSelect: ({ id }) => handleNavigate(`/reports/${id}`),
},
{
key: 'reports-custom',
heading: t('Custom Reports'),

View File

@@ -0,0 +1,6 @@
---
category: Enhancements
authors: [bonroyage]
---
Add reports to command bar