mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-11-29 08:25:10 +00:00
frontpage: Show Configure button in service details
Only show when user is logged in.
This commit is contained in:
1 parent
9ca42fd271
commit
8f147e4c7f
10 files changed
+48
-14
No files matched your search
@@ -51,6 +51,8 @@ description = [
|
||||
'is needed.'), box_name=_(cfg.box_name)),
|
||||
]
|
||||
|
||||
configure_url = _('apps/minetest')
|
||||
|
||||
|
||||
def init():
|
||||
"""Initialize the module."""
|
||||
@@ -75,7 +77,8 @@ def setup(helper, old_version=None):
|
||||
|
||||
def add_shortcut():
|
||||
frontpage.add_shortcut('minetest', title, None, 'glyphicon-th-large',
|
||||
description, login_required=False)
|
||||
description, configure_url,
|
||||
login_required=False)
|
||||
|
||||
|
||||
def enable():
|
||||
|
||||
@@ -51,6 +51,9 @@ description = [
|
||||
]
|
||||
|
||||
|
||||
configure_url = _('apps/mumble')
|
||||
|
||||
|
||||
def init():
|
||||
"""Intialize the Mumble module."""
|
||||
menu = cfg.main_menu.get('apps:index')
|
||||
@@ -80,7 +83,8 @@ def setup(helper, old_version=None):
|
||||
|
||||
def add_shortcut():
|
||||
frontpage.add_shortcut('mumble', title, None, 'glyphicon-headphones',
|
||||
description, login_required=False)
|
||||
description, configure_url,
|
||||
login_required=False)
|
||||
|
||||
|
||||
def enable():
|
||||
|
||||
@@ -54,9 +54,12 @@ description = [
|
||||
'While using Privoxy, you can see its configuration details and '
|
||||
'documentation at '
|
||||
'<a href="http://config.privoxy.org">http://config.privoxy.org/</a> '
|
||||
'or <a href="http://p.p">http://p.p</a>.'), box_name=_(cfg.box_name))
|
||||
'or <a href="http://p.p">http://p.p</a>.'),
|
||||
box_name=_(cfg.box_name)),
|
||||
]
|
||||
|
||||
configure_url = _('apps/privoxy')
|
||||
|
||||
service = None
|
||||
|
||||
|
||||
@@ -84,7 +87,8 @@ def setup(helper, old_version=None):
|
||||
|
||||
def add_shortcut():
|
||||
frontpage.add_shortcut('privoxy', title, None, 'glyphicon-cloud-upload',
|
||||
description, login_required=True)
|
||||
description, configure_url,
|
||||
login_required=True)
|
||||
|
||||
|
||||
def enable():
|
||||
|
||||
@@ -55,9 +55,11 @@ description = [
|
||||
'4242. Clients to connect to Quassel from your '
|
||||
'<a href="http://quassel-irc.org/downloads">desktop</a> and '
|
||||
'<a href="http://quasseldroid.iskrembilen.com/">mobile</a> devices '
|
||||
'are available.')
|
||||
'are available.'),
|
||||
]
|
||||
|
||||
configure_url = _('apps/quassel')
|
||||
|
||||
|
||||
def init():
|
||||
"""Initialize the quassel module."""
|
||||
@@ -88,7 +90,8 @@ def setup(helper, old_version=None):
|
||||
|
||||
def add_shortcut():
|
||||
frontpage.add_shortcut('quassel', title, None, 'glyphicon-retweet',
|
||||
description, login_required=True)
|
||||
description, configure_url,
|
||||
login_required=True)
|
||||
|
||||
|
||||
def enable():
|
||||
|
||||
@@ -51,6 +51,8 @@ description = [
|
||||
'login.'), box_name=_(cfg.box_name)),
|
||||
]
|
||||
|
||||
configure_url = _('apps/radicale')
|
||||
|
||||
CONFIG_FILE = '/etc/radicale/config'
|
||||
|
||||
|
||||
@@ -78,7 +80,8 @@ def setup(helper, old_version=None):
|
||||
|
||||
def add_shortcut():
|
||||
frontpage.add_shortcut('radicale', title, None, 'glyphicon-calendar',
|
||||
description, login_required=True)
|
||||
description, configure_url,
|
||||
login_required=True)
|
||||
|
||||
|
||||
def enable():
|
||||
|
||||
@@ -59,6 +59,8 @@ description = [
|
||||
'service and re-enable it.'),
|
||||
]
|
||||
|
||||
configure_url = _('apps/repro')
|
||||
|
||||
service = None
|
||||
|
||||
|
||||
@@ -92,7 +94,8 @@ def setup(helper, old_version=None):
|
||||
|
||||
def add_shortcut():
|
||||
frontpage.add_shortcut('repro', title, None, 'glyphicon-phone-alt',
|
||||
description, login_required=True)
|
||||
description, configure_url,
|
||||
login_required=True)
|
||||
|
||||
|
||||
def enable():
|
||||
|
||||
@@ -49,9 +49,11 @@ description = [
|
||||
|
||||
_('To actually communicate, you can use the web client or any other '
|
||||
'<a href=\'http://xmpp.org/xmpp-software/clients/\' target=\'_blank\''
|
||||
'>XMPP client</a>.')
|
||||
'>XMPP client</a>.'),
|
||||
]
|
||||
|
||||
configure_url = _('apps/xmpp')
|
||||
|
||||
service = None
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
@@ -92,9 +94,10 @@ def setup(helper, old_version=None):
|
||||
def add_shortcut():
|
||||
frontpage.add_shortcut('jsxc', _('Chat Client (jsxc)'),
|
||||
reverse_lazy('xmpp:jsxc'), 'glyphicon-comment',
|
||||
login_required=True)
|
||||
None, login_required=True)
|
||||
frontpage.add_shortcut('xmpp', title, None, 'glyphicon-comment',
|
||||
description, login_required=True)
|
||||
description, configure_url,
|
||||
login_required=True)
|
||||
|
||||
|
||||
def is_enabled():
|
||||
|
||||
Reference in new issue
Block a user