static pages are rendered and cached

This commit is contained in:
realaravinth
2021-05-04 15:45:53 +05:30
parent f817f49182
commit fe02c43c2c
7 changed files with 49 additions and 65 deletions

View File

@@ -20,19 +20,13 @@ use sailfish::TemplateOnce;
#[derive(TemplateOnce, Clone)]
#[template(path = "panel/site-keys/index.html")]
pub struct IndexPage<'a> {
pub name: &'a str,
pub title: &'a str,
}
pub struct IndexPage;
const TITLE: &str = "Add Site Key";
const PAGE: &str = "SiteKeys";
impl<'a> Default for IndexPage<'a> {
impl Default for IndexPage {
fn default() -> Self {
IndexPage {
name: "mCaptcha",
title: TITLE,
}
IndexPage
}
}