From fd02b2120f89fb4ac7129ef8bb281727a8d2bd4f Mon Sep 17 00:00:00 2001 From: Bowen Zhu <43287170+bowenzhu1@users.noreply.github.com> Date: Tue, 27 Dec 2022 17:44:08 -0500 Subject: [PATCH] add placeholders --- frontend/src/APIClients/CamperAPIClient.ts | 7 ++++--- .../pages/RegistrantExperience/Waiver/index.tsx | 9 ++++++--- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/frontend/src/APIClients/CamperAPIClient.ts b/frontend/src/APIClients/CamperAPIClient.ts index 7c9a1dbd..0d24d46a 100644 --- a/frontend/src/APIClients/CamperAPIClient.ts +++ b/frontend/src/APIClients/CamperAPIClient.ts @@ -93,8 +93,9 @@ const deleteMultipleCampersById = async (ids: string[]): Promise => { } }; -const sendWaiverEmail = async ( - waiverContent: HTMLElement, +/* TODO: take pdf logic and move to /campers/register call +const sendConfirmationEmails = async ( + waiverContent: string, ): Promise => { try { const waiverPdf = new JsPDF("portrait", "pt", "a4"); @@ -115,6 +116,7 @@ const sendWaiverEmail = async ( return false; } } +*/ const getCampersByChargeIdAndSessionId = async ( chargeId: string, @@ -138,7 +140,6 @@ export default { updateCamperRegistrationStatus, deleteWaitlistedCamperById, updateCampersById, - sendWaiverEmail, getCampersByChargeIdAndSessionId, deleteMultipleCampersById, }; diff --git a/frontend/src/components/pages/RegistrantExperience/Waiver/index.tsx b/frontend/src/components/pages/RegistrantExperience/Waiver/index.tsx index e5bc09ee..31d43266 100644 --- a/frontend/src/components/pages/RegistrantExperience/Waiver/index.tsx +++ b/frontend/src/components/pages/RegistrantExperience/Waiver/index.tsx @@ -63,6 +63,12 @@ const WaiverPage = ({ waiverDispatch, campName, }: WaiverPageProps): React.ReactElement => { + /* TODO: store waiver content (html) string to be used in future steps + const sendEmail = async () => { + const waiver = document.getElementById("waiver")?.outerHTML; + await CamperAPIClient.sendConfirmationEmail(waiver); + } + */ return ( @@ -229,9 +235,6 @@ const WaiverPage = ({ /> - ); };