diff --git a/src/changes_resource.rs b/src/changes_resource.rs index 1befd1a..af4936f 100644 --- a/src/changes_resource.rs +++ b/src/changes_resource.rs @@ -37,14 +37,14 @@ impl Resource for ChangesResource { use chrono::{TimeZone, Local}; struct Row { - article_id: i32, - revision: i32, + _article_id: i32, + _revision: i32, created: String, slug: String, title: String, - latest: bool, + _latest: bool, } #[derive(BartDisplay)] @@ -62,12 +62,12 @@ impl Resource for ChangesResource { let changes = &data.into_iter().map(|x| { Row { - article_id: x.article_id, - revision: x.revision, - created: Local.from_utc_datetime(&x.created).to_string(), + _article_id: x.article_id, + _revision: x.revision, + created: Local.from_utc_datetime(&x.created).to_rfc2822(), slug: x.slug, title: x.title, - latest: x.latest, + _latest: x.latest, } }).collect::>(); diff --git a/templates/changes.html b/templates/changes.html index 1ee0698..1742877 100644 --- a/templates/changes.html +++ b/templates/changes.html @@ -6,22 +6,12 @@
- - - - - + + {{#changes}} - - - - + {{/changes}}
TitleSlugArticle IDRevisionCreatedArticleUpdated
- {{#.latest?}}{{/.latest}} - {{.title}} - {{#.latest?}}{{/.latest}} - {{#.slug.is_empty()?}}/{{/.slug.is_empty()}}{{.slug}}{{.article_id}}{{.revision}}{{.title}} {{.created}}