Themes modal udpated
This commit is contained in:
@@ -2,14 +2,14 @@ import type { MRT_ColumnDef } from "mantine-react-table";
|
||||
import { useMemo } from "react";
|
||||
|
||||
export default function CategoryColumns() {
|
||||
const columns = useMemo<MRT_ColumnDef<any>[]>(
|
||||
const columns = useMemo<MRT_ColumnDef<any>[]>(
|
||||
() => [
|
||||
{
|
||||
accessorFn: (row) => {
|
||||
if (row.id) {
|
||||
return `${row.id}`;
|
||||
}
|
||||
return "";
|
||||
return "";
|
||||
},
|
||||
enableEditing: false,
|
||||
id: "id",
|
||||
@@ -18,12 +18,12 @@ export default function CategoryColumns() {
|
||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||
Header: ({ column }) => column.columnDef.header,
|
||||
},
|
||||
{
|
||||
{
|
||||
accessorFn: (row) => {
|
||||
if (row.category_name) {
|
||||
return `${row.category_name}`;
|
||||
}
|
||||
return "";
|
||||
return "";
|
||||
},
|
||||
id: "category_name",
|
||||
header: "Name",
|
||||
@@ -31,12 +31,12 @@ export default function CategoryColumns() {
|
||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||
Header: ({ column }) => column.columnDef.header,
|
||||
},
|
||||
{
|
||||
{
|
||||
accessorFn: (row) => {
|
||||
if (row.category_index > -1) {
|
||||
return `${row.category_index}`;
|
||||
}
|
||||
return "";
|
||||
return "";
|
||||
},
|
||||
enableEditing: false,
|
||||
id: "category_index",
|
||||
@@ -45,12 +45,12 @@ export default function CategoryColumns() {
|
||||
Cell: ({ renderedCellValue, row }) => renderedCellValue,
|
||||
Header: ({ column }) => column.columnDef.header,
|
||||
},
|
||||
{
|
||||
{
|
||||
accessorFn: (row) => {
|
||||
if (row.column_filter) {
|
||||
return `${row.column_filter}`;
|
||||
}
|
||||
return "";
|
||||
return "";
|
||||
},
|
||||
id: "column_filter",
|
||||
header: "Filter Name",
|
||||
@@ -62,6 +62,5 @@ export default function CategoryColumns() {
|
||||
[],
|
||||
);
|
||||
|
||||
return columns;
|
||||
return columns;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user