mirror of
https://github.com/YunoHost/tartiflette.git
synced 2024-09-03 20:06:08 +02:00
Forgot to add applist news template
This commit is contained in:
parent
a1b172ee09
commit
966d10e088
2 changed files with 44 additions and 1 deletions
|
@ -152,7 +152,7 @@ def appsobservatory_history():
|
|||
@main.route('/appsobservatory/news')
|
||||
def appsobservatory_news():
|
||||
news_per_date = json.loads(open("./app/scripts/appListsHistory/news.json").read())
|
||||
return render_template('applist_news.html', news_per_date=reversed(news_per_date.items()))
|
||||
return render_template('applist_news.html', news_per_date=list(reversed(list(news_per_date.items()))))
|
||||
|
||||
|
||||
@main.route('/appsobservatory/unlisted')
|
||||
|
|
43
app/templates/applist_news.html
Normal file
43
app/templates/applist_news.html
Normal file
|
@ -0,0 +1,43 @@
|
|||
{% extends "base.html" %}
|
||||
{% block content %}
|
||||
|
||||
<div class="row">
|
||||
<div class="col-10 offset-1">
|
||||
|
||||
{% for date, news in news_per_date %}
|
||||
|
||||
<h2>{{ date }}</h2>
|
||||
|
||||
<ul>
|
||||
{% for app, url in news["added"] %}
|
||||
<li>
|
||||
<span class="badge bg-primary" style="color: white;"><i class="oi oi-plus pr-1" aria-hidden="true"></i>Added</span>
|
||||
<a href="{{url}}">{{app}}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
{% for app, url in news["repaired"] %}
|
||||
<li>
|
||||
<span class="badge bg-success" style="color: white;"><i class="oi oi-circle-check pr-1" aria-hidden="true"></i>Repaired</span>
|
||||
<a href="{{url}}">{{app}}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
{% for app, url in news["broke"] %}
|
||||
<li>
|
||||
<span class="badge bg-warning" style="color: white;"><i class="oi oi-warning pr-1" aria-hidden="true"></i>Broke</span>
|
||||
<a href="{{url}}">{{app}}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
{% for app, url in news["removed"] %}
|
||||
<li>
|
||||
<span class="badge bg-danger" style="color: white;"><i class="oi oi-circle-x pr-1" aria-hidden="true"></i>Removed</span>
|
||||
<a href="{{url}}">{{app}}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
|
||||
{% endfor %}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
Loading…
Reference in a new issue