2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2024-11-21 23:01:52 +00:00
troggle/core/context.py

13 lines
551 B
Python
Raw Normal View History

from django.conf import settings
2021-04-13 00:43:57 +01:00
from troggle.core.models.troggle import Expedition
2021-04-13 01:37:42 +01:00
'''This is the only troglle-specific 'context processor' that troggle uses
in the processing of Django templates
This seems to mean that every page produced has bundled in its context the complete 'settings' and
the expedition class object, so all templates can doe queries on Expedition.
https://betterprogramming.pub/django-quick-tips-context-processors-da74f887f1fc
'''
2009-05-19 06:32:42 +01:00
def troggle_context(request):
return { 'settings':settings, 'Expedition':Expedition }