Révision e3abbabb
Ajouté par Frédéric Péters il y a plus de 6 ans
auquotidien/modules/root.py | ||
---|---|---|
808 | 808 |
response.filter = {} |
809 | 809 |
|
810 | 810 |
response.filter['auquotidien'] = True |
811 |
response.filter['gauche'] = self.box_side(path) |
|
812 |
response.filter['keywords'] = template.get_current_theme().get('keywords') |
|
811 |
if not path or path[0] not in ('api', 'backoffice'): |
|
812 |
# api & backoffice have no use for a side box |
|
813 |
response.filter['gauche'] = self.box_side(path) |
|
814 |
response.filter['keywords'] = template.get_current_theme().get('keywords') |
|
813 | 815 |
get_publisher().substitutions.feed(self) |
814 | 816 |
|
815 | 817 |
response.breadcrumb = [ ('', _('Home')) ] |
... | ... | |
1103 | 1105 |
r += htmltext('<input type="submit" value="%s"/>') % _('Load') |
1104 | 1106 |
r += htmltext('</form>') |
1105 | 1107 |
|
1106 |
r += self.links() |
|
1108 |
if get_cfg('aq-permissions', {}).get('links'): |
|
1109 |
r += self.links() |
|
1107 | 1110 |
|
1108 | 1111 |
cats = Category.select(order_by = 'name') |
1109 | 1112 |
cats = [x for x in cats if x.url_name != 'consultations' and x.get_homepage_position() == 'side'] |
... | ... | |
1117 | 1120 |
r += htmltext('</ul>') |
1118 | 1121 |
r += htmltext('</div>') |
1119 | 1122 |
|
1120 |
if Event.keys(): # if there are events, add a link to the agenda |
|
1123 |
if get_cfg('aq-permissions', {}).get('events') and Event.keys(): |
|
1124 |
# if there are events, add a link to the agenda |
|
1121 | 1125 |
tags = get_cfg('misc', {}).get('event_tags') |
1122 | 1126 |
if not tags: |
1123 | 1127 |
tags = get_default_event_tags() |
Formats disponibles : Unified diff
perfs: avoid events/links in critical path (#18965)