guide
This commit is contained in:
@@ -35,7 +35,11 @@ import { useBranchScope } from '../BranchScope';
|
||||
import { CataloguePanel } from '../CataloguePanel';
|
||||
import { ProductsPanel } from '../ProductsPanel';
|
||||
import { SetupReturnBar } from '@/features/onboarding/SetupReturnBar';
|
||||
import type { StepId } from '@/features/onboarding/onboardingState';
|
||||
import {
|
||||
PROGRESS_STEPS,
|
||||
STEP_LABEL,
|
||||
type StepId,
|
||||
} from '@/features/onboarding/onboardingState';
|
||||
import { useLocationProducts } from '@/queries/hooks';
|
||||
import { TablePager } from '@/components/TablePager';
|
||||
import { usePaged } from '@/components/usePaged';
|
||||
@@ -108,7 +112,16 @@ export function InventoryPage() {
|
||||
{/* Above the header, because it is about the errand rather than the page:
|
||||
it is the only thing on screen that knows setup is unfinished. */}
|
||||
{fromSetup ? (
|
||||
<SetupReturnBar step={fromSetup} productCount={(setupProducts.data ?? []).length} />
|
||||
<SetupReturnBar
|
||||
position={PROGRESS_STEPS.indexOf(fromSetup) + 1}
|
||||
total={PROGRESS_STEPS.length}
|
||||
stepLabel={STEP_LABEL[fromSetup]}
|
||||
isDone={(setupProducts.data ?? []).length > 0}
|
||||
doneTitle={`${(setupProducts.data ?? []).length} product${
|
||||
(setupProducts.data ?? []).length === 1 ? '' : 's'
|
||||
} added`}
|
||||
href={`/admin/onboarding?advance=${fromSetup}`}
|
||||
/>
|
||||
) : null}
|
||||
|
||||
<PageHeader
|
||||
|
||||
Reference in New Issue
Block a user