diff --git a/admin_frontend/src/templates.rs b/admin_frontend/src/templates.rs index de888805..0e392d25 100644 --- a/admin_frontend/src/templates.rs +++ b/admin_frontend/src/templates.rs @@ -18,6 +18,10 @@ pub struct OpenAppFlowyOrDownload {} #[template(path = "pages/login_callback.html")] pub struct LoginCallback {} +#[derive(Template)] +#[template(path = "pages/payment_success_redirect.html")] +pub struct PaymentSuccessRedirect {} + #[derive(Template)] #[template(path = "components/user_usage.html")] pub struct UserUsage { diff --git a/admin_frontend/src/web_app.rs b/admin_frontend/src/web_app.rs index ce502bba..e552facd 100644 --- a/admin_frontend/src/web_app.rs +++ b/admin_frontend/src/web_app.rs @@ -28,6 +28,7 @@ fn page_router() -> Router { .route("/", get(home_handler)) .route("/login", get(login_handler)) .route("/login-callback", get(login_callback_handler)) + .route("/payment-success", get(payment_success_handler)) .route("/login-callback-query", get(login_callback_query_handler)) .route( "/open-appflowy-or-download", @@ -67,6 +68,10 @@ async fn login_callback_handler() -> Result, WebAppError> { render_template(templates::LoginCallback {}) } +async fn payment_success_handler() -> Result, WebAppError> { + render_template(templates::PaymentSuccessRedirect {}) +} + async fn login_callback_query_handler( State(state): State, session: Option, diff --git a/admin_frontend/templates/pages/payment_success_redirect.html b/admin_frontend/templates/pages/payment_success_redirect.html new file mode 100644 index 00000000..89f6aced --- /dev/null +++ b/admin_frontend/templates/pages/payment_success_redirect.html @@ -0,0 +1,10 @@ + + + AppFlowy - Redirecting + + + + +