<commit_before>{% extends "admin/base.html" %}

{% import 'macros/form.html' as form %}

{% block primary_content_inner %}
  {% set service_url = h.url_for('download_requests_data') %}
  {% set csv = '?format=csv'%}
  {% set json = '?format=json'%}
  <div class="dropdown">
    <button class="btn dropdown-toggle " type="button" data-toggle="dropdown">Download
    <span class="caret"></span></button>
    <ul class="dropdown-menu dropdown-menu-left">
      <li><a href="{{ service_url }}{{ csv }}">CSV</a></li>
      <li><a href="{{ service_url }}{{ json }}">JSON</a></li>
    </ul>
  </div>
    <br><br>
  <div>
    <div class="total-requests-counter requested-data-container-item">Total:
      <span>{{ total_requests_counters.requests[0][0] }} requests,</span>
      <span>{{ total_requests_counters.replied[0][0] }} replies,</span>
      <span>{{ total_requests_counters.declined[0][0] }} declined,</span>
      <span>{{ total_requests_counters.shared[0][0] }} shared</span>
    </div>
    <div class="total-requests-filter">
      {% snippet 'requestdata/snippets/filter_requests.html', title='Organization', filter_options=organizations_for_filters, type='maintainer', type='organization' %}
    </div>
  </div>
  <br><br>
  <div class="sysadmin-requests-container">
    {% for org in organizations %}
    <div>
      <div class="requested-data-org-title requested-data-container-item"> <h2 data-id="{{ org.id }}">{{ org['title'] }}</h2></div>
       <div class="total-requests-counter requested-data-container-item">
        <span>{{ org.counters.requests[0][0] }} requests,</span>
        <span>{{ org.counters.replied[0][0] }} replies,</span>
        <span>{{ org.counters.declined[0][0] }} declined,</span>
        <span>{{ org.counters.shared[0][0] }} shared</span>
      </div>
      <div class="total-requests-filter">
      {% snippet 'requestdata/snippets/filter_requests.html', org_name=org.name, title='Maintainer', filter_options=org.maintainers, type='maintainer' %}
      </div>
    </div>
    <br><br>
      {% snippet 'requestdata/snippets/section_base.html', state='new', title='New', requests=org['requests_new'], template_type='admin'  %}
      {% snippet 'requestdata/snippets/section_base.html', state='open', title='Open', requests=org['requests_open'], template_type='admin' %}

            {% set service_url = h.url_for('ckanadmin_requests_data') %}
            {% set o = org['name']%}
            {% set asc = "?order_by=asc|org:"+ o%}
            {% set desc = '?order_by=desc|org:' + o%}
            {% set req = '?order_by=requests|org:' + o %}
            {% set shared = '?order_by=shared|org:' + o %}
          <div class="dropdown requested-data-order-btn">
            <button class="btn dropdown-toggle " type="button" data-toggle="dropdown">ORDER BY
            <span class="caret"></span></button>
            <ul class="dropdown-menu dropdown-menu-left">
              <li><a href="{{ service_url }}{{ asc }}">ALPHABETICAL(A-Z)</a></li>
              <li><a href="{{ service_url }}{{ desc }}">ALPHABETICAL (Z-A)</a></li>
               <li><a href="{{ service_url }}{{ req }}">REQUESTS RATE</a></li>
               <li><a href="{{ service_url }}{{ shared }}">SHARING RATE</a></li>
            </ul>
          </div>
      {% snippet 'requestdata/snippets/section_base.html', state='archive', title='Archive', requests=org['requests_archive'], template_type='admin'  %}
    {% endfor %}
  </div>
  <div class="alert alert-dismissible request-message-alert hide" role="alert">
    <div class="alert-text"></div>
  </div>
{% endblock %}

{% block secondary_content %}
  <div class="module module-narrow module-shallow">
    <h2 class="module-heading">
      <i class="icon-info-sign"></i>
      {{ _('Data') }}
    </h2>
    <div class="module-content">
      {% block admin_form_help %}
        <p><strong>Requested data:</strong> We will add info for these page here</a>.</p>
      {% endblock %}
    </div>
  </div>
{% endblock %}<commit_msg>Remove left panel in admin requests data page<commit_after>{% extends "page.html" %}

{% import 'macros/form.html' as form %}

{% block primary %}
  {% set service_url = h.url_for('download_requests_data') %}
  {% set csv = '?format=csv'%}
  {% set json = '?format=json'%}
  <div class="dropdown">
    <button class="btn dropdown-toggle " type="button" data-toggle="dropdown">Download
    <span class="caret"></span></button>
    <ul class="dropdown-menu dropdown-menu-left">
      <li><a href="{{ service_url }}{{ csv }}">CSV</a></li>
      <li><a href="{{ service_url }}{{ json }}">JSON</a></li>
    </ul>
  </div>
    <br><br>
  <div>
    <div class="total-requests-counter requested-data-container-item">Total:
      <span>{{ total_requests_counters.requests[0][0] }} requests,</span>
      <span>{{ total_requests_counters.replied[0][0] }} replies,</span>
      <span>{{ total_requests_counters.declined[0][0] }} declined,</span>
      <span>{{ total_requests_counters.shared[0][0] }} shared</span>
    </div>
    <div class="total-requests-filter">
      {% snippet 'requestdata/snippets/filter_requests.html', title='Organization', filter_options=organizations_for_filters, type='maintainer', type='organization' %}
    </div>
  </div>
  <br><br>
  <div class="sysadmin-requests-container">
    {% for org in organizations %}
    <div>
      <div class="requested-data-org-title requested-data-container-item"> <h2 data-id="{{ org.id }}">{{ org['title'] }}</h2></div>
       <div class="total-requests-counter requested-data-container-item">
        <span>{{ org.counters.requests[0][0] }} requests,</span>
        <span>{{ org.counters.replied[0][0] }} replies,</span>
        <span>{{ org.counters.declined[0][0] }} declined,</span>
        <span>{{ org.counters.shared[0][0] }} shared</span>
      </div>
      <div class="total-requests-filter">
      {% snippet 'requestdata/snippets/filter_requests.html', org_name=org.name, title='Maintainer', filter_options=org.maintainers, type='maintainer' %}
      </div>
    </div>
    <br><br>
      {% snippet 'requestdata/snippets/section_base.html', state='new', title='New', requests=org['requests_new'], template_type='admin'  %}
      {% snippet 'requestdata/snippets/section_base.html', state='open', title='Open', requests=org['requests_open'], template_type='admin' %}

            {% set service_url = h.url_for('ckanadmin_requests_data') %}
            {% set o = org['name']%}
            {% set asc = "?order_by=asc|org:"+ o%}
            {% set desc = '?order_by=desc|org:' + o%}
            {% set req = '?order_by=requests|org:' + o %}
            {% set shared = '?order_by=shared|org:' + o %}
          <div class="dropdown requested-data-order-btn">
            <button class="btn dropdown-toggle " type="button" data-toggle="dropdown">ORDER BY
            <span class="caret"></span></button>
            <ul class="dropdown-menu dropdown-menu-left">
              <li><a href="{{ service_url }}{{ asc }}">ALPHABETICAL(A-Z)</a></li>
              <li><a href="{{ service_url }}{{ desc }}">ALPHABETICAL (Z-A)</a></li>
               <li><a href="{{ service_url }}{{ req }}">REQUESTS RATE</a></li>
               <li><a href="{{ service_url }}{{ shared }}">SHARING RATE</a></li>
            </ul>
          </div>
      {% snippet 'requestdata/snippets/section_base.html', state='archive', title='Archive', requests=org['requests_archive'], template_type='admin'  %}
    {% endfor %}
  </div>
  <div class="alert alert-dismissible request-message-alert hide" role="alert">
    <div class="alert-text"></div>
  </div>
{% endblock %}

{% block secondary %}{% endblock %}

{'fraction_non_alphanumeric': 0.20448289421942586, 'fraction_numerical': 0.0049809935771398615, 'mean_word_length': 3.436046511627907, 'pattern_counts': {'":': 0, '<': 184, '<?xml version=': 0, '>': 184, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1369333', 'n_tokens_mistral': 2599, 'n_tokens_neox': 2462, 'n_words': 448}