feat: tambah dependensi 'jose' versi 5.9.2 pada package.json

refactor: rapikan identasi dan buat field 'expires' opsional di model UserSession pada schema prisma

chore: bersihkan import tidak terpakai di route login dan register API
This commit is contained in:
2024-09-18 14:39:39 +08:00
parent 2ccbca6566
commit 6ee43ed20f
83 changed files with 794 additions and 273 deletions

View File

@@ -1,3 +1,4 @@
import { CheckCookies_UiView } from "@/app_modules/check_cookies";
import { Event_DetailMain } from "@/app_modules/event";
import { Event_countTotalPesertaById } from "@/app_modules/event/fun/count/count_total_peserta_by_id";
import { Event_CekUserJoinById } from "@/app_modules/event/fun/get/cek_user_join_by_id";
@@ -7,11 +8,13 @@ import { user_funGetOneUserId } from "@/app_modules/fun_global/get_user_token";
export default async function Page({ params }: { params: { id: string } }) {
let eventId = params.id;
const userLoginId = await user_funGetOneUserId();
if (!userLoginId) return <CheckCookies_UiView />;
const dataEvent = await Event_getOneById(eventId);
const listPeserta = await Event_getListPesertaById(eventId);
const userLoginId = await user_funGetOneUserId();
const isJoin = await Event_CekUserJoinById(eventId, userLoginId);
const totalPeserta = await Event_countTotalPesertaById(eventId)
const totalPeserta = await Event_countTotalPesertaById(eventId);
return (
<>