{% extends "includes/crud/table_list.html" %} {% load trans blocktrans from i18n %} {% block top_left_menu_items %} {% endblock top_left_menu_items %} {% block create_button %} {% url "projects_automation_rule_create" project_slug=project.slug as create_regex_url %} {% trans "Add automation rule" as text %} {% include "includes/crud/create_button.html" with url=create_regex_url text=text %} {% endblock create_button %} {% block list_placeholder_icon_class %} fa-duotone fa-swap-opacity fa-robot {% endblock list_placeholder_icon_class %} {% block list_placeholder_header %} {% blocktrans trimmed %} No automation rules have been configured yet {% endblocktrans %}
{% blocktrans trimmed %} Automation rules can be used to automate common actions on new branches and tags. {% endblocktrans %}
{% endblock list_placeholder_header %} {% block list_placeholder_text %} {% trans "Learn more" %} {% endblock list_placeholder_text %} {% block list_item_right_buttons %} {% trans "Move up" as button_up_text %} {% trans "Move down" as button_down_text %} {% if not forloop.first %} {% endif %} {% if not forloop.last %} {% endif %} {% url 'projects_automation_rule_delete' object.project.slug object.pk as form_url %} {% trans "Remove rule" as action_text %} {% blocktrans trimmed asvar content_text with rule=object.get_description %} Remove rule {{ rule }}? {% endblocktrans %} {% include "includes/crud/remove_button.html" with id=object.pk form_url=form_url action_text=action_text content_text=content_text %} {% endblock list_item_right_buttons %} {% block list_item_icon %} {% endblock list_item_icon %} {% block list_item_header %} {{ object.get_description }}
{# TODO the text is special cased here because the model text has an additional note currently #} {% if object.action == object.DELETE_VERSION_ACTION %} {% trans "Delete version" %} {% else %} {{ object.get_action_display }} {% endif %}
{% endblock list_item_header %}