mirror of
https://github.com/almet/notmyidea.git
synced 2025-04-28 19:42:37 +02:00
group the archives by year
This commit is contained in:
parent
5e8dc92256
commit
8960ec19d1
2 changed files with 17 additions and 8 deletions
|
@ -51,12 +51,17 @@ hr { border: 2px solid #EEEEEE; }
|
|||
/* Anchors */
|
||||
a {outline: 0;}
|
||||
a img {border: 0px; text-decoration: none;}
|
||||
a:link, a:visited {
|
||||
color: #C74350;
|
||||
.body a:link, .body a:visited {
|
||||
border-radius: 5px 5px 5px 5px;
|
||||
padding: 0px 5px;
|
||||
background-color: rgb(234, 234, 234);
|
||||
color: rgb(0, 0, 0);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.entry-content a:hover, .entry-content a:active {
|
||||
color: #000;
|
||||
.body a:hover, .body a:active {
|
||||
color: #fff;
|
||||
background-color: #000;
|
||||
}
|
||||
|
||||
h1 a:link, h1 a:visited { font-size: 1.2em; text-decoration: none; color: #000;, z-index: 10;}
|
||||
|
|
|
@ -1,12 +1,16 @@
|
|||
{% extends "base.html" %}
|
||||
{% block content %}
|
||||
<section id="content" class="body">
|
||||
<h1>Archives for {{ SITENAME }}</h1>
|
||||
<h1>Some archives for this blog</h1>
|
||||
|
||||
<dl>
|
||||
{% for article in dates %}
|
||||
<dt>{{ article.locale_date }}</dt>
|
||||
<dd><a href="{{ article.url }}">{{ article.title }}</a></dd>
|
||||
{% for year in articles|groupby('date.year') %}
|
||||
<dt>{{ year.grouper }}</dt>
|
||||
<dd><ul>
|
||||
{% for article in year.list %}
|
||||
<li><a href="{{ SITEURL }}/{{ article.url }}">{{ article.title }}</a></li>
|
||||
{% endfor %}
|
||||
</ul></dd>
|
||||
{% endfor %}
|
||||
</dl>
|
||||
</section>
|
||||
|
|
Loading…
Reference in a new issue