vue update

This commit is contained in:
bkfox
2022-03-18 03:45:13 +01:00
parent adb10c3d95
commit 789808e815
24 changed files with 8902 additions and 6514 deletions

View File

@ -12,6 +12,8 @@ __all__ = ['AdminMixin', 'StatisticsView']
class AdminMixin(LoginRequiredMixin, UserPassesTestMixin):
title = ''
init_app = True
""" If true, create vue app. """
@property
def station(self):
@ -24,6 +26,7 @@ class AdminMixin(LoginRequiredMixin, UserPassesTestMixin):
kwargs.update(admin.site.each_context(self.request))
kwargs.setdefault('title', self.title)
kwargs.setdefault('station', self.station)
kwargs.setdefault('init_app', self.init_app)
return super().get_context_data(**kwargs)