Admin
Add:" - app/(application)/admin/ ## NO Issue
This commit is contained in:
@@ -1,43 +0,0 @@
|
||||
/* eslint-disable @typescript-eslint/no-unused-vars */
|
||||
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 { Stack } from "expo-router";
|
||||
import { useState } from "react";
|
||||
|
||||
export default function AdminLayout() {
|
||||
const [openDrawer, setOpenDrawer] = useState(false);
|
||||
return (
|
||||
<>
|
||||
<Stack
|
||||
screenOptions={{
|
||||
headerStyle: GStyles.headerStyle,
|
||||
headerTitleStyle: GStyles.headerTitleStyle,
|
||||
headerTitleAlign: "center",
|
||||
contentStyle: {
|
||||
borderBottomColor: AccentColor.blue,
|
||||
},
|
||||
headerLeft: () => (
|
||||
<Ionicons
|
||||
name="menu"
|
||||
size={ICON_SIZE_SMALL}
|
||||
color={MainColor.white}
|
||||
/>
|
||||
),
|
||||
headerRight: () => (
|
||||
<FontAwesome6
|
||||
name="circle-user"
|
||||
size={ICON_SIZE_SMALL}
|
||||
color={MainColor.white}
|
||||
/>
|
||||
),
|
||||
}}
|
||||
>
|
||||
<Stack.Screen name="dashboard" options={{ title: "Dashboard" }} />
|
||||
<Stack.Screen name="maps" options={{ title: "Maps" }} />
|
||||
<Stack.Screen name="information" options={{ title: "Information" }} />
|
||||
</Stack>
|
||||
</>
|
||||
);
|
||||
}
|
||||
@@ -1,9 +0,0 @@
|
||||
import { Text } from "react-native";
|
||||
|
||||
export default function AdminDashboard() {
|
||||
return (
|
||||
<>
|
||||
<Text>Dashboard</Text>
|
||||
</>
|
||||
);
|
||||
}
|
||||
@@ -1,9 +0,0 @@
|
||||
import { Text } from "react-native";
|
||||
|
||||
export default function AdminInformation() {
|
||||
return (
|
||||
<>
|
||||
<Text>Information</Text>
|
||||
</>
|
||||
);
|
||||
}
|
||||
@@ -1,9 +0,0 @@
|
||||
import { Text } from "react-native";
|
||||
|
||||
export default function AdminMaps() {
|
||||
return (
|
||||
<>
|
||||
<Text>Maps</Text>
|
||||
</>
|
||||
);
|
||||
}
|
||||
@@ -7,7 +7,8 @@ export default function ApplicationLayout() {
|
||||
<>
|
||||
<Stack screenOptions={HeaderStyles}>
|
||||
<Stack.Screen name="(user)" options={{ headerShown: false }} />
|
||||
<Stack.Screen name="(admin)" options={{ headerShown: false }} />
|
||||
<Stack.Screen name="admin" options={{ headerShown: false }} />
|
||||
|
||||
|
||||
{/* Take Picture */}
|
||||
<Stack.Screen
|
||||
|
||||
94
app/(application)/admin/_layout.tsx
Normal file
94
app/(application)/admin/_layout.tsx
Normal file
@@ -0,0 +1,94 @@
|
||||
/* eslint-disable @typescript-eslint/no-unused-vars */
|
||||
import {
|
||||
ClickableCustom,
|
||||
DrawerCustom,
|
||||
StackCustom,
|
||||
TextCustom,
|
||||
} from "@/components";
|
||||
import DrawerAdmin from "@/components/Drawer/DrawerAdmin";
|
||||
import NavbarMenu from "@/components/Drawer/NavbarMenu";
|
||||
import SidebarMenu from "@/components/Drawer/SidebarMenu";
|
||||
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 { useState } from "react";
|
||||
import { View } from "react-native";
|
||||
|
||||
export default function AdminLayout() {
|
||||
const [openDrawer, setOpenDrawer] = useState(false);
|
||||
return (
|
||||
<>
|
||||
<Stack
|
||||
screenOptions={{
|
||||
headerStyle: GStyles.headerStyle,
|
||||
headerTitleStyle: GStyles.headerTitleStyle,
|
||||
headerTitleAlign: "center",
|
||||
contentStyle: {
|
||||
borderBottomColor: AccentColor.blue,
|
||||
},
|
||||
headerLeft: () => (
|
||||
<Ionicons
|
||||
name="menu"
|
||||
size={ICON_SIZE_SMALL}
|
||||
color={MainColor.white}
|
||||
onPress={() => setOpenDrawer(true)}
|
||||
/>
|
||||
),
|
||||
headerRight: () => (
|
||||
<FontAwesome6
|
||||
name="circle-user"
|
||||
size={ICON_SIZE_SMALL}
|
||||
color={MainColor.white}
|
||||
/>
|
||||
),
|
||||
}}
|
||||
>
|
||||
<Stack.Screen name="dashboard" options={{ title: "Dashboard" }} />
|
||||
<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/publish" options={{ title: "Job Publish" }} />
|
||||
<Stack.Screen name="job/review" options={{ title: "Job Review" }} />
|
||||
<Stack.Screen name="job/reject" options={{ title: "Job Reject" }} />
|
||||
</Stack>
|
||||
|
||||
<DrawerAdmin isVisible={openDrawer} onClose={() => setOpenDrawer(false)}>
|
||||
<StackCustom gap={"lg"}>
|
||||
<Ionicons
|
||||
name="close"
|
||||
size={ICON_SIZE_SMALL}
|
||||
color={MainColor.white}
|
||||
onPress={() => setOpenDrawer(false)}
|
||||
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)}
|
||||
/>
|
||||
</StackCustom>
|
||||
</DrawerAdmin>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
11
app/(application)/admin/dashboard.tsx
Normal file
11
app/(application)/admin/dashboard.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminDashboard() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Dashboard</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/information.tsx
Normal file
11
app/(application)/admin/information.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminInformation() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Information</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/job/index.tsx
Normal file
11
app/(application)/admin/job/index.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminJob() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Job</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/job/publish.tsx
Normal file
11
app/(application)/admin/job/publish.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminJobPublish() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Job Publish</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/job/reject.tsx
Normal file
11
app/(application)/admin/job/reject.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminJobReject() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Job Reject</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/job/review.tsx
Normal file
11
app/(application)/admin/job/review.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminJobReview() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Admin Job Review</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
11
app/(application)/admin/maps.tsx
Normal file
11
app/(application)/admin/maps.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
|
||||
export default function AdminMaps() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<TextCustom>Maps</TextCustom>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user