  <table class="datatable">
    <thead>
      <tr>
        <th>Purpose</th>
        {% if not no_pipeline %}
        <th>Pipeline</th>
        {% endif %}
        <th>Path</th>
        <th>Description</th>
        {% if not no_space %}
        <th>Space</th>
        {% endif %}
        <th>UUID</th>
        <th>Usage</th>
        <th>Enabled</th>
        <th>Actions</th>
      </tr>
    </thead>
    <tbody>
    {% for loc in locations %}
      <tr>
        <td>{{ loc.get_purpose_display }}</td>
        {% if not no_pipeline %}
          <td>
          {% for p in loc.pipeline.all %}
            <a href="{% url 'pipeline_detail' p.uuid %}">{{ p.description }}</a>,
          {% empty %}
            <p>No pipelines</p>
          {% endfor %}
          </td>
        {% endif %}
        <td>{{ loc.full_path }}</td>
        <td><a href="{% url 'location_detail' loc.uuid %}">{{ loc.description|default:"None" }}</a></td>
        {% if not no_space %}
          <td><a href="{% url 'space_detail' loc.space.uuid %}">{{ loc.space.uuid|truncatechars:11 }}</a></td>
        {% endif %}
        <td>{{ loc.uuid }}</td>
        <td>{{ loc.used }}B / {{ loc.quota|default:"unlimited" }}</td>
        <td>{{ loc.enabled|yesno:"Enabled,Disabled" }}</td>
        <td><a href="{% url 'location_edit' loc.space.uuid loc.uuid %}">Edit</a> | <a href="{% url 'location_switch_enabled' loc.uuid %}?next={{ request.path }}">{{ loc.enabled|yesno:"Disable,Enable" }}</a> | <a href="{% url 'location_delete' loc.uuid %}?next={{ request.path }}">Delete</a></td>
      </tr>
    {% endfor %}
    </tbody>
  </table>
