From d9ee195590b0846226a2e20948855764985d83e4 Mon Sep 17 00:00:00 2001
From: Scott Idem
Date: Fri, 8 Mar 2024 13:08:54 -0500
Subject: [PATCH] Documentation for what reason?
---
.../10_edit_modal__event_presenter_obj.svelte | 82 +++++++++----------
.../10_edit_modal__sponsorship_obj.svelte | 32 ++++----
src/routes/sponsorships/[slug]/+page.svelte | 12 ++-
3 files changed, 63 insertions(+), 63 deletions(-)
diff --git a/src/routes/events_speakers/10_edit_modal__event_presenter_obj.svelte b/src/routes/events_speakers/10_edit_modal__event_presenter_obj.svelte
index 36eb3b3e..2095ed85 100644
--- a/src/routes/events_speakers/10_edit_modal__event_presenter_obj.svelte
+++ b/src/routes/events_speakers/10_edit_modal__event_presenter_obj.svelte
@@ -64,6 +64,8 @@ let placeholder_li: key_val = {
if ($slct.event_presenter_id) {
console.log(`Presenter ID selected: ${$slct.event_presenter_id}`);
console.log(`Presenter object selected:`, $slct.event_presenter_obj);
+
+ $slct_trigger = 'load__event_presenter_obj';
} else {
$store_current_tab = 'start';
@@ -257,12 +259,17 @@ async function handle_submit_form(event) {
if ($slct.event_presenter_id) {
if ($store_current_tab == 'start' && $slct.event_presenter_id) {
$store_current_tab = 'biograhpy';
+ send_init_confirm_email();
+
} else if ($store_current_tab == 'biograhpy' && $slct.event_presenter_id) {
$store_current_tab = 'files';
} else if ($store_current_tab == 'files' && $slct.event_presenter_id) {
$store_current_tab = 'summary';
}
+ } else {
+ console.log('No obj ID found!');
}
+
}
async function handle_submit_form_files(event) {
@@ -412,6 +419,36 @@ async function handle_update__event_presenter({
return ae_promises.update__event_presenter_obj;
}
+
+function send_init_confirm_email() {
+ let subject = `CHOW 2024 Speaker Hub Link for ${$slct.event_presenter_obj.full_name} (ID: ${$slct.event_presenter_id})`;
+
+ let body_html = `Thank you for your submission to the Speaker Hub. You are an integral part of Capitol Hill Ocean Week and we appreciate your participation. If you need to make any changes or updates to your submission, you may access it via the below hyperlink:
Name: ${$slct.event_presenter_obj.full_name} (Speaker ID: ${$slct.event_presenter_id})
Use this link to view or update your CHOW 2024 speaker information.
Copy and paste link: ${$ae_loc.mod.events.presenter_link}
`
+
+ api.send_email({
+ api_cfg: $ae_api,
+ from_email: 'noreply+chow@oneskyit.com',
+ from_name: 'CHOW 2024 Speaker Hub',
+ to_email: $slct.event_presenter_obj.email,
+ subject: subject,
+ body_html: body_html,
+ });
+}
+
+function send_summary_email() {
+ let subject = `CHOW 2024 Speaker Hub Link for ${$slct.event_presenter_obj.full_name} (ID: ${$slct.event_presenter_id})`;
+
+ let body_html = `Thank you for your submission to the Speaker Hub. You are an integral part of Capitol Hill Ocean Week and we appreciate your participation. If you need to make any changes or updates to your submission, you may access it via the link below.
Name: ${$slct.event_presenter_obj.full_name} (ID: ${$slct.event_presenter_id})
Professional title: ${$slct.event_presenter_obj.professional_title}
Affiliations: ${$slct.event_presenter_obj.affiliations}
Email: ${$slct.event_presenter_obj.email}
Biography:
${$slct.event_presenter_obj.biography} Headshot:
${placeholder_li.image_headshot}
Use this link to view or update your CHOW 2024 speaker information.
Copy and paste link: ${$ae_loc.mod.events.presenter_link}
`
+
+ api.send_email({
+ api_cfg: $ae_api,
+ from_email: 'noreply+chow@oneskyit.com',
+ from_name: 'CHOW 2024 Speaker Hub',
+ to_email: $slct.event_presenter_obj.email,
+ subject: subject,
+ body_html: body_html,
+ });
+}
@@ -465,18 +502,6 @@ async function handle_update__event_presenter({
on:click={() => {
if (!confirm(`Are you sure you want to send this email to ${$slct.event_presenter_obj.email}?`)) {return false;}
- let subject = `CHOW 2024 Speaker Link for ${$slct.event_presenter_obj.full_name} (ID: ${$slct.event_presenter_id})`;
- let body_html = `Name: ${$slct.event_presenter_obj.full_name} (speaker ID: ${$slct.event_presenter_id})
Use this link to view or update your CHOW 2024 speaker information.
Copy and paste link: ${$ae_loc.mod.events.presenter_link}
`
-
- api.send_email({
- api_cfg: $ae_api,
- from_email: 'scott.idem+from@oneskyit.com',
- from_name: 'Scott Idem',
- to_email: $slct.event_presenter_obj.email,
- subject: subject,
- body_html: body_html,
- });
-
}}
>
@@ -694,7 +719,7 @@ async function handle_update__event_presenter({
-->
- Thank you for your submission to the Speaker Hub. You are an integral part of Capitol Hill Ocean Week and we appreciate your participation. If you need to make any changes or updates to your submission, you may access it via the below hyperlink:
Name: ${$slct.event_presenter_obj.full_name} (Speaker ID: ${$slct.event_presenter_id})
Use this link to view or update your CHOW 2024 speaker information.
Copy and paste link: ${$ae_loc.mod.events.presenter_link}
`
-
- api.send_email({
- api_cfg: $ae_api,
- from_email: 'noreply+chow@oneskyit.com',
- from_name: 'CHOW 2024 Speaker Hub',
- to_email: $slct.event_presenter_obj.email,
- subject: subject,
- body_html: body_html,
- });
-
}}
>
Save and email
-
+ -->
{
console.log('*** Save start button clicked ***');
}}
@@ -856,20 +869,7 @@ async function handle_update__event_presenter({
on:click={() => {
if (!confirm(`Are you sure you want to send this email to ${$slct.event_presenter_obj.email}?`)) {return false;}
- let subject = `CHOW 2024 Speaker Hub Link for ${$slct.event_presenter_obj.full_name} (ID: ${$slct.event_presenter_id})`;
- // let body_html = `Name: ${$slct.event_presenter_obj.full_name} (speaker ID: ${$slct.event_presenter_id})
Use this link to view or update your CHOW 2024 speaker information.
Copy and paste link: ${$ae_loc.mod.events.presenter_link}
`
-
- let body_html = `Thank you for your submission to the Speaker Hub. You are an integral part of Capitol Hill Ocean Week and we appreciate your participation. If you need to make any changes or updates to your submission, you may access it via the link below.
Name: ${$slct.event_presenter_obj.full_name} (ID: ${$slct.event_presenter_id})
Professional title: ${$slct.event_presenter_obj.professional_title}
Affiliations: ${$slct.event_presenter_obj.affiliations}
Email: ${$slct.event_presenter_obj.email}
Biography:
${$slct.event_presenter_obj.biography} Headshot:
${placeholder_li.image_headshot}
Use this link to view or update your CHOW 2024 speaker information.
Copy and paste link: ${$ae_loc.mod.events.presenter_link}
`
-
- api.send_email({
- api_cfg: $ae_api,
- from_email: 'noreply+chow@oneskyit.com',
- from_name: 'CHOW 2024 Speaker Hub',
- to_email: $slct.event_presenter_obj.email,
- subject: subject,
- body_html: body_html,
- });
-
+ send_summary_email();
}}
>
diff --git a/src/routes/sponsorships/10_edit_modal__sponsorship_obj.svelte b/src/routes/sponsorships/10_edit_modal__sponsorship_obj.svelte
index a58fdfb2..6d0d2b7e 100644
--- a/src/routes/sponsorships/10_edit_modal__sponsorship_obj.svelte
+++ b/src/routes/sponsorships/10_edit_modal__sponsorship_obj.svelte
@@ -728,9 +728,10 @@ async function handle_update__sponsorship({
}
function send_init_confirm_email() {
+ console.log(`*** send_init_confirm_email() *** to ${$slct.sponsorship_obj.poc_json.email}.`)
let subject = `CHOW 2024 Sponsor Hub Link for ${$slct.sponsorship_obj.name} (ID: ${$slct.sponsorship_id})`;
- let body_html = `Thank you for your submission to the Sponsorships Hub. You are an integral part of Capitol Hill Ocean Week and we appreciate your participation. If you need to make any changes or updates to your submission, you may access it via the below hyperlink:
Name: ${$slct.sponsorship_obj.name} (Sponsor ID: ${$slct.sponsorship_id})
Use this link to view or update your CHOW 2024 speaker information.
Copy and paste link: ${$ae_loc.mod.sponsorships.link}
`
+ let body_html = `Thank you for your submission to the Sponsorship Hub. You are an integral part of Capitol Hill Ocean Week and we appreciate your participation. If you need to make any changes or updates to your submission, you may access it via the below hyperlink:
Name: ${$slct.sponsorship_obj.name} (Sponsor ID: ${$slct.sponsorship_id})
Use this link to view or update your CHOW 2024 speaker information.
Copy and paste link: ${$ae_loc.mod.sponsorships.link}
`
api.send_email({
api_cfg: $ae_api,
@@ -740,7 +741,20 @@ function send_init_confirm_email() {
subject: subject,
body_html: body_html,
});
+}
+function send_confirm_email() {
+ let subject = `CHOW 2024 Sponsor Hub Link for ${$slct.sponsorship_obj.name} (ID: ${$slct.sponsorship_id})`;
+ let body_html = `Thank you for your submission to the Sponsorships Hub. You are an integral part of Capitol Hill Ocean Week and we appreciate your participation. If you need to make any changes or updates to your submission, you may access it via the below hyperlink:
Level: ${$slct.sponsorship_obj.level_str}
Name: ${$slct.sponsorship_obj.name} (Sponsor ID: ${$slct.sponsorship_id})
POC: ${$slct.sponsorship_obj.poc_json.full_name} (${$slct.sponsorship_obj.poc_json.email})
Use this link to view or update your CHOW 2024 sponsorship information.
Copy and paste link: ${$ae_loc.mod.sponsorships.link}
`;
+
+ api.send_email({
+ api_cfg: $ae_api,
+ from_email: 'noreply+chow@oneskyit.com',
+ from_name: 'CHOW 2024 Sponsor Hub',
+ to_email: $slct.sponsorship_obj.poc_json.email,
+ subject: subject,
+ body_html: body_html,
+ });
}
@@ -2300,25 +2314,13 @@ function send_init_confirm_email() {
{
if (!confirm(`Are you sure you want to send this email to ${$slct.sponsorship_obj.poc_json.email}?`)) {return false;}
- let subject = `CHOW 2024 Sponsor Hub Link for ${$slct.sponsorship_obj.name} (ID: ${$slct.sponsorship_id})`;
- let body_html = `Thank you for your submission to the Sponsorships Hub. You are an integral part of Capitol Hill Ocean Week and we appreciate your participation. If you need to make any changes or updates to your submission, you may access it via the below hyperlink:
Level: ${$slct.sponsorship_obj.level_str}
Name: ${$slct.sponsorship_obj.name} (Sponsor ID: ${$slct.sponsorship_id})
POC: ${$slct.sponsorship_obj.poc_json.full_name} (${$slct.sponsorship_obj.poc_json.email})
Use this link to view or update your CHOW 2024 sponsorship information.
Copy and paste link: ${$ae_loc.mod.sponsorships.link}
`;
-
- await api.send_email({
- api_cfg: $ae_api,
- from_email: 'noreply+chow@oneskyit.com',
- from_name: 'CHOW 2024 Sponsor Hub',
- to_email: $slct.sponsorship_obj.poc_json.email,
- subject: subject,
- body_html: body_html,
- });
$ae_sess.mod.sponsorships.submit_status = 'sending email';
-
-
+ send_confirm_email();
}}
>