Cache more templates

This commit is contained in:
Mark Veidemanis 2023-02-11 14:54:57 +00:00
parent eba4142960
commit bb5b473898
Signed by: m
GPG Key ID: 5ACFCEED46C0904F
4 changed files with 148 additions and 140 deletions

View File

@ -1,4 +1,8 @@
{% load pretty %}
{% load cache %}
{% cache 600 generic_detail request.user.id object live %}
{% include 'mixins/partials/notify.html' %}
{% if live is not None %}
@ -70,3 +74,4 @@
</tbody>
</table>
{% endif %}
{% endcache %}

View File

@ -1,3 +1,7 @@
{% load cache %}
{% cache 600 object_form request.user.id form %}
{% include 'mixins/partials/notify.html' %}
{% if page_title is not None %}
<h1 class="title is-4">{{ page_title }}</h1>
@ -25,10 +29,4 @@
<button type="submit" class="button modal-close-button">Submit</button>
</form>
{% endcache %}

View File

@ -1,3 +1,7 @@
{% load cache %}
{% cache 600 object request.user.id object %}
{% include 'mixins/partials/notify.html' %}
{% if page_title is not None %}
<h1 class="title is-4">{{ page_title }}</h1>
@ -43,3 +47,4 @@
{% include detail_template %}
{% endcache %}

View File

@ -1,6 +1,6 @@
{% load cache %}
{% cache 60 objects request.user.id object_list %}
{% cache 600 objects request.user.id object_list %}
{% include 'mixins/partials/notify.html' %}
{% if page_title is not None %}
<h1 class="title is-4">{{ page_title }}</h1>