{% extends "core/base.jinja" %}

{% block content %}
  <h3>{% trans %}Club tools{% endtrans %}</h3>
  <div>
    <h4>{% trans %}Communication:{% endtrans %}</h4>
    <ul>
      <li>
        <a href="{{ url('com:news_new') }}?club={{ object.id }}">
          {% trans %}Create a news{% endtrans %}
        </a>
      </li>
      <li>
        <a href="{{ url('com:weekmail_article') }}?club={{ object.id }}">
          {% trans %}Post in the Weekmail{% endtrans %}
        </a>
      </li>
      {% if object.can_roles_be_edited_by(user) %}
        <li><a href="{{ url("club:club_roles", club_id=object.id) }}"></a></li>
      {% endif %}
      {% if object.trombi %}
        <li> <a href="{{ url('trombi:detail', trombi_id=object.trombi.id) }}">{% trans %}Edit Trombi{% endtrans %}</a></li>
      {% else %}
        <li> <a href="{{ url('trombi:create', club_id=object.id) }}">{% trans %}New Trombi{% endtrans %}</a></li>
        <li> <a href="{{ url('club:poster_list', club_id=object.id) }}">{% trans %}Posters{% endtrans %}</a></li>
      {% endif %}
    </ul>
    <h4>{% trans %}Counters:{% endtrans %}</h4>
    <ul>
      {% for c in object.counters.filter(type="OFFICE") %}
        <li>{{ c }}:
          <a href="{{ url('counter:details', counter_id=c.id) }}">View</a>
          <a href="{{ url('counter:admin', counter_id=c.id) }}">Edit</a>
        </li>
      {% endfor %}
    </ul>
  </div>
{% endblock %}



