773a37d1c20f3518f59f396a401c50752dbb916f
[wolnelektury.git] / src / references / views.py
1 from django.views.decorators.cache import never_cache
2 from django.shortcuts import render, get_object_or_404
3 from . import models
4
5
6 def map(request):
7     return render(request, 'references/map.html', {
8         'entities': models.Entity.objects.exclude(lat=None).exclude(lon=None),
9         'funding_no_show_current': True,
10     })
11
12 @never_cache
13 def popup(request, pk):
14     e = get_object_or_404(models.Entity, pk=pk)
15     return render(request, 'references/popup.html', {
16         'entity': e,
17     })
18