fix: implement requested changes

- pass short_description to header.html include statement in templates/setup.html
- pass description to header.html include statement in
  modules/sharing/templates/sharing.html
- use `[]` instead of `None` for the initial value of description
  property in SetupView (plinth/views.py)
- add license info to header.html

Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
Alice Kile 2019-12-03 15:42:02 +05:30 committed by James Valleroy
parent a9979db56f
commit 52a9673f69
No known key found for this signature in database
GPG Key ID: 77C0C75E7B650808
4 changed files with 22 additions and 3 deletions

View File

@ -33,7 +33,7 @@
{% block content %}
{% include "header.html" with icon_filename=icon_filename name=title description='' %}
{% include "header.html" with icon_filename=icon_filename name=title description=description %}
<p>
<a title="{% trans 'Add share' %}"

View File

@ -1,3 +1,22 @@
{% 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 %}
{% load static %}

View File

@ -36,7 +36,7 @@
{% block content %}
{% include "header.html" with icon_filename=setup_helper.module.icon_filename name=setup_helper.module.name description=setup_helper.module.description manual_page=setup_helper.module.manual_page setup=True %}
{% include "header.html" with icon_filename=setup_helper.module.icon_filename name=setup_helper.module.name description=setup_helper.module.description short_description=setup_helper.module.short_description manual_page=setup_helper.module.manual_page setup=True %}
{% include "toolbar.html" with clients=setup_helper.module.clients %}

View File

@ -211,7 +211,7 @@ class SetupView(TemplateView):
template_name = 'setup.html'
name = 'None'
# List of paragraphs describing the service
description = ""
description = []
def get_context_data(self, **kwargs):
"""Return the context data rendering the template."""