diff --git a/app/apis/admin/create-category.ts b/app/apis/admin/create-category.ts index 54fcd32..b18165b 100644 --- a/app/apis/admin/create-category.ts +++ b/app/apis/admin/create-category.ts @@ -1,7 +1,7 @@ import { z } from 'zod' import { HttpServer } from '~/libs/http-server' -import type { TCategorySchema } from '~/pages/category-create' +import type { TCategorySchema } from '~/pages/dashboard-category-create' const categoryResponseSchema = z.object({ data: z.object({ diff --git a/app/pages/dashboard-categories/index.tsx b/app/pages/dashboard-categories/index.tsx index 2cd031f..e2c92a1 100644 --- a/app/pages/dashboard-categories/index.tsx +++ b/app/pages/dashboard-categories/index.tsx @@ -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) => ( + + ), + } return (
@@ -61,6 +77,7 @@ export const CategoriesPage = () => { data={dataTable} columns={dataColumns} options={dataOptions} + slots={dataSlot} title="Daftar Katgeori" />
diff --git a/app/pages/category-create/index.tsx b/app/pages/dashboard-category-create/index.tsx similarity index 100% rename from app/pages/category-create/index.tsx rename to app/pages/dashboard-category-create/index.tsx diff --git a/app/pages/dashboard-category-update/index.tsx b/app/pages/dashboard-category-update/index.tsx new file mode 100644 index 0000000..ca8e173 --- /dev/null +++ b/app/pages/dashboard-category-update/index.tsx @@ -0,0 +1,5 @@ +import React from 'react' + +export const UpdateCategoryPage = () => { + return
UpdateCategoryPage
+} diff --git a/app/routes/_admin.lg-admin._dashboard.category.create.tsx b/app/routes/_admin.lg-admin._dashboard.category.create.tsx index 896d09b..5f475e0 100644 --- a/app/routes/_admin.lg-admin._dashboard.category.create.tsx +++ b/app/routes/_admin.lg-admin._dashboard.category.create.tsx @@ -1,4 +1,4 @@ -import { CreateCategoryPage } from '~/pages/category-create' +import { CreateCategoryPage } from '~/pages/dashboard-category-create' const DashboardCategoryLayout = () => export default DashboardCategoryLayout diff --git a/app/routes/_admin.lg-admin._dashboard.category.update.$slug.tsx b/app/routes/_admin.lg-admin._dashboard.category.update.$slug.tsx new file mode 100644 index 0000000..2da33fd --- /dev/null +++ b/app/routes/_admin.lg-admin._dashboard.category.update.$slug.tsx @@ -0,0 +1,4 @@ +import { UpdateCategoryPage } from '~/pages/dashboard-category-update' + +const DashboardCategoryUpdateLayout = () => +export default DashboardCategoryUpdateLayout diff --git a/app/routes/_admin.lg-admin._dashboard.settings.tsx b/app/routes/_admin.lg-admin._dashboard.settings.tsx index 4e2632a..f4b9873 100644 --- a/app/routes/_admin.lg-admin._dashboard.settings.tsx +++ b/app/routes/_admin.lg-admin._dashboard.settings.tsx @@ -1,2 +1,34 @@ -const DashboardSettingsLayout = () =>
Settings Page
+import { Button } from '~/components/ui/button' + +const DashboardSettingsLayout = () => ( +
+ {/* action sementara kategory */} +
+ + + +
+
+) export default DashboardSettingsLayout diff --git a/app/routes/actions.admin.category.create.ts b/app/routes/actions.admin.category.create.ts index 1f27a93..8dec87d 100644 --- a/app/routes/actions.admin.category.create.ts +++ b/app/routes/actions.admin.category.create.ts @@ -8,7 +8,7 @@ import { handleCookie } from '~/libs/cookies' import { createCategorySchema, type TCategorySchema, -} from '~/pages/category-create' +} from '~/pages/dashboard-category-create' import type { Route } from './+types/actions.register'