diff --git a/layouts/shortcodes/camp-form.html b/layouts/shortcodes/camp-form.html index 7bfacaa..5829e17 100644 --- a/layouts/shortcodes/camp-form.html +++ b/layouts/shortcodes/camp-form.html @@ -3,7 +3,7 @@
-
+

Camp Form

diff --git a/resources/_gen/images/staff/chris-and-abbie-cochrun/2024-05/featured_hu33ae59ff71c10f926d425099900983cf_416662_1200x0_resize_q75_box.jpg b/resources/_gen/images/staff/chris-and-abbie-cochrun/2024-05/featured_hu33ae59ff71c10f926d425099900983cf_416662_1200x0_resize_q75_box.jpg deleted file mode 100644 index e3c6135..0000000 Binary files a/resources/_gen/images/staff/chris-and-abbie-cochrun/2024-05/featured_hu33ae59ff71c10f926d425099900983cf_416662_1200x0_resize_q75_box.jpg and /dev/null differ diff --git a/resources/_gen/images/staff/chris-and-abbie-cochrun/2024-05/featured_hu33ae59ff71c10f926d425099900983cf_416662_600x0_resize_q75_box.jpg b/resources/_gen/images/staff/chris-and-abbie-cochrun/2024-05/featured_hu33ae59ff71c10f926d425099900983cf_416662_600x0_resize_q75_box.jpg deleted file mode 100644 index cc212d6..0000000 Binary files a/resources/_gen/images/staff/chris-and-abbie-cochrun/2024-05/featured_hu33ae59ff71c10f926d425099900983cf_416662_600x0_resize_q75_box.jpg and /dev/null differ diff --git a/src/api/camp_form.rs b/src/api/camp_form.rs index 7d3eaad..342da32 100644 --- a/src/api/camp_form.rs +++ b/src/api/camp_form.rs @@ -1,9 +1,7 @@ -use std::fs; - -use actix_multipart::form::{tempfile::TempFile, text::Text, MultipartForm}; +use actix_multipart::form::{text::Text, MultipartForm}; use actix_web::{post, HttpResponse}; use lettre::{ - message::{header::ContentType, Attachment, MultiPart, SinglePart}, + message::MultiPart, transport::smtp::authentication::{Credentials, Mechanism}, Message, SmtpTransport, Transport, }; @@ -35,6 +33,7 @@ struct CampForm { #[post("/camp-form")] pub async fn camp_form(MultipartForm(form): MultipartForm) -> HttpResponse { + log::info!("a new form"); let first = form .first_name .as_ref() @@ -166,6 +165,7 @@ pub async fn camp_form(MultipartForm(form): MultipartForm) -> HttpResp }) .0 .clone(); + let reg = registration.clone().as_str(); log::info!("{first} {last} signed up for camp!"); let email = markup::new! { @markup::doctype() @@ -282,5 +282,19 @@ pub async fn camp_form(MultipartForm(form): MultipartForm) -> HttpResp log::info!("Email incorrect"); } + match reg { + "now" => { + log::info!("Sending them to pay for registration now"); + } + "full" => { + log::info!("Sending them to pay for the full registration now"); + } + "later" => { + log::info!("They'd like to pay later"); + } + _ => { + log::error!("Got registration error....."); + } + } HttpResponse::Ok().body("thankyou") }