Separate out the short description and app name

Signed-off-by: Prachi <prachi@swecha.net>
Reviewed-by: Joseph Nuthalapati <njoseph@thoughtworks.com>
This commit is contained in:
Prachi authored and Joseph Nuthalpati committed 2017-08-21 11:17:08 +05:30
1 parent f75f9dbab9
commit c8eb714562
60 files changed
+238 -173

No files matched your search

+8 -5
View File
@@ -38,7 +38,9 @@ managed_services = ['matrix-synapse']
managed_packages = ['matrix-synapse']
title = _('Chat Server \n (Matrix Synapse)')
name = _('Matrix Synapse')
short_description = _('Chat Server')
description = [
_('<a href="https://matrix.org/docs/guides/faq.html">Matrix</a> is an new '
@@ -65,13 +67,13 @@ SERVER_NAME_PATH = "/etc/matrix-synapse/conf.d/server_name.yaml"
def init():
"""Initialize the matrix-synapse module."""
menu = main_menu.get('apps')
menu.add_urlname(title, 'glyphicon-comment', 'matrixsynapse:index')
menu.add_urlname(name, 'glyphicon-comment', 'matrixsynapse:index', short_description)
global service
setup_helper = globals()['setup_helper']
if setup_helper.get_state() != 'needs-setup':
service = service_module.Service(
'matrix-synapse', title,
'matrix-synapse', name,
ports=['matrix-synapse-plinth'],
is_external=True, is_enabled=is_enabled, enable=enable,
disable=disable)
@@ -85,7 +87,7 @@ def setup(helper, old_version=None):
global service
if service is None:
service = service_module.Service(
'matrix-synapse', title,
'matrix-synapse', name,
ports=['matrix-synapse-plinth'],
is_external=True, is_enabled=is_enabled, enable=enable,
disable=disable)
@@ -98,7 +100,8 @@ def setup(helper, old_version=None):
def add_shortcut():
"""Add a shortcut to the frontpage."""
frontpage.add_shortcut('matrixsynapse', title, details=description,
frontpage.add_shortcut('matrixsynapse', name, details=description,
short_description=short_description,
configure_url=reverse_lazy('matrixsynapse:index'),
login_required=True)
+1 -1
View File
@@ -48,7 +48,7 @@ class SetupView(FormView):
"""Provide context data to the template."""
context = super().get_context_data(**kwargs)
context['title'] = matrixsynapse.title
context['title'] = matrixsynapse.name
context['description'] = matrixsynapse.description
context['domain_names'] = get_domain_names()