{% extends "wagtailadmin/generic/base.html" %} {% load i18n wagtailadmin_tags %} {% block titletag %}{% trans "DripDrop cache" %}{% endblock %} {% block main_header %} {% include "wagtailadmin/shared/header.html" with title="DripDrop cache" subtitle="Flows and custom fields" icon="refresh" only %} {% endblock %} {% block main_content %}

{% trans "DripDrop flow and custom field choices are cached for Wagtail form editing. Use this page to inspect the current cache and refresh it from the DripDrop API." %}

{% csrf_token %}

{% blocktrans count count=flow_count %}Cached flow{% plural %}Cached flows{% endblocktrans %} ({{ flow_count }})

{% if not flows_cached %}

{% trans "Flow cache is empty. Refresh the cache to fetch flows from DripDrop." %}

{% elif flows %} {% for flow in flows %} {% endfor %}
{% trans "Name" %} {% trans "UUID" %}
{{ flow.name|default:"—" }} {{ flow.uuid|default:"—" }}
{% else %}

{% trans "Flow cache is present but contains no flows." %}

{% endif %}

{% blocktrans count count=custom_field_count %}Cached custom field{% plural %}Cached custom fields{% endblocktrans %} ({{ custom_field_count }})

{% if not custom_fields_cached %}

{% trans "Custom field cache is empty. Refresh the cache to fetch custom fields from DripDrop." %}

{% elif custom_fields %} {% for field in custom_fields %} {% endfor %}
{% trans "Display name" %} {% trans "Key" %} {% trans "Target model" %}
{{ field.display_name|default:"—" }} {{ field.key|default:"—" }} {{ field.target_model|default:"—" }}
{% else %}

{% trans "Custom field cache is present but contains no custom fields." %}

{% endif %}
{% endblock %}