diff --git a/src/components/runners/RunnersOverview.svelte b/src/components/runners/RunnersOverview.svelte index 3ab812dc..ab1e8c15 100644 --- a/src/components/runners/RunnersOverview.svelte +++ b/src/components/runners/RunnersOverview.svelte @@ -8,34 +8,46 @@ } from "@tanstack/svelte-table"; const columns = [ - // { - // accessorKey: "id", - // cell: (info) => info.getValue(), - // footer: (info) => info.column.id, - // }, - // { - // accessorFn: (row) => row.lastName, - // id: "lastName", - // cell: (info) => info.getValue(), - // header: () => "Last Name", - // footer: (info) => info.column.id, - // }, { accessorKey: "id", header: () => "id", }, { - accessorKey: "firstname", - header: () => "firstname", + header: "Name", + footer: (props) => props.column.id, + columns: [ + { + accessorKey: "firstname", + cell: (info) => info.getValue(), + footer: (props) => props.column.id, + }, + { + accessorFn: (row) => row.lastname, + id: "lastname", + cell: (info) => info.getValue(), + header: () => "Nachname", + footer: (props) => props.column.id, + }, + { + accessorFn: (row) => `${row.firstname} ${row.lastname}`, + id: "fullname", + header: "Voller Name", + cell: (info) => info.getValue(), + // footer: (props) => props.column.id, + // filterFn: "fuzzy", + // sortingFn: fuzzySort, + }, + ], }, // { - // accessorKey: "middlename", - // header: () => "middlename", + // accessorKey: "firstname", + // header: () => "firstname", // }, - { - accessorKey: "lastname", - header: () => "lastname", - }, + // { + // accessorKey: "lastname", + // header: () => "lastname", + // } + // , { accessorKey: "group.name", header: () => "group", @@ -165,6 +177,64 @@ {/each} +
+
+ + + + + +
Page
+ + {$table.getState().pagination.pageIndex + 1} of{" "} + {$table.getPageCount()} + +
+ + | Go to page: + { + const page = e.target.value ? Number(e.target.value) - 1 : 0; + $table.setPageIndex(page); + }} + class="border p-1 rounded w-16" + /> + + +
{/if} {/if}