comparison bns_website/templates/news/news_list.html @ 23:1357c69e887d

- I added a little New badge for posts in the last 3 days. - I added a <div class=""> tag to the news posts to group them within the same Bootstrap CSS alert block. I'm not sure if it's a good idea or not, but it's kind of cool.
author Bob Mourlam <bob.mourlam@gmail.com>
date Mon, 31 Oct 2011 22:08:45 -0500
parents 687af3cb0525
children ced908af601a 6b4e02b8be6b
comparison
equal deleted inserted replaced
22:6cb0d49187ae 23:1357c69e887d
18 {% block content %} 18 {% block content %}
19 {% navbar 'news' %} 19 {% navbar 'news' %}
20 <h1>News</h1> 20 <h1>News</h1>
21 <dl> 21 <dl>
22 {% for news in object_list %} 22 {% for news in object_list %}
23 <dt>{{ news.title }}</a></dt> 23 <div class="alert-message block-message info">
24 <dt><h2>{{ news.title }} {% if news.is_new %}<span class="label success">New</span>{% endif %}</h2>
25 </dt>
24 <dd>{{ news.content|linebreaksbr }}</dd> 26 <dd>{{ news.content|linebreaksbr }}</dd>
27 <p align="right"> <span class="label">{{news.date}}</span></p>
28 </div>
25 <p/> 29 <p/>
26 {% endfor %} 30 {% endfor %}
27 </dl> 31 </dl>
28 32
29 {% endblock %} 33 {% endblock %}