member kyc

This commit is contained in:
unknown
2025-03-04 23:04:31 +07:00
parent 52eee53002
commit 985ceacb42
8 changed files with 188 additions and 51 deletions

View File

@ -1,8 +1,8 @@
import { ColumnDef } from '@tanstack/react-table';
export type Group = {
id: number;
createdDate: Date;
no: number;
created_at: Date;
name: string;
status: string;
description: string;
@ -10,13 +10,13 @@ export type Group = {
export const columns: ColumnDef<Group>[] = [
{
accessorKey: 'id',
accessorKey: 'no',
header: 'ID'
},
{
accessorKey: 'createdDate',
accessorKey: 'created_at',
header: 'Created Date',
cell: ({ row }) => new Date(row.original.createdDate).toLocaleDateString()
cell: ({ row }) => new Date(row.original.created_at).toLocaleDateString()
},
{
accessorKey: 'name',

View File

@ -47,7 +47,12 @@ const ManageGroups = () => {
order_direction: 'ASC'
}
});
setDataGroup(groups.data.data.list)
let temp = 1
let resGroups = groups.data.data.list.map((el: any) => {
el.no = temp++
return el
})
setDataGroup(resGroups)
} catch (error: any) {
alert(error.message)
console.log(error);