summaryrefslogtreecommitdiff
path: root/src/pyssg/plt
diff options
context:
space:
mode:
Diffstat (limited to 'src/pyssg/plt')
-rw-r--r--src/pyssg/plt/index.html8
-rw-r--r--src/pyssg/plt/mandatory_config.yaml2
-rw-r--r--src/pyssg/plt/page.html6
-rw-r--r--src/pyssg/plt/tag.html8
4 files changed, 11 insertions, 13 deletions
diff --git a/src/pyssg/plt/index.html b/src/pyssg/plt/index.html
index 96d66ef..c33fd37 100644
--- a/src/pyssg/plt/index.html
+++ b/src/pyssg/plt/index.html
@@ -19,13 +19,13 @@
<ul>
{%for p in all_pages%}
{%if loop.previtem%}
- {%if loop.previtem.cdate_list_sep !=p.cdate_list_sep%}
- <h3>{{p.cdate_list_sep}}</h3>
+ {%if loop.previtem.cdatetime.strftime(config['fmt']['list_sep_date']) != p.cdatetime.strftime(config['fmt']['list_sep_date'])%}
+ <h3>{{p.cdatetime.strftime(config['fmt']['list_sep_date'])}}</h3>
{%endif%}
{%else%}
- <h3>{{p.cdate_list_sep}}</h3>
+ <h3>{{p.cdatetime.strftime(config['fmt']['list_sep_date'])}}</h3>
{%endif%}
- <li>{{p.cdate_list}} - <a href="{{p.url}}">{{p.title}}</a></li>
+ <li>{{p.cdatetime.strftime(config['fmt']['list_date'])}} - <a href="{{p.url}}">{{p.title}}</a></li>
{%endfor%}
</ul>
</body>
diff --git a/src/pyssg/plt/mandatory_config.yaml b/src/pyssg/plt/mandatory_config.yaml
index c1ce9f2..4b4acac 100644
--- a/src/pyssg/plt/mandatory_config.yaml
+++ b/src/pyssg/plt/mandatory_config.yaml
@@ -10,8 +10,6 @@ url:
main:
fmt:
date:
- list_date:
- list_sep_date:
dirs:
/:
...
diff --git a/src/pyssg/plt/page.html b/src/pyssg/plt/page.html
index d7f5e43..08e92f1 100644
--- a/src/pyssg/plt/page.html
+++ b/src/pyssg/plt/page.html
@@ -8,9 +8,9 @@
<body>
<h1>{{page.title}}</h1>
<p>By {{page.author}}</p>
- <p>Created: {{page.cdate}}</p>
- {%if page.mdate is not none%}
- <p>Modified: {{page.mdate}}</p>
+ <p>Created: {{page.cdatetime.strftime(config['fmt']['date'])}}</p>
+ {%if page.mdatetime is not none%}
+ <p>Modified: {{page.mdatetime.strftime(config['fmt']['date'])}}</p>
{%endif%}
{{page.content}}
diff --git a/src/pyssg/plt/tag.html b/src/pyssg/plt/tag.html
index 59cbdf1..2dd7177 100644
--- a/src/pyssg/plt/tag.html
+++ b/src/pyssg/plt/tag.html
@@ -13,13 +13,13 @@
<ul>
{%for p in tag_pages%}
{%if loop.previtem%}
- {%if loop.previtem.cdate_list_sep !=p.cdate_list_sep%}
- <h3>{{p.cdate_list_sep}}</h3>
+ {%if loop.previtem.cdatetime.strftime(config['fmt']['list_sep_date']) != p.cdatetime.strftime(config['fmt']['list_sep_date'])%}
+ <h3>{{p.cdatetime.strftime(config['fmt']['list_sep_date'])}}</h3>
{%endif%}
{%else%}
- <h3>{{p.cdate_list_sep}}</h3>
+ <h3>{{p.cdatetime.strftime(config['fmt']['list_sep_date'])}}</h3>
{%endif%}
- <li>{{p.cdate_list}} - <a href="{{p.url}}">{{p.title}}</a></li>
+ <li>{{p.cdatetime.strftime(config['fmt']['list_date'])}} - <a href="{{p.url}}">{{p.title}}</a></li>
{%endfor%}
</ul>
</body>