Admin
Add: - Menambahkan folder : /admin/collaboration , /admin/investmen - NavbarMenu ### No Issue
This commit is contained in:
@@ -1,20 +1,12 @@
|
||||
/* eslint-disable @typescript-eslint/no-unused-vars */
|
||||
import {
|
||||
ClickableCustom,
|
||||
DrawerCustom,
|
||||
StackCustom,
|
||||
TextCustom,
|
||||
} from "@/components";
|
||||
import { StackCustom } from "@/components";
|
||||
import DrawerAdmin from "@/components/Drawer/DrawerAdmin";
|
||||
import NavbarMenu from "@/components/Drawer/NavbarMenu";
|
||||
import SidebarMenu from "@/components/Drawer/SidebarMenu";
|
||||
import NavbarMenu, { NavbarItem } from "@/components/Drawer/NavbarMenu";
|
||||
import { AccentColor, MainColor } from "@/constants/color-palet";
|
||||
import { ICON_SIZE_SMALL } from "@/constants/constans-value";
|
||||
import { GStyles } from "@/styles/global-styles";
|
||||
import { FontAwesome6, Ionicons } from "@expo/vector-icons";
|
||||
import { router, Stack } from "expo-router";
|
||||
import { Stack } from "expo-router";
|
||||
import { useState } from "react";
|
||||
import { View } from "react-native";
|
||||
|
||||
export default function AdminLayout() {
|
||||
const [openDrawer, setOpenDrawer] = useState(false);
|
||||
@@ -45,17 +37,37 @@ export default function AdminLayout() {
|
||||
),
|
||||
}}
|
||||
>
|
||||
<Stack.Screen name="dashboard" options={{ title: "Dashboard" }} />
|
||||
<Stack.Screen name="dashboard" options={{ title: "Main Dashboard" }} />
|
||||
<Stack.Screen name="investment/index" options={{ title: "Dashboard Investasi" }} />
|
||||
<Stack.Screen name="investment/publish" options={{ title: "Investasi Publish" }} />
|
||||
<Stack.Screen name="investment/review" options={{ title: "Investasi Review" }} />
|
||||
<Stack.Screen name="investment/reject" options={{ title: "Investasi Reject" }} />
|
||||
<Stack.Screen name="maps" options={{ title: "Maps" }} />
|
||||
<Stack.Screen name="information" options={{ title: "Information" }} />
|
||||
<Stack.Screen name="job/index" options={{ title: "Job" }} />
|
||||
<Stack.Screen name="job/index" options={{ title: "Dashboard Job" }} />
|
||||
<Stack.Screen name="job/publish" options={{ title: "Job Publish" }} />
|
||||
<Stack.Screen name="job/review" options={{ title: "Job Review" }} />
|
||||
<Stack.Screen name="job/reject" options={{ title: "Job Reject" }} />
|
||||
<Stack.Screen
|
||||
name="collaboration/index"
|
||||
options={{ title: "Dashboard Collaboration" }}
|
||||
/>
|
||||
<Stack.Screen
|
||||
name="collaboration/publish"
|
||||
options={{ title: "Collaboration Publish" }}
|
||||
/>
|
||||
<Stack.Screen
|
||||
name="collaboration/group"
|
||||
options={{ title: "Collaboration Group" }}
|
||||
/>
|
||||
<Stack.Screen
|
||||
name="collaboration/reject"
|
||||
options={{ title: "Collaboration Reject" }}
|
||||
/>
|
||||
</Stack>
|
||||
|
||||
<DrawerAdmin isVisible={openDrawer} onClose={() => setOpenDrawer(false)}>
|
||||
<StackCustom gap={"lg"}>
|
||||
<StackCustom gap={"xs"}>
|
||||
<Ionicons
|
||||
name="close"
|
||||
size={ICON_SIZE_SMALL}
|
||||
@@ -64,31 +76,102 @@ export default function AdminLayout() {
|
||||
style={{ alignSelf: "flex-end" }}
|
||||
/>
|
||||
|
||||
<NavbarMenu
|
||||
items={[
|
||||
{ label: "Dashboard", icon: "home", link: "/admin/dashboard" },
|
||||
{ label: "Maps", icon: "map", link: "/admin/maps" },
|
||||
{
|
||||
label: "Information",
|
||||
icon: "information-circle",
|
||||
link: "/admin/information",
|
||||
},
|
||||
{
|
||||
label: "Job",
|
||||
icon: "calendar",
|
||||
links: [
|
||||
{ label: "Summary", link: "/admin/job" },
|
||||
{ label: "Publish", link: "/admin/job/publish" },
|
||||
{ label: "Review", link: "/admin/job/review" },
|
||||
{ label: "Reject", link: "/admin/job/reject" },
|
||||
],
|
||||
},
|
||||
]}
|
||||
onClose={() => setOpenDrawer(false)}
|
||||
/>
|
||||
<NavbarMenu items={listItem} onClose={() => setOpenDrawer(false)} />
|
||||
</StackCustom>
|
||||
</DrawerAdmin>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
const listItem: NavbarItem[] = [
|
||||
{
|
||||
label: "Main Dashboard",
|
||||
icon: "home",
|
||||
link: "/admin/dashboard",
|
||||
},
|
||||
{
|
||||
label: "Investasi",
|
||||
icon: "wallet",
|
||||
links: [
|
||||
{ label: "Dashboard", link: "/admin/investment" },
|
||||
{ label: "Publish", link: "/admin/investment/publish" },
|
||||
{ label: "Review", link: "/admin/investment/review" },
|
||||
{ label: "Reject", link: "/admin/investment/reject" },
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "Donasi",
|
||||
icon: "hand-right",
|
||||
links: [
|
||||
{ label: "Dashboard", link: "/admin/donasi" },
|
||||
{ label: "Publish", link: "/admin/donasi/publish" },
|
||||
{ label: "Review", link: "/admin/donasi/review" },
|
||||
{ label: "Reject", link: "/admin/donasi/reject" },
|
||||
{ label: "Kategori", link: "/admin/donasi/kategori" },
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "Event",
|
||||
icon: "calendar-clear",
|
||||
links: [
|
||||
{ label: "Dashboard", link: "/admin/event" },
|
||||
{ label: "Publish", link: "/admin/event/publish" },
|
||||
{ label: "Review", link: "/admin/event/review" },
|
||||
{ label: "Reject", link: "/admin/event/reject" },
|
||||
{ label: "Tipe Acara", link: "/admin/event/tipe-acara" },
|
||||
{ label: "Riwayat", link: "/admin/event/riwayat" },
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "Voting",
|
||||
icon: "accessibility-outline",
|
||||
links: [
|
||||
{ label: "Dashboard", link: "/admin/voting" },
|
||||
{ label: "Publish", link: "/admin/voting/publish" },
|
||||
{ label: "Review", link: "/admin/voting/review" },
|
||||
{ label: "Reject", link: "/admin/voting/reject" },
|
||||
{ label: "Riwayat", link: "/admin/voting/riwayat" },
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "Job",
|
||||
icon: "desktop-outline",
|
||||
links: [
|
||||
{ label: "Dashboard", link: "/admin/job" },
|
||||
{ label: "Publish", link: "/admin/job/publish" },
|
||||
{ label: "Review", link: "/admin/job/review" },
|
||||
{ label: "Reject", link: "/admin/job/reject" },
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "Forum",
|
||||
icon: "chatbubble-ellipses-outline",
|
||||
links: [
|
||||
{ label: "Dashboard", link: "/admin/forum" },
|
||||
{ label: "Posting", link: "/admin/forum/publish" },
|
||||
{ label: "Report Posting", link: "/admin/forum/review" },
|
||||
{ label: "Report Comment", link: "/admin/forum/reject" },
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "Collaboration",
|
||||
icon: "people",
|
||||
links: [
|
||||
{ label: "Dashboard", link: "/admin/collaboration" },
|
||||
{ label: "Publish", link: "/admin/collaboration/publish" },
|
||||
{ label: "Group", link: "/admin/collaboration/group" },
|
||||
{ label: "Reject", link: "/admin/collaboration/reject" },
|
||||
],
|
||||
},
|
||||
{ label: "Maps", icon: "map", link: "/admin/maps" },
|
||||
{
|
||||
label: "App Information",
|
||||
icon: "information-circle",
|
||||
link: "/admin/information",
|
||||
},
|
||||
{
|
||||
label: "User Access",
|
||||
icon: "people",
|
||||
link: "/admin/user-access",
|
||||
},
|
||||
];
|
||||
|
||||
11
app/(application)/admin/collaboration/group.tsx
Normal file
11
app/(application)/admin/collaboration/group.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminCollaborationGroup() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Collaboration Group</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/collaboration/index.tsx
Normal file
11
app/(application)/admin/collaboration/index.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminCollaboration() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Collaboration</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/collaboration/publish.tsx
Normal file
11
app/(application)/admin/collaboration/publish.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminCollaborationPublish() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Collaboration Publish</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/collaboration/reject.tsx
Normal file
11
app/(application)/admin/collaboration/reject.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminCollaborationReject() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Collaboration Reject</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/investment/index.tsx
Normal file
11
app/(application)/admin/investment/index.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminInvestment() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Investment</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/investment/publish.tsx
Normal file
11
app/(application)/admin/investment/publish.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminInvestmentPublish() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Investment Publish</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/investment/reject.tsx
Normal file
11
app/(application)/admin/investment/reject.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminInvestmentReject() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Investment Reject</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/investment/review.tsx
Normal file
11
app/(application)/admin/investment/review.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminInvestmentReview() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Investment Review</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user