Co-authored-by: renee-png <262607627+renee-png@users.noreply.github.com>
This commit is contained in:
gpt-engineer-app[bot]
2026-04-19 18:59:56 +00:00
co-authored by renee-png
parent 674e6329b3
commit 354ef188bc
+16
View File
@@ -366,6 +366,22 @@ function InvoicesIndex() {
</table>
</CardContent>
</Card>
{totalCount > PAGE_SIZE && (
<div className="flex items-center justify-between mt-3 text-sm">
<span className="text-muted-foreground">
Showing {totalCount === 0 ? 0 : page * PAGE_SIZE + 1}–{Math.min((page + 1) * PAGE_SIZE, totalCount)} of {totalCount}
</span>
<div className="flex items-center gap-2">
<Button variant="outline" size="sm" disabled={page === 0 || loading} onClick={() => setPage((p) => Math.max(0, p - 1))}>
Previous
</Button>
<span className="text-muted-foreground">Page {page + 1} of {totalPages}</span>
<Button variant="outline" size="sm" disabled={page + 1 >= totalPages || loading} onClick={() => setPage((p) => p + 1)}>
Next
</Button>
</div>
</div>
)}
</TabsContent>
<TabsContent value="time" className="mt-4">