summaryrefslogtreecommitdiff
path: root/src/works
diff options
context:
space:
mode:
Diffstat (limited to 'src/works')
-rw-r--r--src/works/mod.rs3
-rw-r--r--src/works/stories.rs10
2 files changed, 12 insertions, 1 deletions
diff --git a/src/works/mod.rs b/src/works/mod.rs
index 6cb9331..1d0b3de 100644
--- a/src/works/mod.rs
+++ b/src/works/mod.rs
@@ -21,6 +21,9 @@ pub trait Works: for<'a> Deserialize<'a> + Serialize {
Ok(context)
}
+ // render page for every work
+ fn render_single_pages(&self, tera_instance: &tera::Tera, template_name: &str) -> Result<()>;
+
// render corresponding overview HTML template
// with its tera context
fn render_overview_page(
diff --git a/src/works/stories.rs b/src/works/stories.rs
index 4620553..c68745a 100644
--- a/src/works/stories.rs
+++ b/src/works/stories.rs
@@ -18,7 +18,15 @@ pub struct Story {
}
// see src/works/mod.rs for information of Works trait
-impl super::Works for Stories {}
+impl super::Works for Stories {
+ fn render_single_pages(
+ &self,
+ tera_instance: &tera::Tera,
+ template_name: &str,
+ ) -> anyhow::Result<()> {
+ !unimplemented!()
+ }
+}
// language of story content
#[derive(Deserialize, Serialize, Debug)]