feat: implement category creation and update pages with routing adjustments
This commit is contained in:
@@ -33,6 +33,10 @@ export const CategoriesPage = () => {
|
||||
title: 'Code Katgeori',
|
||||
data: 'code',
|
||||
},
|
||||
{
|
||||
title: 'Action',
|
||||
data: 'id',
|
||||
},
|
||||
]
|
||||
|
||||
const dataOptions = {
|
||||
@@ -42,6 +46,18 @@ export const CategoriesPage = () => {
|
||||
info: true,
|
||||
}
|
||||
|
||||
const dataSlot = {
|
||||
3: (value: string) => (
|
||||
<Button
|
||||
as="a"
|
||||
href={`/lg-admin/category/update/${value}`}
|
||||
className="text-md rounded-md"
|
||||
size="sm"
|
||||
>
|
||||
Lihat Detail
|
||||
</Button>
|
||||
),
|
||||
}
|
||||
return (
|
||||
<div className="relative">
|
||||
<TitleDashboard title="Kategori" />
|
||||
@@ -61,6 +77,7 @@ export const CategoriesPage = () => {
|
||||
data={dataTable}
|
||||
columns={dataColumns}
|
||||
options={dataOptions}
|
||||
slots={dataSlot}
|
||||
title="Daftar Katgeori"
|
||||
/>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
import React from 'react'
|
||||
|
||||
export const UpdateCategoryPage = () => {
|
||||
return <div>UpdateCategoryPage</div>
|
||||
}
|
||||
Reference in New Issue
Block a user