Projet

Général

Profil

0001-hobo-generate-backoffice_extra_head-if-there-s-a-com.patch

Frédéric Péters, 08 juin 2015 16:26

Télécharger (1,3 ko)

Voir les différences:

Subject: [PATCH] hobo: generate backoffice_extra_head if there's a combo for
 agents (#7499)

 wcs/ctl/check_hobos.py | 12 ++++++++++++
 1 file changed, 12 insertions(+)
wcs/ctl/check_hobos.py
274 274
            # Use the first fargo found and stop
275 275
            break
276 276

  
277
        try:
278
            portal_agent_url = config.get('variables', 'portal_agent_url')
279
        except ConfigParser.NoOptionError:
280
            pass
281
        else:
282
            if portal_agent_url.endswith('/'):
283
                portal_agent_url = portal_agent_url.rstrip('/')
284
            extra_head = '''<script src="%s/__services.js"></script>'''\
285
                         '''<script src="%s/static/js/publik.js"></script>''' % (
286
                                 portal_agent_url, portal_agent_url)
287
            config.set('options', 'backoffice_extra_head', extra_head)
288

  
277 289
        with open(site_options_filepath, 'wb') as site_options:
278 290
            config.write(site_options)
279 291

  
280
-