Feat:fix detail penugasan, approver language
This commit is contained in:
parent
bc2bbd98cf
commit
be7e34ee11
|
|
@ -590,15 +590,15 @@ const CalendarView = ({ categories }: CalendarViewProps) => {
|
|||
<Dialog open={open} onOpenChange={setOpen}>
|
||||
<DialogTrigger asChild>
|
||||
{roleId == 2 ? (
|
||||
<Button className="dark:bg-background dark:text-foreground ml-2">
|
||||
<Book className="w-4 h-4 me-1" />
|
||||
Hasil Pantauan BAG PA
|
||||
<Button className="dark:bg-background dark:text-foreground ">
|
||||
<Book className="w-4 h-4" />
|
||||
{t("bag-pa-monitoring-results")}
|
||||
</Button>
|
||||
) : null}
|
||||
</DialogTrigger>
|
||||
<DialogContent className="sm:max-w-[425px] md:max-w-[500px] lg:max-w-[1500px] overflow-y-auto max-h-[500px]">
|
||||
<DialogHeader>
|
||||
<DialogTitle>Hasil Pantauan</DialogTitle>
|
||||
<DialogTitle>{t("monitoring-results")}</DialogTitle>
|
||||
</DialogHeader>
|
||||
{getModalContent("terkirim")}
|
||||
</DialogContent>
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ import {
|
|||
TableRow,
|
||||
} from "@/components/ui/table";
|
||||
import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar";
|
||||
import { ChevronDown, Search } from "lucide-react";
|
||||
import { ChevronDown, Plus, Search } from "lucide-react";
|
||||
import { cn } from "@/lib/utils";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { InputGroup, InputGroupText } from "@/components/ui/input-group";
|
||||
|
|
@ -42,11 +42,14 @@ import {
|
|||
} from "@/components/ui/dropdown-menu";
|
||||
import { Label } from "@/components/ui/label";
|
||||
import { listEnableCategory } from "@/service/content/content";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { CardHeader, CardTitle } from "@/components/ui/card";
|
||||
import { Link } from "@/i18n/routing";
|
||||
|
||||
const BlogTable = () => {
|
||||
const router = useRouter();
|
||||
const searchParams = useSearchParams();
|
||||
|
||||
const t = useTranslations("Blog");
|
||||
const [dataTable, setDataTable] = React.useState<any[]>([]);
|
||||
const [totalData, setTotalData] = React.useState<number>(1);
|
||||
const [sorting, setSorting] = React.useState<SortingState>([]);
|
||||
|
|
@ -169,6 +172,25 @@ const BlogTable = () => {
|
|||
};
|
||||
|
||||
return (
|
||||
<div>
|
||||
<CardHeader className="border-b border-solid border-default-200 mb-6">
|
||||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
{t("table")} {t("blog")}
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/blog/create"}>
|
||||
<Button fullWidth color="primary">
|
||||
<Plus className="w-6 h-6 me-1.5" />
|
||||
{t("create-indeks")}
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
|
||||
<div className="w-full overflow-x-auto">
|
||||
<div className="flex flex-col md:flex-row lg:flex-row md:justify-between lg:justify-between items-center md:px-5 lg:px-5">
|
||||
<div className="w-full md:w-[200px] lg:w-[200px] px-2">
|
||||
|
|
@ -178,7 +200,7 @@ const BlogTable = () => {
|
|||
</InputGroupText>
|
||||
<Input
|
||||
type="text"
|
||||
placeholder="Search Judul..."
|
||||
placeholder="Search Title"
|
||||
className="bg-transparent dark:border-secondary dark:placeholder-white/80 dark:focus:border-secondary dark:text-white"
|
||||
value={search}
|
||||
onChange={handleSearch}
|
||||
|
|
@ -199,14 +221,8 @@ const BlogTable = () => {
|
|||
>
|
||||
<div className="flex flex-row justify-between my-1 mx-1">
|
||||
<p>Filter</p>
|
||||
{/* <p
|
||||
className="text-blue-600 cursor-pointer"
|
||||
onClick={fetchData}
|
||||
>
|
||||
Simpan
|
||||
</p> */}
|
||||
</div>
|
||||
<Label className="ml-2">Kategori</Label>
|
||||
<Label className="ml-2">{t("category")}</Label>
|
||||
{categories.length > 0 ? (
|
||||
categories.map((category) => (
|
||||
<div
|
||||
|
|
@ -342,14 +358,20 @@ const BlogTable = () => {
|
|||
>
|
||||
{row.getVisibleCells().map((cell) => (
|
||||
<TableCell key={cell.id}>
|
||||
{flexRender(cell.column.columnDef.cell, cell.getContext())}
|
||||
{flexRender(
|
||||
cell.column.columnDef.cell,
|
||||
cell.getContext()
|
||||
)}
|
||||
</TableCell>
|
||||
))}
|
||||
</TableRow>
|
||||
))
|
||||
) : (
|
||||
<TableRow>
|
||||
<TableCell colSpan={columns.length} className="h-24 text-center">
|
||||
<TableCell
|
||||
colSpan={columns.length}
|
||||
className="h-24 text-center"
|
||||
>
|
||||
No results.
|
||||
</TableCell>
|
||||
</TableRow>
|
||||
|
|
@ -362,6 +384,7 @@ const BlogTable = () => {
|
|||
totalPage={totalPage}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -11,23 +11,6 @@ const BlogPage = async () => {
|
|||
<SiteBreadcrumb />
|
||||
<div className="space-y-4">
|
||||
<Card>
|
||||
<CardHeader className="border-b border-solid border-default-200 mb-6">
|
||||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
Tabel Indeks
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/blog/create"}>
|
||||
<Button fullWidth color="primary">
|
||||
<Plus className="w-6 h-6 me-1.5" />
|
||||
Add Index
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent className="p-0">
|
||||
<BlogTable />
|
||||
</CardContent>
|
||||
|
|
|
|||
|
|
@ -22,18 +22,22 @@ import {
|
|||
TableHeader,
|
||||
TableRow,
|
||||
} from "@/components/ui/table";
|
||||
import { Search } from "lucide-react";
|
||||
import { Search, UploadIcon } from "lucide-react";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { InputGroup, InputGroupText } from "@/components/ui/input-group";
|
||||
import { useRouter, useSearchParams } from "next/navigation";
|
||||
import TablePagination from "@/components/table/table-pagination";
|
||||
import columns from "./columns";
|
||||
import { paginationSchedule } from "@/service/schedule/schedule";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { CardHeader, CardTitle } from "@/components/ui/card";
|
||||
import { Link } from "@/i18n/routing";
|
||||
import { Button } from "@/components/ui/button";
|
||||
|
||||
const EventTable = () => {
|
||||
const router = useRouter();
|
||||
const searchParams = useSearchParams();
|
||||
|
||||
const t = useTranslations("Schedule");
|
||||
const [dataTable, setDataTable] = React.useState<any[]>([]);
|
||||
const [totalData, setTotalData] = React.useState<number>(1);
|
||||
const [sorting, setSorting] = React.useState<SortingState>([]);
|
||||
|
|
@ -109,6 +113,24 @@ const EventTable = () => {
|
|||
};
|
||||
|
||||
return (
|
||||
<div>
|
||||
<CardHeader className="border-b border-solid border-default-200 mb-6">
|
||||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
Event {t("schedule")}
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/schedule/event/create"}>
|
||||
<Button color="primary" className="text-white">
|
||||
<UploadIcon />
|
||||
{t("create-schedule")}
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
<div className="w-full overflow-x-auto">
|
||||
<div className="flex justify-between items-center px-5 gap-2">
|
||||
<div className="w-[150px] md:w-[250px] lg:w-[250px]">
|
||||
|
|
@ -118,7 +140,7 @@ const EventTable = () => {
|
|||
</InputGroupText>
|
||||
<Input
|
||||
type="text"
|
||||
placeholder="Search Judul..."
|
||||
placeholder="Search Title..."
|
||||
className="bg-transparent dark:border-secondary dark:placeholder-white/80 dark:focus:border-secondary dark:text-white"
|
||||
value={search}
|
||||
onChange={handleSearch}
|
||||
|
|
@ -165,14 +187,20 @@ const EventTable = () => {
|
|||
>
|
||||
{row.getVisibleCells().map((cell) => (
|
||||
<TableCell key={cell.id}>
|
||||
{flexRender(cell.column.columnDef.cell, cell.getContext())}
|
||||
{flexRender(
|
||||
cell.column.columnDef.cell,
|
||||
cell.getContext()
|
||||
)}
|
||||
</TableCell>
|
||||
))}
|
||||
</TableRow>
|
||||
))
|
||||
) : (
|
||||
<TableRow>
|
||||
<TableCell colSpan={columns.length} className="h-24 text-center">
|
||||
<TableCell
|
||||
colSpan={columns.length}
|
||||
className="h-24 text-center"
|
||||
>
|
||||
No results.
|
||||
</TableCell>
|
||||
</TableRow>
|
||||
|
|
@ -185,6 +213,7 @@ const EventTable = () => {
|
|||
totalPage={totalPage}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -12,23 +12,6 @@ const EventPage = async () => {
|
|||
<SiteBreadcrumb />
|
||||
<div className="space-y-4">
|
||||
<Card>
|
||||
<CardHeader className="border-b border-solid border-default-200 mb-6">
|
||||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
Jadwal Event
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/schedule/event/create"}>
|
||||
<Button color="primary" className="text-white">
|
||||
<UploadIcon />
|
||||
Buat Jadwal
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent className="p-0">
|
||||
<EventTable />
|
||||
</CardContent>
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ import {
|
|||
Trash2,
|
||||
TrendingDown,
|
||||
TrendingUp,
|
||||
UploadIcon,
|
||||
} from "lucide-react";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { InputGroup, InputGroupText } from "@/components/ui/input-group";
|
||||
|
|
@ -42,11 +43,14 @@ import { useRouter, useSearchParams } from "next/navigation";
|
|||
import TablePagination from "@/components/table/table-pagination";
|
||||
import columns from "./columns";
|
||||
import { paginationSchedule } from "@/service/schedule/schedule";
|
||||
import { CardHeader, CardTitle } from "@/components/ui/card";
|
||||
import { Link } from "@/i18n/routing";
|
||||
import { useTranslations } from "next-intl";
|
||||
|
||||
const PressConferenceTable = () => {
|
||||
const router = useRouter();
|
||||
const searchParams = useSearchParams();
|
||||
|
||||
const t = useTranslations("Schedule");
|
||||
const [dataTable, setDataTable] = React.useState<any[]>([]);
|
||||
const [totalData, setTotalData] = React.useState<number>(1);
|
||||
const [sorting, setSorting] = React.useState<SortingState>([]);
|
||||
|
|
@ -122,6 +126,24 @@ const PressConferenceTable = () => {
|
|||
};
|
||||
|
||||
return (
|
||||
<div>
|
||||
<CardHeader className="border-b border-solid border-default-200 mb-6">
|
||||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
{t("press-conference")} {t("schedule")}
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/schedule/press-conference/create"}>
|
||||
<Button color="primary" className="text-white">
|
||||
<UploadIcon />
|
||||
{t("create-schedule")}
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
<div className="w-full overflow-x-auto">
|
||||
<div className="flex justify-between items-center px-5 gap-2">
|
||||
<div className="w-[150px] md:w-[250px] lg:w-[250px]">
|
||||
|
|
@ -131,7 +153,7 @@ const PressConferenceTable = () => {
|
|||
</InputGroupText>
|
||||
<Input
|
||||
type="text"
|
||||
placeholder="Search Judul..."
|
||||
placeholder="Search Title..."
|
||||
className="bg-transparent dark:border-secondary dark:placeholder-white/80 dark:focus:border-secondary dark:text-white"
|
||||
value={search}
|
||||
onChange={handleSearch}
|
||||
|
|
@ -178,14 +200,20 @@ const PressConferenceTable = () => {
|
|||
>
|
||||
{row.getVisibleCells().map((cell) => (
|
||||
<TableCell key={cell.id}>
|
||||
{flexRender(cell.column.columnDef.cell, cell.getContext())}
|
||||
{flexRender(
|
||||
cell.column.columnDef.cell,
|
||||
cell.getContext()
|
||||
)}
|
||||
</TableCell>
|
||||
))}
|
||||
</TableRow>
|
||||
))
|
||||
) : (
|
||||
<TableRow>
|
||||
<TableCell colSpan={columns.length} className="h-24 text-center">
|
||||
<TableCell
|
||||
colSpan={columns.length}
|
||||
className="h-24 text-center"
|
||||
>
|
||||
No results.
|
||||
</TableCell>
|
||||
</TableRow>
|
||||
|
|
@ -198,6 +226,7 @@ const PressConferenceTable = () => {
|
|||
totalPage={totalPage}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -2,8 +2,6 @@ import SiteBreadcrumb from "@/components/site-breadcrumb";
|
|||
import { Button } from "@/components/ui/button";
|
||||
import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
|
||||
import PressConferenceTable from "./components/presscon-table";
|
||||
import { UploadIcon } from "lucide-react";
|
||||
import { Link } from "@/components/navigation";
|
||||
|
||||
const PressConferencePage = async () => {
|
||||
return (
|
||||
|
|
@ -11,23 +9,6 @@ const PressConferencePage = async () => {
|
|||
<SiteBreadcrumb />
|
||||
<div className="space-y-4">
|
||||
<Card>
|
||||
<CardHeader className="border-b border-solid border-default-200 mb-6">
|
||||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
Jadwal Konferensi Pers
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/schedule/press-conference/create"}>
|
||||
<Button color="primary" className="text-white">
|
||||
<UploadIcon />
|
||||
Buat Jadwal
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent className="p-0">
|
||||
<PressConferenceTable />
|
||||
</CardContent>
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ import {
|
|||
Trash2,
|
||||
TrendingDown,
|
||||
TrendingUp,
|
||||
UploadIcon,
|
||||
} from "lucide-react";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { InputGroup, InputGroupText } from "@/components/ui/input-group";
|
||||
|
|
@ -43,11 +44,14 @@ import { useRouter, useSearchParams } from "next/navigation";
|
|||
import TablePagination from "@/components/table/table-pagination";
|
||||
import columns from "./columns";
|
||||
import { paginationSchedule } from "@/service/schedule/schedule";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { CardHeader, CardTitle } from "@/components/ui/card";
|
||||
import { Link } from "@/i18n/routing";
|
||||
|
||||
const PressReleaseTable = () => {
|
||||
const router = useRouter();
|
||||
const searchParams = useSearchParams();
|
||||
|
||||
const t = useTranslations("Schedule");
|
||||
const [dataTable, setDataTable] = React.useState<any[]>([]);
|
||||
const [totalData, setTotalData] = React.useState<number>(1);
|
||||
const [sorting, setSorting] = React.useState<SortingState>([]);
|
||||
|
|
@ -123,6 +127,24 @@ const PressReleaseTable = () => {
|
|||
};
|
||||
|
||||
return (
|
||||
<div>
|
||||
<CardHeader className="border-b border-solid border-default-200 mb-6">
|
||||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
{t("press-release")} {t("schedule")}
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/schedule/press-release/create"}>
|
||||
<Button color="primary" className="text-white">
|
||||
<UploadIcon />
|
||||
{t("create-schedule")}
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
<div className="w-full overflow-x-auto">
|
||||
<div className="flex justify-between items-center px-5 gap-2">
|
||||
<div className="w-[150px] md:w-[250px] lg:w-[250px]">
|
||||
|
|
@ -132,7 +154,7 @@ const PressReleaseTable = () => {
|
|||
</InputGroupText>
|
||||
<Input
|
||||
type="text"
|
||||
placeholder="Search Judul..."
|
||||
placeholder="Search Title..."
|
||||
className="bg-transparent dark:border-secondary dark:placeholder-white/80 dark:focus:border-secondary dark:text-white"
|
||||
value={search}
|
||||
onChange={handleSearch}
|
||||
|
|
@ -179,14 +201,20 @@ const PressReleaseTable = () => {
|
|||
>
|
||||
{row.getVisibleCells().map((cell) => (
|
||||
<TableCell key={cell.id}>
|
||||
{flexRender(cell.column.columnDef.cell, cell.getContext())}
|
||||
{flexRender(
|
||||
cell.column.columnDef.cell,
|
||||
cell.getContext()
|
||||
)}
|
||||
</TableCell>
|
||||
))}
|
||||
</TableRow>
|
||||
))
|
||||
) : (
|
||||
<TableRow>
|
||||
<TableCell colSpan={columns.length} className="h-24 text-center">
|
||||
<TableCell
|
||||
colSpan={columns.length}
|
||||
className="h-24 text-center"
|
||||
>
|
||||
No results.
|
||||
</TableCell>
|
||||
</TableRow>
|
||||
|
|
@ -199,6 +227,8 @@ const PressReleaseTable = () => {
|
|||
totalPage={totalPage}
|
||||
/>
|
||||
</div>
|
||||
\{" "}
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -11,23 +11,6 @@ const PressReleasePage = async () => {
|
|||
<SiteBreadcrumb />
|
||||
<div className="space-y-4">
|
||||
<Card>
|
||||
<CardHeader className="border-b border-solid border-default-200 mb-6">
|
||||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
Jadwal Pers Rilis
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/schedule/press-release/create"}>
|
||||
<Button color="primary" className="text-white">
|
||||
<UploadIcon />
|
||||
Buat Jadwal
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent className="p-0">
|
||||
<PressReleaseTable />
|
||||
</CardContent>
|
||||
|
|
|
|||
|
|
@ -55,11 +55,12 @@ import columns from "./columns";
|
|||
import { listTask } from "@/service/task";
|
||||
import { Label } from "@/components/ui/label";
|
||||
import { format } from "date-fns";
|
||||
import { useTranslations } from "next-intl";
|
||||
|
||||
const TaskTable = () => {
|
||||
const router = useRouter();
|
||||
const searchParams = useSearchParams();
|
||||
|
||||
const t = useTranslations("AnalyticsDashboard");
|
||||
const [dataTable, setDataTable] = React.useState<any[]>([]);
|
||||
const [totalData, setTotalData] = React.useState<number>(1);
|
||||
const [sorting, setSorting] = React.useState<SortingState>([]);
|
||||
|
|
@ -205,7 +206,7 @@ const TaskTable = () => {
|
|||
}
|
||||
px-[18px] py-1 transition duration-100 rounded`}
|
||||
>
|
||||
Atensi Khusus
|
||||
{t("special-attention")}
|
||||
</span>
|
||||
<span
|
||||
className={`
|
||||
|
|
@ -217,7 +218,7 @@ const TaskTable = () => {
|
|||
px-[18px] py-1 transition duration-100 rounded
|
||||
`}
|
||||
>
|
||||
Tugas Harian
|
||||
{t("daily-tasks")}
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
|
|
@ -232,7 +233,7 @@ const TaskTable = () => {
|
|||
</InputGroupText>
|
||||
<Input
|
||||
type="text"
|
||||
placeholder="Search Judul dan Code"
|
||||
placeholder="Search Title dan Code"
|
||||
className="bg-transparent dark:border-secondary dark:placeholder-white/80 dark:focus:border-secondary dark:text-white w-full"
|
||||
value={search}
|
||||
onChange={handleSearch}
|
||||
|
|
@ -260,7 +261,7 @@ const TaskTable = () => {
|
|||
<p>Filter</p>
|
||||
</div>
|
||||
<div className="mx-2 my-1">
|
||||
<Label>Tanggal Awal</Label>
|
||||
<Label>{t("date")}</Label>
|
||||
<Input
|
||||
type="date"
|
||||
value={dateFilter}
|
||||
|
|
@ -287,7 +288,7 @@ const TaskTable = () => {
|
|||
onChange={() => handleStatusCheckboxChange(1)}
|
||||
/>
|
||||
<label htmlFor="status-1" className="text-sm">
|
||||
Selesai
|
||||
{t("done")}
|
||||
</label>
|
||||
</div>
|
||||
<div className="flex items-center px-4 py-1">
|
||||
|
|
@ -299,7 +300,7 @@ const TaskTable = () => {
|
|||
onChange={() => handleStatusCheckboxChange(2)}
|
||||
/>
|
||||
<label htmlFor="status-2" className="text-sm">
|
||||
Aktif
|
||||
{t("active")}
|
||||
</label>
|
||||
</div>
|
||||
</DropdownMenuContent>
|
||||
|
|
|
|||
|
|
@ -7,8 +7,10 @@ import SiteBreadcrumb from "@/components/site-breadcrumb";
|
|||
import { Link } from "@/components/navigation";
|
||||
import { checkAuthorization, checkLoginSession } from "@/lib/utils";
|
||||
import React, { useEffect } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
|
||||
const TaskPage = () => {
|
||||
const t = useTranslations("AnalyticsDashboard");
|
||||
useEffect(() => {
|
||||
function initState() {
|
||||
checkAuthorization("admin"); // Specify the page, e.g., "admin" or another value
|
||||
|
|
@ -27,13 +29,13 @@ const TaskPage = () => {
|
|||
<CardTitle>
|
||||
<div className="flex flex-col sm:flex-row lg:flex-row lg:items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
Tabel Penugasan
|
||||
{t("tabel")} {t("task")}
|
||||
</div>
|
||||
<div className="flex-none">
|
||||
<Link href={"/contributor/task/create"}>
|
||||
<Button color="primary" className="text-white">
|
||||
<UploadIcon />
|
||||
Buat Penugasan
|
||||
{t("create-task")}
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -174,7 +174,7 @@ const InternalTable = () => {
|
|||
</InputGroupText>
|
||||
<Input
|
||||
type="text"
|
||||
placeholder="Search Judul..."
|
||||
placeholder="Search Title..."
|
||||
className="bg-transparent dark:border-secondary dark:placeholder-white/80 dark:focus:border-secondary dark:text-white"
|
||||
value={search}
|
||||
onChange={(e) => setSearch(e.target.value)}
|
||||
|
|
|
|||
|
|
@ -10,9 +10,11 @@ import { Link, useRouter } from "@/i18n/routing";
|
|||
import { PlusIcon } from "lucide-react";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import InternalTable from "./internal/components/internal-table";
|
||||
import { useTranslations } from "next-intl";
|
||||
|
||||
const CommunicationPage = () => {
|
||||
const [tab, setTab] = useState("Pertanyaan Internal");
|
||||
const t = useTranslations("Communication");
|
||||
return (
|
||||
<div>
|
||||
<SiteBreadcrumb />
|
||||
|
|
@ -23,7 +25,7 @@ const CommunicationPage = () => {
|
|||
<Link href="/shared/communication/internal/create">
|
||||
<Button color="primary" size="md">
|
||||
<PlusIcon />
|
||||
Pertanyaan baru
|
||||
{t("new-question")}
|
||||
</Button>
|
||||
</Link>
|
||||
)}
|
||||
|
|
@ -31,7 +33,7 @@ const CommunicationPage = () => {
|
|||
<Link href="/shared/communication/collaboration/create">
|
||||
<Button color="primary" size="md">
|
||||
<PlusIcon />
|
||||
Kolaborasi baru
|
||||
{t("new-collaboration")}
|
||||
</Button>
|
||||
</Link>
|
||||
)}
|
||||
|
|
@ -47,7 +49,7 @@ const CommunicationPage = () => {
|
|||
: "bg-white text-black "
|
||||
}`}
|
||||
>
|
||||
Pertanyaan Internal
|
||||
{t("internal-questions")}
|
||||
</Button>
|
||||
<Button
|
||||
rounded="md"
|
||||
|
|
@ -59,7 +61,7 @@ const CommunicationPage = () => {
|
|||
: "bg-white text-black "
|
||||
}`}
|
||||
>
|
||||
Eskalasi
|
||||
{t("escalation")}
|
||||
</Button>
|
||||
<Button
|
||||
rounded="md"
|
||||
|
|
@ -71,7 +73,7 @@ const CommunicationPage = () => {
|
|||
: "bg-white text-black "
|
||||
}`}
|
||||
>
|
||||
Kolaborasi
|
||||
{t("collaboration")}
|
||||
</Button>
|
||||
</div>
|
||||
{tab === "Pertanyaan Internal" && <InternalTable />}
|
||||
|
|
|
|||
|
|
@ -8,10 +8,11 @@ import { Button } from "@/components/ui/button";
|
|||
import { UploadIcon } from "lucide-react";
|
||||
import { getCookiesDecrypt } from "@/lib/utils";
|
||||
import { useEffect, useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
|
||||
const ContestPage = () => {
|
||||
const [userLevelId, setUserLevelId] = useState<any>(null);
|
||||
|
||||
const t = useTranslations("Contest");
|
||||
useEffect(() => {
|
||||
setUserLevelId(Number(getCookiesDecrypt("ulie")));
|
||||
}, []);
|
||||
|
|
@ -24,14 +25,14 @@ const ContestPage = () => {
|
|||
<CardTitle>
|
||||
<div className="flex items-center">
|
||||
<div className="flex-1 text-xl font-medium text-default-900">
|
||||
Tabel Lomba
|
||||
{t("table")} {t("contest")}
|
||||
</div>
|
||||
{userLevelId !== 776 && userLevelId !== null && (
|
||||
<div className="flex-none">
|
||||
<Link href={"/shared/contest/create"}>
|
||||
<Button color="primary" className="text-white">
|
||||
<UploadIcon />
|
||||
Buat Lomba
|
||||
{t("create-contest")}
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -1547,10 +1547,22 @@ export default function FormTaskDetail() {
|
|||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{uploadResults.map((item) => (
|
||||
{uploadResults.map((item: any) => (
|
||||
<tr key={item.id} className="border-b">
|
||||
<td className="px-4 py-2 text-blue-500">
|
||||
<a href="">{item.title}</a>
|
||||
<Link
|
||||
href={
|
||||
Number(item?.fileType?.id) == 1
|
||||
? `/contributor/content/image/detail/${item?.id}`
|
||||
: Number(item?.fileType?.id) == 2
|
||||
? `/contributor/content/video/detail/${item?.id}`
|
||||
: Number(item?.fileType?.id) == 3
|
||||
? `/contributor/content/teks/detail/${item?.id}`
|
||||
: `/contributor/content/audio/detail/${item?.id}`
|
||||
}
|
||||
>
|
||||
{item.title}
|
||||
</Link>
|
||||
</td>
|
||||
<td className="px-4 py-2">{item.fileType.name}</td>
|
||||
<td className="px-4 py-2">{item.category.name}</td>
|
||||
|
|
|
|||
|
|
@ -181,7 +181,7 @@ export function getMenuList(pathname: string, t: any): Group[] {
|
|||
submenus: [
|
||||
{
|
||||
href: "/contributor/schedule/press-conference",
|
||||
label: "konferensi pers",
|
||||
label: t("press-conference"),
|
||||
active: pathname.includes("/schedule/press-conference"),
|
||||
icon: "heroicons:arrow-trending-up",
|
||||
children: [],
|
||||
|
|
@ -195,7 +195,7 @@ export function getMenuList(pathname: string, t: any): Group[] {
|
|||
},
|
||||
{
|
||||
href: "/contributor/schedule/press-release",
|
||||
label: "pers rilis",
|
||||
label: t("press-release"),
|
||||
active: pathname.includes("/schedule/press-release"),
|
||||
icon: "heroicons:shopping-cart",
|
||||
children: [],
|
||||
|
|
|
|||
|
|
@ -36,6 +36,12 @@
|
|||
"create-video": "Create Video",
|
||||
"create-text": "Create Teks",
|
||||
"create-audio": "Create Audio",
|
||||
"create-task": "Create Task",
|
||||
"special-attention": "special attention",
|
||||
"daily-tasks": "Daily Tasks",
|
||||
"date": "Date",
|
||||
"active": "Active",
|
||||
"done": "Done",
|
||||
"image": "Image",
|
||||
"video": "Video",
|
||||
"audio": "Audio",
|
||||
|
|
@ -128,7 +134,9 @@
|
|||
"addEvent": "Add New Agenda",
|
||||
"shortDesc": "Drag and drop your event or click in the calendar",
|
||||
"filter": "FILTER",
|
||||
"no-data-yet": "Not data yet"
|
||||
"no-data-yet": "Not data yet",
|
||||
"bag-pa-monitoring-results": "BAG PA monitoring results",
|
||||
"monitoring-results": "Monitoring Results"
|
||||
},
|
||||
"TodoApp": {
|
||||
"addTask": "Add Task",
|
||||
|
|
@ -153,6 +161,8 @@
|
|||
"task": "Task",
|
||||
"planning": "Planning",
|
||||
"schedule": "Schedule",
|
||||
"press-conference": "Press Conference",
|
||||
"press-release": "press release",
|
||||
"curated-content": "Curated Content",
|
||||
"communication": "Communication",
|
||||
"contest": "Contest",
|
||||
|
|
@ -565,5 +575,29 @@
|
|||
"Planning": {
|
||||
"planning": "Planning",
|
||||
"channel": "Channel"
|
||||
},
|
||||
"Schedule": {
|
||||
"schedule": "Schedule",
|
||||
"press-conference": "Press Conference",
|
||||
"press-release": "Press Release",
|
||||
"create-schedule": "Create Schedule"
|
||||
},
|
||||
"Blog": {
|
||||
"table": "Table",
|
||||
"blog": "Blog",
|
||||
"create-indeks": "Add Blog",
|
||||
"category": "Category"
|
||||
},
|
||||
"Communication": {
|
||||
"internal-questions": "Internal Question",
|
||||
"escalation": "Escalation",
|
||||
"collaboration": "Collaboration",
|
||||
"new-question": "New Question",
|
||||
"new-collaboration": "New Collaboration"
|
||||
},
|
||||
"Contest": {
|
||||
"table": "Table",
|
||||
"contest": "Lomba",
|
||||
"create-contest": "Create Contest"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,6 +37,12 @@
|
|||
"create-video": "Unggah Video",
|
||||
"create-text": "Unggah Teks",
|
||||
"create-audio": "Unggah Audio",
|
||||
"create-task": "Buat Penugasan",
|
||||
"special-attention": "Atensi Khusus",
|
||||
"daily-tasks": "Tugas Khusus",
|
||||
"date": "Tanggal",
|
||||
"active": "Aktif",
|
||||
"done": "Selesai",
|
||||
"image": "Image",
|
||||
"video": "Video",
|
||||
"audio": "Audio",
|
||||
|
|
@ -129,7 +135,9 @@
|
|||
"addEvent": "Tambah Agenda Baru",
|
||||
"shortDesc": "Drag and drop your event or click in the calendar",
|
||||
"filter": "FILTER",
|
||||
"no-data-yet": "Belum ada Data"
|
||||
"no-data-yet": "Belum ada Data",
|
||||
"bag-pa-monitoring-results": "Hasil Pantauan BAG PA",
|
||||
"monitoring-results": "Hasil Pantauan"
|
||||
},
|
||||
"TodoApp": {
|
||||
"addTask": "Add Task",
|
||||
|
|
@ -154,6 +162,8 @@
|
|||
"task": "Penugasan",
|
||||
"planning": "Perencanaan",
|
||||
"schedule": "Jadwal",
|
||||
"press-conference": "Konferensi Pers",
|
||||
"press-release": "Pers Rilis",
|
||||
"curated-content": "Kurasi Konten",
|
||||
"communication": "Komunikasi",
|
||||
"contest": "Lomba",
|
||||
|
|
@ -566,5 +576,29 @@
|
|||
"Planning": {
|
||||
"planning": "Perencanaan",
|
||||
"channel": "Kanal"
|
||||
},
|
||||
"Schedule": {
|
||||
"schedule": "Jadwal",
|
||||
"press-conference": "Konferensi Pers",
|
||||
"press-release": "Pers Rilis",
|
||||
"create-schedule": "Buat Jadwal"
|
||||
},
|
||||
"Blog": {
|
||||
"table": "Tabel",
|
||||
"blog": "Indeks",
|
||||
"create-indeks": "Tambah Indeks",
|
||||
"category": "Kategori"
|
||||
},
|
||||
"Communication": {
|
||||
"internal-questions": "Pertanyaan Internal",
|
||||
"escalation": "Eskalasi",
|
||||
"collaboration": "Kolaborasi",
|
||||
"new-question": "Pertanyaan Baru",
|
||||
"new-collaboration": "Kolaborasi Baru"
|
||||
},
|
||||
"Contest": {
|
||||
"table": "Tabel",
|
||||
"contest": "Lomba",
|
||||
"create-contest": "Buat Lomba"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue