Integrasi API: Admin Event & Event user ui
Fix: Metode konfirmasi pada event menggunakan QR Code Perbaikan file pada: - app/(application)/(user)/event/(tabs)/index.tsx - app/(application)/(user)/event/[id]/confirmation.tsx - app/(application)/(user)/event/[id]/publish.tsx - app/(application)/admin/event/[id]/[status]/index.tsx - app/(application)/admin/event/[id]/reject-input.tsx - app/(application)/admin/event/[status]/status.tsx - service/api-admin/api-admin-event.ts - service/api-client/api-event.ts ### Issue: Belum menyertakan fungsi konfrimasu kehadiran
This commit is contained in:
@@ -47,3 +47,4 @@ export async function apiAdminEventUpdateStatus({
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -138,3 +138,42 @@ export async function apiEventCheckParticipants({
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
|
||||
export async function apiEventGetConfirmation({
|
||||
id,
|
||||
userId,
|
||||
}: {
|
||||
id: string;
|
||||
userId?: string;
|
||||
}) {
|
||||
try {
|
||||
const response = await apiConfig.get(`/mobile/event/${id}/confirmation?userId=${userId}`);
|
||||
return response.data;
|
||||
} catch (error) {
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
|
||||
export async function apiEventConfirmationAction({
|
||||
id,
|
||||
userId,
|
||||
category,
|
||||
}: {
|
||||
id: string;
|
||||
userId?: string;
|
||||
category?: "join_and_confirm" | "confirmation";
|
||||
}) {
|
||||
try {
|
||||
const response = await apiConfig.post(
|
||||
`/mobile/event/${id}/confirmation?category=${category}`,
|
||||
{
|
||||
data: {
|
||||
userId: userId,
|
||||
},
|
||||
}
|
||||
);
|
||||
return response.data;
|
||||
} catch (error) {
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user