add mail for requesting fee
This commit is contained in:
@ -39,6 +39,16 @@ async fn fee(db: &State<SqlitePool>, _admin: AdminUser, config: &State<Config>)
|
||||
"SUCC"
|
||||
}
|
||||
|
||||
#[get("/mail/fee-final")]
|
||||
async fn fee_final(
|
||||
db: &State<SqlitePool>,
|
||||
_admin: AdminUser,
|
||||
config: &State<Config>,
|
||||
) -> &'static str {
|
||||
Mail::fees_final(db, config.smtp_pw.clone()).await;
|
||||
"SUCC"
|
||||
}
|
||||
|
||||
#[derive(FromForm, Debug)]
|
||||
pub struct MailToSend<'a> {
|
||||
pub(crate) role_id: i32,
|
||||
@ -63,7 +73,7 @@ async fn update(
|
||||
}
|
||||
|
||||
pub fn routes() -> Vec<Route> {
|
||||
routes![index, update, fee]
|
||||
routes![index, update, fee, fee_final]
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
Reference in New Issue
Block a user