mirror of
https://github.com/c0de-archive/pelican-mg.git
synced 2024-12-22 08:22:40 +00:00
Handling optional "date" field in past readings list
This commit is contained in:
parent
5712d577b0
commit
c9c730f727
@ -86,6 +86,7 @@
|
|||||||
updateArticlesVisibility();
|
updateArticlesVisibility();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// This is a bit redundant with /tag/$tag.html pages, but is slightly more powerful as it allow to combine multiple filters
|
||||||
let queryParams = parseQuery(window.location.search);
|
let queryParams = parseQuery(window.location.search);
|
||||||
for (let [qpName, qpValue] of Object.entries(queryParams)) {
|
for (let [qpName, qpValue] of Object.entries(queryParams)) {
|
||||||
if (!qpValue) { continue; }
|
if (!qpValue) { continue; }
|
||||||
|
@ -266,7 +266,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</aside>
|
</aside>
|
||||||
|
|
||||||
<script src="{{SITEURL}}/theme/bundle-SHARE-{{SHARE|string|first|length|string|first}}-MG_FILTER_TAGS-{{MG_FILTER_TAGS|string|first|length|string|first}}-SHORTSHA1-b4c4e94.js"></script>
|
<script src="{{SITEURL}}/theme/bundle-SHARE-{{SHARE|string|first|length|string|first}}-MG_FILTER_TAGS-{{MG_FILTER_TAGS|string|first|length|string|first}}-SHORTSHA1-efddc02.js"></script>
|
||||||
|
|
||||||
{% include 'disqus_count.html' %}
|
{% include 'disqus_count.html' %}
|
||||||
{% include 'analytics.html' %}
|
{% include 'analytics.html' %}
|
||||||
|
4
templates/past_readings.html
Executable file → Normal file
4
templates/past_readings.html
Executable file → Normal file
@ -9,8 +9,8 @@
|
|||||||
<div class="uk-grid">
|
<div class="uk-grid">
|
||||||
{% for reading in READINGS %}
|
{% for reading in READINGS %}
|
||||||
<figure class="uk-width-1-1 uk-width-small-1-2 uk-width-medium-1-3">
|
<figure class="uk-width-1-1 uk-width-small-1-2 uk-width-medium-1-3">
|
||||||
<img class="uk-thumbnail" src="{{ reading['img_url'] }}" alt="{{ reading['description'] }}">
|
<img class="uk-thumbnail" src="{{ reading['img_url'] }}" alt="{{ reading['description']+' '+reading.get('date', '') }}">
|
||||||
<figcaption>{{ reading['description'] }}</figcaption>
|
<figcaption>{{ reading['description']+' '+reading.get('date', '') }}</figcaption>
|
||||||
</figure>
|
</figure>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user