feat: restructure folder for contributor, supervisor, curator; update landing page pagination (image); etc
This commit is contained in:
parent
5fb177cb41
commit
cec4259da8
|
|
@ -112,7 +112,7 @@ const EventModal = ({
|
||||||
confirmButtonColor: "#3085d6",
|
confirmButtonColor: "#3085d6",
|
||||||
confirmButtonText: "OK",
|
confirmButtonText: "OK",
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
router.push("/en/agenda-setting");
|
router.push("/contributor/agenda-setting");
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -139,7 +139,7 @@ const columns: ColumnDef<any>[] = [
|
||||||
</Button>
|
</Button>
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent className="p-0" align="end">
|
<DropdownMenuContent className="p-0" align="end">
|
||||||
<a href="/en/task/detail/[id]">
|
<a href="/contributor/task/detail/[id]">
|
||||||
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
||||||
<Eye className="w-4 h-4 me-1.5" />
|
<Eye className="w-4 h-4 me-1.5" />
|
||||||
View
|
View
|
||||||
|
|
@ -58,7 +58,7 @@ const ReactTableVideoPage = () => {
|
||||||
Konten Video
|
Konten Video
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-none">
|
<div className="flex-none">
|
||||||
<Link href={"/content/audio-visual/create"}>
|
<Link href={"/contributor/content/audio-visual/create"}>
|
||||||
<Button color="primary" className="text-white">
|
<Button color="primary" className="text-white">
|
||||||
<UploadIcon />
|
<UploadIcon />
|
||||||
Unggah Video
|
Unggah Video
|
||||||
|
|
@ -139,7 +139,7 @@ const columns: ColumnDef<any>[] = [
|
||||||
</Button>
|
</Button>
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent className="p-0" align="end">
|
<DropdownMenuContent className="p-0" align="end">
|
||||||
<a href="/en/task/detail/[id]">
|
<a href="/contributor/task/detail/[id]">
|
||||||
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
||||||
<Eye className="w-4 h-4 me-1.5" />
|
<Eye className="w-4 h-4 me-1.5" />
|
||||||
View
|
View
|
||||||
|
|
@ -139,7 +139,7 @@ const columns: ColumnDef<any>[] = [
|
||||||
</Button>
|
</Button>
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent className="p-0" align="end">
|
<DropdownMenuContent className="p-0" align="end">
|
||||||
<a href="/en/task/detail/[id]">
|
<a href="/contributor/task/detail/[id]">
|
||||||
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
||||||
<Eye className="w-4 h-4 me-1.5" />
|
<Eye className="w-4 h-4 me-1.5" />
|
||||||
View
|
View
|
||||||
|
|
@ -6,7 +6,6 @@ import { UploadIcon } from "lucide-react";
|
||||||
import { Button } from "@/components/ui/button";
|
import { Button } from "@/components/ui/button";
|
||||||
import { Icon } from "@iconify/react/dist/iconify.js";
|
import { Icon } from "@iconify/react/dist/iconify.js";
|
||||||
import { Link } from "@/components/navigation";
|
import { Link } from "@/components/navigation";
|
||||||
import TicketingTable from "../../ticketing/components/table";
|
|
||||||
|
|
||||||
const ReactTableImagePage = () => {
|
const ReactTableImagePage = () => {
|
||||||
return (
|
return (
|
||||||
|
|
@ -58,7 +57,7 @@ const ReactTableImagePage = () => {
|
||||||
Konten Foto
|
Konten Foto
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-none">
|
<div className="flex-none">
|
||||||
<Link href={"/content/image/create"}>
|
<Link href={"/contributor/content/image/create"}>
|
||||||
<Button color="primary" className="text-white">
|
<Button color="primary" className="text-white">
|
||||||
<UploadIcon />
|
<UploadIcon />
|
||||||
Unggah Foto
|
Unggah Foto
|
||||||
|
|
@ -88,7 +88,7 @@ const columns: ColumnDef<any>[] = [
|
||||||
</Button>
|
</Button>
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent className="p-0" align="end">
|
<DropdownMenuContent className="p-0" align="end">
|
||||||
<a href="/en/task/detail/[id]">
|
<a href="/contributor/task/detail/[id]">
|
||||||
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
||||||
<Eye className="w-4 h-4 me-1.5" />
|
<Eye className="w-4 h-4 me-1.5" />
|
||||||
View
|
View
|
||||||
|
|
@ -177,7 +177,7 @@ const columns: ColumnDef<CompanyData>[] = [
|
||||||
</Button>
|
</Button>
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent className="p-0" align="end">
|
<DropdownMenuContent className="p-0" align="end">
|
||||||
<a href="/en/task/detail/[id]">
|
<a href="/contributor/task/detail/[id]">
|
||||||
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
||||||
<Eye className="w-4 h-4 me-1.5" />
|
<Eye className="w-4 h-4 me-1.5" />
|
||||||
View
|
View
|
||||||
|
|
@ -139,7 +139,7 @@ const columns: ColumnDef<any>[] = [
|
||||||
</Button>
|
</Button>
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent className="p-0" align="end">
|
<DropdownMenuContent className="p-0" align="end">
|
||||||
<a href="/en/task/detail/[id]">
|
<a href="/contributor/task/detail/[id]">
|
||||||
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
||||||
<Eye className="w-4 h-4 me-1.5" />
|
<Eye className="w-4 h-4 me-1.5" />
|
||||||
View
|
View
|
||||||
|
|
@ -5,7 +5,6 @@ import { UploadIcon } from "lucide-react";
|
||||||
import PressConferenceTable from "../press-conference/components/presscon-table";
|
import PressConferenceTable from "../press-conference/components/presscon-table";
|
||||||
import EventTable from "./components/event-table";
|
import EventTable from "./components/event-table";
|
||||||
import { Link } from "@/components/navigation";
|
import { Link } from "@/components/navigation";
|
||||||
import TicketingTable from "../../ticketing/components/table";
|
|
||||||
|
|
||||||
const EventPage = async () => {
|
const EventPage = async () => {
|
||||||
return (
|
return (
|
||||||
|
|
@ -20,7 +19,7 @@ const EventPage = async () => {
|
||||||
Jadwal Event
|
Jadwal Event
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-none">
|
<div className="flex-none">
|
||||||
<Link href={"/schedule/event/create"}>
|
<Link href={"/contributor/schedule/event/create"}>
|
||||||
<Button color="primary" className="text-white">
|
<Button color="primary" className="text-white">
|
||||||
<UploadIcon />
|
<UploadIcon />
|
||||||
Buat Jadwal
|
Buat Jadwal
|
||||||
|
|
@ -139,7 +139,7 @@ const columns: ColumnDef<any>[] = [
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent className="p-0" align="end">
|
<DropdownMenuContent className="p-0" align="end">
|
||||||
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
<DropdownMenuItem className="p-2 border-b text-default-700 group focus:bg-default focus:text-primary-foreground rounded-none">
|
||||||
<Link href={`/schedule/press-conference/detail/${row.id}`}>
|
<Link href={`/contributor/schedule/press-conference/detail/${row.id}`}>
|
||||||
<Eye className="w-4 h-4 me-1.5" />
|
<Eye className="w-4 h-4 me-1.5" />
|
||||||
Detail
|
Detail
|
||||||
</Link>
|
</Link>
|
||||||
|
|
@ -4,7 +4,6 @@ import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
|
||||||
import PressConferenceTable from "./components/presscon-table";
|
import PressConferenceTable from "./components/presscon-table";
|
||||||
import { UploadIcon } from "lucide-react";
|
import { UploadIcon } from "lucide-react";
|
||||||
import { Link } from "@/components/navigation";
|
import { Link } from "@/components/navigation";
|
||||||
import TicketingTable from "../../ticketing/components/table";
|
|
||||||
|
|
||||||
const PressConferencePage = async () => {
|
const PressConferencePage = async () => {
|
||||||
return (
|
return (
|
||||||
|
|
@ -19,7 +18,7 @@ const PressConferencePage = async () => {
|
||||||
Jadwal Konferensi Pers
|
Jadwal Konferensi Pers
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-none">
|
<div className="flex-none">
|
||||||
<Link href={"/schedule/press-conference/create"}>
|
<Link href={"/contributor/schedule/press-conference/create"}>
|
||||||
<Button color="primary" className="text-white">
|
<Button color="primary" className="text-white">
|
||||||
<UploadIcon />
|
<UploadIcon />
|
||||||
Buat Jadwal
|
Buat Jadwal
|
||||||
|
|
@ -3,7 +3,6 @@ import { Button } from "@/components/ui/button";
|
||||||
import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
|
import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
|
||||||
import { UploadIcon } from "lucide-react";
|
import { UploadIcon } from "lucide-react";
|
||||||
import { Link } from "@/components/navigation";
|
import { Link } from "@/components/navigation";
|
||||||
import TicketingTable from "../../ticketing/components/table";
|
|
||||||
import PressReleaseTable from "./components/pressrilis-table";
|
import PressReleaseTable from "./components/pressrilis-table";
|
||||||
|
|
||||||
const PressReleasePage = async () => {
|
const PressReleasePage = async () => {
|
||||||
|
|
@ -19,7 +18,7 @@ const PressReleasePage = async () => {
|
||||||
Jadwal Pers Rilis
|
Jadwal Pers Rilis
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-none">
|
<div className="flex-none">
|
||||||
<Link href={"/schedule/press-release/create"}>
|
<Link href={"/contributor/schedule/press-release/create"}>
|
||||||
<Button color="primary" className="text-white">
|
<Button color="primary" className="text-white">
|
||||||
<UploadIcon />
|
<UploadIcon />
|
||||||
Buat Jadwal
|
Buat Jadwal
|
||||||
|
|
@ -73,7 +73,7 @@ const TaskTable = () => {
|
||||||
const [page, setPage] = React.useState(1);
|
const [page, setPage] = React.useState(1);
|
||||||
const [totalPage, setTotalPage] = React.useState(1);
|
const [totalPage, setTotalPage] = React.useState(1);
|
||||||
const [limit, setLimit] = React.useState(10);
|
const [limit, setLimit] = React.useState(10);
|
||||||
const [activeTab, setActiveTab] = React.useState("atensi-khusus");
|
const [isSpecificAttention, setIsSpecificAttention] = React.useState(true);
|
||||||
|
|
||||||
const table = useReactTable({
|
const table = useReactTable({
|
||||||
data: dataTable,
|
data: dataTable,
|
||||||
|
|
@ -105,11 +105,11 @@ const TaskTable = () => {
|
||||||
|
|
||||||
React.useEffect(() => {
|
React.useEffect(() => {
|
||||||
fetchData();
|
fetchData();
|
||||||
}, [page, limit, activeTab]);
|
}, [page, limit, isSpecificAttention]);
|
||||||
|
|
||||||
async function fetchData() {
|
async function fetchData() {
|
||||||
try {
|
try {
|
||||||
const res = await listTask("", page - 1, limit, activeTab);
|
const res = await listTask("", page - 1, limit, isSpecificAttention ? "atensi-khusu" : "tugas-harian");
|
||||||
const data = res.data?.data;
|
const data = res.data?.data;
|
||||||
const contentData = data?.content;
|
const contentData = data?.content;
|
||||||
contentData.forEach((item: any, index: number) => {
|
contentData.forEach((item: any, index: number) => {
|
||||||
|
|
@ -131,22 +131,31 @@ const TaskTable = () => {
|
||||||
<div className="mx-5 mb-3">
|
<div className="mx-5 mb-3">
|
||||||
<div className="">
|
<div className="">
|
||||||
<div className="row">
|
<div className="row">
|
||||||
<Button
|
<div className="flex justify-between mb-6">
|
||||||
onClick={() => setActiveTab("atensi-khusus")}
|
<label className="inline-flex text-md cursor-pointer">
|
||||||
className={`col-md-6 text-center rounded-none ${
|
<input type="checkbox" onChange={() => setIsSpecificAttention(!isSpecificAttention)} hidden />
|
||||||
activeTab == "atensi-khusus" ? "text-blue-600" : "text-muted"
|
<span
|
||||||
}`}
|
className={` ${
|
||||||
|
isSpecificAttention
|
||||||
|
? "bg-default-900 text-white"
|
||||||
|
: "dark:text-default-700 border-2"
|
||||||
|
}
|
||||||
|
px-[18px] py-1 transition duration-100 rounded`}
|
||||||
>
|
>
|
||||||
Atensi Khusus
|
Atensi Khusus
|
||||||
</Button>
|
</span>
|
||||||
<Button
|
<span
|
||||||
onClick={() => setActiveTab("tugas-harian")}
|
className={`
|
||||||
className={`col text-center rounded-none ${
|
${
|
||||||
activeTab == "tugas-harian" ? "text-blue-600" : "text-muted"
|
!isSpecificAttention ? "bg-default-900 text-white" : " dark:text-default-700 border-2"
|
||||||
}`}
|
}
|
||||||
|
px-[18px] py-1 transition duration-100 rounded
|
||||||
|
`}
|
||||||
>
|
>
|
||||||
Tugas Harian
|
Tugas Harian
|
||||||
</Button>
|
</span>
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -7,7 +7,6 @@ import SiteBreadcrumb from "@/components/site-breadcrumb";
|
||||||
import { Link } from "@/components/navigation";
|
import { Link } from "@/components/navigation";
|
||||||
import { checkAuthorization, checkLoginSession } from "@/lib/utils";
|
import { checkAuthorization, checkLoginSession } from "@/lib/utils";
|
||||||
import React, { useEffect } from "react";
|
import React, { useEffect } from "react";
|
||||||
import TicketingTable from "../ticketing/components/table";
|
|
||||||
|
|
||||||
const TaskPage = () => {
|
const TaskPage = () => {
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
|
@ -31,7 +30,7 @@ const TaskPage = () => {
|
||||||
Table Penugasan
|
Table Penugasan
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-none">
|
<div className="flex-none">
|
||||||
<Link href={"/task/create"}>
|
<Link href={"/contributor/task/create"}>
|
||||||
<Button color="primary" className="text-white">
|
<Button color="primary" className="text-white">
|
||||||
<UploadIcon />
|
<UploadIcon />
|
||||||
Buat Penugasan
|
Buat Penugasan
|
||||||
|
|
@ -7,9 +7,9 @@ import { Button } from "@/components/ui/button";
|
||||||
import { UploadIcon } from "lucide-react";
|
import { UploadIcon } from "lucide-react";
|
||||||
import RecentActivity from "./routine-task/recent-activity";
|
import RecentActivity from "./routine-task/recent-activity";
|
||||||
import CompanyTable from "./routine-task/routine-task-table";
|
import CompanyTable from "./routine-task/routine-task-table";
|
||||||
import TaskTable from "../task/components/task-table";
|
import TaskTable from "../contributor/task/components/task-table";
|
||||||
import PressConferenceTable from "../schedule/press-release/components/pressrilis-table";
|
import PressConferenceTable from "../contributor/schedule/press-release/components/pressrilis-table";
|
||||||
import BlogTable from "../blog/components/blog-table";
|
import BlogTable from "../contributor/blog/components/blog-table";
|
||||||
|
|
||||||
const DashboardPage = () => {
|
const DashboardPage = () => {
|
||||||
const t = useTranslations("AnalyticsDashboard");
|
const t = useTranslations("AnalyticsDashboard");
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ const ContestPage = async () => {
|
||||||
Table Lomba
|
Table Lomba
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-none">
|
<div className="flex-none">
|
||||||
{/* <Link href={"/task/create"}>
|
{/* <Link href={"/contributor/task/create"}>
|
||||||
<Button color="primary" className="text-white">
|
<Button color="primary" className="text-white">
|
||||||
<UploadIcon />
|
<UploadIcon />
|
||||||
Buat Penugasan
|
Buat Penugasan
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue