{% load is_empty from ext_theme_tags %} {% comment "rst" %} Shared list base ================ ``includes/crud/list.html`` This is the shared template that is used to produce a consistent list view. All list views extend this common template, and so all list views share layout and functionality. Template parameters ------------------- .. describe:: objects This is the queryset instance that the list view will iterate over. Views use the context variable ``objects`` by default, but some of our views can also use custom context variables, like ``projects`` or ``project_objects``. .. describe:: skip_pagination **Boolean, default=False**. Skip pagination calls and links List top menu blocks -------------------- .. describe:: view_binding This is used to apply a Knockout ``data-bind``, used when the list is JS/Knockout driven UI. This is the case for any list view that has dynamic user interactions for each list item. .. seealso: Views like the project list view and the project detail (or project version list view) show how this data binding would be configured. .. describe:: top_left_menu_items This is the block used to add list view filter elements to the top of the list. .. describe:: top_right_menu This is the parent element for where we will insert an "Add" button. You shouldn't need to alter this unless you are doing something different with this block. Contains ``top_right_menu_items``, which similarly doesn't normally require overriding, and the child ``create_button``, which is the most common to override .. describe:: top_right_menu_itmes Similar to ``top_right_menu``, this doesn't normaly require overriding. It might be used if you need multiple buttons on the top right of the list. You most likely want to override ``create_button`` .. describe:: create_button This is the button that will usually link to a new page, or open a modal, to create a new object type for the object list -- ie, create a new webhook in the webhook list view. {% endcomment %} {% load trans blocktrans from i18n %} {% load autopaginate paginate from pagination_tags %}
|
{% block list_item_image %}
{% comment %}
On the off chance you actually want an image here,
override this whole block. We use a fake image here to
avoid customizing CSS to avoid width/spacing issues.
{% endcomment %}
{# TODO consider making our own .ui.table .ui.icon.header styles #}
{% block list_item_icon %}
{% comment %}
{% endcomment %}
{% endblock list_item_icon %}
{% endblock list_item_image %}
{% block list_item_header %}
{{ object }}
{% endblock list_item_header %}
|
{% endblock list_item_header_column %}
{% block list_item_meta_column %}
{% block list_item_meta %}
{% block list_item_meta_items %}
{% comment %}
{% endblock list_item_meta %}
{{ build.commit|truncatechars:8 }}
|
{% endblock list_item_meta_column %}
{% block list_item_extra_column %}
{% block list_item_extra %}
{% block list_item_extra_items %}
{% endblock list_item_extra_items %}
|
{% endblock list_item_extra %}
{% endblock list_item_extra_column %}
{% block list_item_right_column %}
{% block list_item_right_menu %} {% endblock list_item_right_menu %} | {% endblock list_item_right_column %} {% endblock list_item %}