add certs page
This commit is contained in:
@@ -76,73 +76,71 @@ export default function Route({
|
||||
const search = searchParams.get('s') as string
|
||||
|
||||
return (
|
||||
<>
|
||||
<Suspense fallback={<Skeleton />}>
|
||||
<div className="space-y-0.5 mb-8">
|
||||
<h1 className="text-2xl font-bold tracking-tight">
|
||||
Resumo de cobranças
|
||||
</h1>
|
||||
<p className="text-muted-foreground">
|
||||
Acompanhe as cobranças em tempo real e garanta mais eficiência no
|
||||
controle financeiro.
|
||||
</p>
|
||||
</div>
|
||||
<Suspense fallback={<Skeleton />}>
|
||||
<div className="space-y-0.5 mb-8">
|
||||
<h1 className="text-2xl font-bold tracking-tight">
|
||||
Resumo de cobranças
|
||||
</h1>
|
||||
<p className="text-muted-foreground">
|
||||
Acompanhe as cobranças em tempo real e garanta mais eficiência no
|
||||
controle financeiro.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<Await resolve={billing}>
|
||||
{({ items = [], ...billing }) => {
|
||||
const {
|
||||
icon: Icon,
|
||||
label: status,
|
||||
color
|
||||
} = statuses?.[billing?.status || 'CLOSED']
|
||||
<Await resolve={billing}>
|
||||
{({ items = [], ...billing }) => {
|
||||
const {
|
||||
icon: Icon,
|
||||
label: status,
|
||||
color
|
||||
} = statuses?.[billing?.status || 'CLOSED']
|
||||
|
||||
return (
|
||||
<Card>
|
||||
<CardContent className="space-y-4">
|
||||
<div className="flex max-lg:flex-col gap-2.5">
|
||||
<div className="w-full xl:w-1/4">
|
||||
<SearchForm
|
||||
defaultValue={search || ''}
|
||||
placeholder={
|
||||
<>
|
||||
Digite <Kbd className="border font-mono">/</Kbd>{' '}
|
||||
para pesquisar
|
||||
</>
|
||||
}
|
||||
onChange={(value) =>
|
||||
setSearchParams((searchParams) => {
|
||||
searchParams.set('s', String(value))
|
||||
return searchParams
|
||||
})
|
||||
}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<RangePeriod
|
||||
startDate={startDate}
|
||||
endDate={endDate}
|
||||
billingDay={billing_day}
|
||||
return (
|
||||
<Card>
|
||||
<CardContent className="space-y-4">
|
||||
<div className="flex max-lg:flex-col gap-2.5">
|
||||
<div className="w-full xl:w-1/4">
|
||||
<SearchForm
|
||||
defaultValue={search || ''}
|
||||
placeholder={
|
||||
<>
|
||||
Digite <Kbd className="border font-mono">/</Kbd> para
|
||||
pesquisar
|
||||
</>
|
||||
}
|
||||
onChange={(value) =>
|
||||
setSearchParams((searchParams) => {
|
||||
searchParams.set('s', String(value))
|
||||
return searchParams
|
||||
})
|
||||
}
|
||||
/>
|
||||
|
||||
<Button
|
||||
className={cn('pointer-events-none lg:ml-auto', color)}
|
||||
variant="outline"
|
||||
asChild
|
||||
>
|
||||
<span>
|
||||
<Icon className="size-3.5" /> {status}
|
||||
</span>
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
<List items={items} search={search} />
|
||||
</CardContent>
|
||||
</Card>
|
||||
)
|
||||
}}
|
||||
</Await>
|
||||
</Suspense>
|
||||
</>
|
||||
<RangePeriod
|
||||
startDate={startDate}
|
||||
endDate={endDate}
|
||||
billingDay={billing_day}
|
||||
/>
|
||||
|
||||
<Button
|
||||
className={cn('pointer-events-none lg:ml-auto', color)}
|
||||
variant="outline"
|
||||
asChild
|
||||
>
|
||||
<span>
|
||||
<Icon className="size-3.5" /> {status}
|
||||
</span>
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
<List items={items} search={search} />
|
||||
</CardContent>
|
||||
</Card>
|
||||
)
|
||||
}}
|
||||
</Await>
|
||||
</Suspense>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -217,7 +215,7 @@ function List({ items, search }) {
|
||||
{charges.length ? (
|
||||
<>
|
||||
<TableHeader>
|
||||
<TableRow className="bg-muted-foreground/10 pointer-events-none">
|
||||
<TableRow className=" pointer-events-none">
|
||||
<TableHead>Colaborador</TableHead>
|
||||
<TableHead>Curso</TableHead>
|
||||
<TableHead>Matriculado por</TableHead>
|
||||
|
||||
Reference in New Issue
Block a user