add template vars

This commit is contained in:
Jérôme Schneider 2014-08-29 19:17:07 +02:00
parent 13734bcbbe
commit 8002e3c2d0
3 changed files with 11 additions and 2 deletions

View File

@ -99,6 +99,12 @@ static_root = config.get('dirs', 'static_root')
# Data dir
data_dir = config.get('dirs', 'data_dir')
# template vars
template_vars = {}
if config.has_section('template_vars'):
for option in config.options('template_vars'):
template_vars[option] = config.get('template_vars', option)
# Supported authentification
authentifications = {
'saml2': 'mandaye.auth.saml2.SAML2Auth',

View File

@ -32,6 +32,9 @@ encrypt_sp_password: false
; must be a 16, 24, or 32 bytes long
encrypt_secret:
[template_vars]
wcs_url: https://demarches.vincennes.fr
[session]
; file, dbm, memory or memcached
; if memcached you need to install python-memcached and memcached

View File

@ -7,10 +7,10 @@
</a>
</div>
<div class="mandaye_toolbar-cc">
<a href="https://connexion.vincennes.fr/accounts/">
<a href="${wcs_url}">
Compte citoyen
</a>
<a id="demarches" href="https://www.vincennes.fr/Vos-demarches">
<a id="demarches" href="${wcs_url}/Vos-demarches">
Démarches
</a>
</div>