mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-27 10:22:17 +00:00
Versioning module now does magic
Automatic creation of views/urls for anything registered with reversion, with a small amount of hackage to preserve legacy stuff. (and the DAMNED asset IDs!) I would never get distracted...
This commit is contained in:
@@ -21,25 +21,6 @@ from assets import models as asset_models
|
||||
from functools import reduce
|
||||
|
||||
from PyRIGS.views import GenericListView
|
||||
from django.views.decorators.cache import never_cache
|
||||
from django.utils.decorators import method_decorator
|
||||
|
||||
"""
|
||||
Displays the current rig count along with a few other bits and pieces
|
||||
"""
|
||||
|
||||
# Disable browser based caching
|
||||
|
||||
|
||||
@method_decorator(never_cache, name='dispatch')
|
||||
class Index(generic.TemplateView):
|
||||
template_name = 'index.html'
|
||||
|
||||
def get_context_data(self, **kwargs):
|
||||
context = super(Index, self).get_context_data(**kwargs)
|
||||
context['rig_count'] = models.Event.objects.rig_count()
|
||||
return context
|
||||
|
||||
|
||||
class PersonList(GenericListView):
|
||||
template_name = 'person_list.html'
|
||||
|
||||
Reference in New Issue
Block a user