# Event Join

## feat
- Join event
- History semua event dan event saya
### No Issuue
This commit is contained in:
2024-01-31 10:48:20 +08:00
parent ca9214d9e0
commit c01906c063
40 changed files with 682 additions and 98 deletions

View File

@@ -0,0 +1,14 @@
import { LayoutEvent_DetailRiwayat } from "@/app_modules/event";
import React from "react";
export default async function Layout({
children,
}: {
children: React.ReactNode;
}) {
return (
<>
<LayoutEvent_DetailRiwayat>{children}</LayoutEvent_DetailRiwayat>
</>
);
}

View File

@@ -0,0 +1,24 @@
import { Event_DetailRiwayat } 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";
import { Event_getListPesertaById } from "@/app_modules/event/fun/get/get_list_peserta_by_id";
import { Event_getOneById } from "@/app_modules/event/fun/get/get_one_by_id";
import { User_getUserId } from "@/app_modules/fun_global/get_user_token";
export default async function Page({ params }: { params: { id: string } }) {
let eventId = params.id;
const dataEvent = await Event_getOneById(eventId);
const listPeserta = await Event_getListPesertaById(eventId);
const totalPeserta = await Event_countTotalPesertaById(eventId);
return (
<>
<Event_DetailRiwayat
dataEvent={dataEvent as any}
listPeserta={listPeserta as any}
totalPeserta={totalPeserta as any}
/>
</>
);
}