Ability to disable cache storage

This commit is contained in:
Yohann D'ANELLO 2020-02-21 18:28:21 +01:00
parent c64347def7
commit 3fd99ebac7
3 changed files with 11 additions and 0 deletions

View File

@ -249,6 +249,9 @@ class ClubAddMemberView(LoginRequiredMixin, CreateView):
context = super().get_context_data(**kwargs) context = super().get_context_data(**kwargs)
context['formset'] = MemberFormSet() context['formset'] = MemberFormSet()
context['helper'] = FormSetHelper() context['helper'] = FormSetHelper()
context['no_cache'] = True
return context return context
def post(self, request, *args, **kwargs): def post(self, request, *args, **kwargs):

View File

@ -28,6 +28,9 @@ class TransactionCreate(LoginRequiredMixin, CreateView):
context = super().get_context_data(**kwargs) context = super().get_context_data(**kwargs)
context['title'] = _('Transfer money from your account ' context['title'] = _('Transfer money from your account '
'to one or others') 'to one or others')
context['no_cache'] = True
return context return context
def get_form(self, form_class=None): def get_form(self, form_class=None):
@ -146,6 +149,8 @@ class ConsoView(LoginRequiredMixin, CreateView):
template_type=template_type) template_type=template_type)
context['title'] = template_type context['title'] = template_type
context['no_cache'] = True
return context return context
def get_success_url(self): def get_success_url(self):

View File

@ -22,6 +22,9 @@ SPDX-License-Identifier: GPL-3.0-or-later
<meta name="msapplication-TileColor" content="#da532c"> <meta name="msapplication-TileColor" content="#da532c">
<meta name="msapplication-config" content="{% static "favicon/browserconfig.xml" %}"> <meta name="msapplication-config" content="{% static "favicon/browserconfig.xml" %}">
<meta name="theme-color" content="#ffffff"> <meta name="theme-color" content="#ffffff">
{% if no_cache %}
<meta name="turbolinks-cache-control" content="no-cache">
{% endif %}
{# Bootstrap CSS #} {# Bootstrap CSS #}
<link rel="stylesheet" <link rel="stylesheet"