Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated add, edit, delete dashboard #8

Merged
merged 1 commit into from
Oct 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/app/dashboard/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export default function Dashboard() {
</p>
</Link>
<Link
href={"/projects"}
href={"/dashboard/projects"}
className="flex w-full max-w-96 cursor-pointer flex-col items-center gap-6 rounded-md border border-gray-200 bg-[#fafafa] p-6 transition-all hover:bg-gray-200"
>
<p className="text-2xl">Edit Projects</p>
Expand Down
13 changes: 13 additions & 0 deletions src/app/dashboard/projects/add/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
"use client";


import ProtectedRoute from "@/components/auth/ProtectedRoute";
import AddForm from "@/components/Forms/AddForm";

export default function projects() {
return (
<ProtectedRoute>
<AddForm/>
</ProtectedRoute>
);
}
13 changes: 13 additions & 0 deletions src/app/dashboard/projects/edit/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
"use client";


import ProtectedRoute from "@/components/auth/ProtectedRoute";
import EditForm from "@/components/Forms/EditForm";

export default function projects() {
return (
<ProtectedRoute>
<EditForm/>
</ProtectedRoute>
);
}
43 changes: 43 additions & 0 deletions src/app/dashboard/projects/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
"use client";

import { BsFillGearFill, BsFillPlusSquareFill } from "react-icons/bs";
import Link from "next/link";
import ProtectedRoute from "@/components/auth/ProtectedRoute";

export default function projects() {
return (
<ProtectedRoute>
<div className="mx-auto max-w-7xl px-10 pt-16">
<h1 className="pb-4 text-3xl">Dashboard</h1>
<hr className="border-gray-200" />
<ul className="flex gap-8 pt-8">
<Link
href={"/dashboard/projects/add"}
className="flex w-full max-w-96 cursor-pointer flex-col items-center gap-6 rounded-md border border-gray-200 bg-[#fafafa] p-6 transition-all hover:bg-gray-200"
>
<p className="text-2xl">Add Projects</p>
<span className="text-[120px] text-blue-500">
<BsFillPlusSquareFill />
</span>
<p className="text-center">
Add new club projects
</p>
</Link>
<Link
href={"/dashboard/projects/edit"}
className="flex w-full max-w-96 cursor-pointer flex-col items-center gap-6 rounded-md border border-gray-200 bg-[#fafafa] p-6 transition-all hover:bg-gray-200"
>
<p className="text-2xl">Edit/Delete Projects</p>
<span className="text-[120px] text-blue-500">
<BsFillGearFill />
</span>
<p className="text-center">
Update and Delete club projects.
</p>
</Link>

</ul>
</div>
</ProtectedRoute>
);
}