FreedomBox/plinth/modules/ikiwiki/templates/ikiwiki_configure.html
Sunil Mohan Adapa f509dc54c1
ikiwiki: Remove extra create button when no wiki/blog is present
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2019-10-20 11:54:13 -04:00

64 lines
2.0 KiB
HTML

{% extends "app.html" %}
{% comment %}
#
# This file is part of FreedomBox.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
{% endcomment %}
{% load bootstrap %}
{% load i18n %}
{% block status %}
<a href="{% url 'ikiwiki:create' %}" class="btn btn-primary"
role="button" title="{% trans 'Create Wiki or Blog' %}">
<span class="fa fa-plus" aria-hidden="true"></span>
{% trans 'Create Wiki or Blog' %}
</a>
{% endblock %}
{% block configuration %}
{{ block.super }}
<h3>{% trans "Manage Wikis and Blogs" %}</h3>
<div class="row">
<div class="col-sm-6">
{% if not sites %}
<p>{% trans "No wikis or blogs available." %}</p>
{% else %}
<div class="list-group">
{% for site in sites %}
<div class="list-group-item clearfix">
<a href="{% url 'ikiwiki:delete' site.0 %}"
class="btn btn-default btn-sm pull-right"
role="button"
title="{% blocktrans with site=site.1 %}Delete site {{ site }}{% endblocktrans %}">
<span class="fa fa-trash-o"
aria-hidden="true"></span>
</a>
<a class="wiki-label" href="/ikiwiki/{{ site.0 }}"
title="{% blocktrans with site=site.1 %}Go to site {{ site }}{% endblocktrans %}">
{{ site.1 }}
</a>
</div>
{% endfor %}
</div>
{% endif %}
</div>
</div>
{% endblock %}