{% extends "includes/crud/table_list.html" %}
{% load trans blocktrans from i18n %}
{% load gravatar_url from gravatar %}
{% block top_left_menu_items %}
{% endblock top_left_menu_items %}
{% block create_button %}
{% url "projects_users_create" project.slug as create_url %}
{% trans "Add maintainer" as create_text %}
{% include "includes/crud/create_button.html" with url=create_url text=create_text %}
{% endblock create_button %}
{% block list_placeholder_icon %}
{% endblock list_placeholder_icon %}
{% block list_placeholder_header %}
{% blocktrans trimmed %}
This project currently has no maintainers.
{% endblocktrans %}
{% endblock list_placeholder_header %}
{% block list_placeholder_text %}
{% endblock list_placeholder_text %}
{% block list_item_right_buttons %}
{% url "projects_users_delete" project.slug as form_url %}
{% trans "Remove maintainer" as action_text %}
{% blocktrans trimmed asvar content_text with username=object.username name=project.name %}
Remove user {{ username }} as a maintainer?
{% endblocktrans %}
{# Repeating the include because Django templates make conditional variables impossible #}
{% if object == request.user %}
{% include "includes/crud/remove_button.html" with id=object.pk form_url=form_url field_name="username" field_value=object.username action_text=action_text content_text=content_text is_disabled=True %}
{% else %}
{% include "includes/crud/remove_button.html" with id=object.pk form_url=form_url field_name="username" field_value=object.username action_text=action_text content_text=content_text is_disabled=False %}
{% endif %}
{% endblock list_item_right_buttons %}
{% block list_item_image %}
{% endblock list_item_image %}
{% block list_item_header %}
{% with full_name=object.get_full_name %}
{% if full_name %}
{{ full_name }}
{% else %}
{{ object.username }}
{% endif %}
{% if full_name %}