<commit_before>{% extends "ndf/base.html" %}
{% load i18n %}
{% load ndf_tags %}
{% load pagination_tags %}

{% block title %} {{ title }} {% endblock %}

{% block style %}
  {{block.super}}

  /* Setting css-properties for app-set in left panel */
    .active-app-set, .active-app-set-edit, .active-app-set-view {
      /*padding:0.5em 0 0.5em 0.5em; */
      /*margin-left: -10px !important;*/
      background-color:#efefef;
    }

    .active-app-set-edit {
      border-right: 4px solid #808080;
      font-weight: bold;
    }

    .active-app-set-view {
      border-left: 4px solid #808080;
      font-weight: bold;
    }

  /* css-properties for table */
    .width_s_no {
      width: 5%;
    }

    .width_gender, .width_edit {
      width: 8%;
    }

    .width_delete {
      width: 8%;
      line-height: 0.5em;
      text-align: center !important;
    }

    .width_dob {
      width: 9%;
    }

    .width_name, .width_email_id {
      width: 31%;
    }

    .margin-0r {
      margin: 0 !important;
    }

    .counter {
      font-weight: bold;
      text-align: right;
    }

    .tiny.button {
      font-size: 1em !important;
    }
{% endblock%}

{% block meta_content %}
  {% check_is_gstaff groupid request.user as gstaff_access %}

  <ul class="side-nav"> 
  	<li>
  		<a></a>
  	</li>

    {% for each in app_collection_set %}
    {% get_memberof_objects_count each.pk groupid as count %}

    {% if app_set_id == each|safe %}
      {% if '/new/' in request.path %}
      <li class="active-app-set-edit">
      {% else %}
      <li class="active-app-set-view">
      {% endif %}
    {% else %}
    <li>
    {% endif %}
    
      <div class="row">
        {% if each.type_of or each.name == "Caste" or each.name == "NUSSD Course" %}
          <a class="large-8 columns" href="{% url 'mis:mis_app_detail' groupid app_id each.pk %}" title="View all {{each.name}}'s">
            {{each.name}} ({{count}})
          </a>

          {% if gstaff_access %}
          <a class="large-4 columns" href="{% url 'mis:mis_app_instance_create' groupid app_id each.pk %}" title="Add {{each.name}}">
            +&nbsp;Add
          </a>
          {% endif %}

        {% else %}
          {{each.name}}
        {% endif %}
      </div>
  	</li>

  	{% endfor %}
  </ul>
{% endblock %}

{% block body_content %} 
  {% check_is_gstaff groupid request.user as gstaff_access %}  

  {% if nodes %}
    {% autopaginate nodes 25 %}
  
    <div id="myModal" class="reveal-modal" data-reveal style="height:500px;overflow:scroll;"> 
     {% blocktrans %} <h3>Are you sure you want to delete? All of the following related data also will be deleted:</h3> {% endblocktrans %} 
      <input class="button tiny confirmDeleteObjects" type="button" value="Confirm">
      <input class="button tiny cancelDeleteObjects" type="button" value="Cancel">
      <div id="deletion_results"></div>
      <a class="close-reveal-modal">&#215;</a>
    </div>

    <div class="row" style="margin-top: 1rem;">
      <form method="POST">
        {% csrf_token %}
        <div class="large-5 large-push-7 columns">
          <div class="row collapse">
            <div class="large-10 columns">
              <input type="text" name="search" value="" placeholder="By name...">
            </div>
            <div class="large-2 columns end">
              <input type="submit" class="button postfix" value="Search">
              <input type="hidden" name="class" value="{{class_name}}">
            </div>
          </div>
        </div>
      </form>
    </div>
  {% endif %}

  <table>
    <thead>
      {% if nodes %}
        <th class="width_s_no counter">{% trans "S. #" %}</th>
        {% for each_key in nodes_keys %}
        <th class="width_{{each_key.0}}">{{each_key.1}}</th>
        {% endfor %}
        {% if gstaff_access %}
        <th class="width_edit">{% trans "Edit" %}</th>
        <th class="width_delete"><input class="margin-0r checkedAll" type="checkbox"><br><input class="button tiny margin-0r deleteObjects" type="button" value="Delete"></th>
        {% endif %}
      {% endif %}
    </thead>
    
    <tbody>
      {% for each in nodes %}
        <tr>
          <td class="counter">{{forloop.counter}}.</td>
          {% for each_key in nodes_keys %}
          {% if forloop.counter == 1 %}
          <td>{{each|get_dict_item:each_key.0|title}}</a></td>
          {% elif forloop.counter > 2 %}
          <td>{{each|get_dict_item:each_key.0|default:"--"}}</a></td>
          {% else %}
          <td>{{each|get_dict_item:each_key.0}}</a></td>
          {% endif %}
          {% endfor %}
          {% if gstaff_access %}
          <td class="name"><a href="{% url 'mis:mis_app_instance_edit' groupid app_id app_set_id each|get_dict_item:'_id' %}" target="_blank" class="button tiny expand margin-0r width_edit">Edit</a></td>
          <td id="{{each|get_dict_item:'_id'}}" class="width_delete objectsCheckbox"> <input type="checkbox"> </td>
          {% endif %}
        </tr>
        
      {% empty %}<commit_msg>Bug fix: Unnecessary close of anchor tag removed<commit_after>{% extends "ndf/base.html" %}
{% load i18n %}
{% load ndf_tags %}
{% load pagination_tags %}

{% block title %} {{ title }} {% endblock %}

{% block style %}
  {{block.super}}

  /* Setting css-properties for app-set in left panel */
    .active-app-set, .active-app-set-edit, .active-app-set-view {
      /*padding:0.5em 0 0.5em 0.5em; */
      /*margin-left: -10px !important;*/
      background-color:#efefef;
    }

    .active-app-set-edit {
      border-right: 4px solid #808080;
      font-weight: bold;
    }

    .active-app-set-view {
      border-left: 4px solid #808080;
      font-weight: bold;
    }

  /* css-properties for table */
    .width_s_no {
      width: 5%;
    }

    .width_gender, .width_edit {
      width: 8%;
    }

    .width_delete {
      width: 8%;
      line-height: 0.5em;
      text-align: center !important;
    }

    .width_dob {
      width: 9%;
    }

    .width_name, .width_email_id {
      width: 31%;
    }

    .margin-0r {
      margin: 0 !important;
    }

    .counter {
      font-weight: bold;
      text-align: right;
    }

    .tiny.button {
      font-size: 1em !important;
    }
{% endblock%}

{% block meta_content %}
  {% check_is_gstaff groupid request.user as gstaff_access %}

  <ul class="side-nav"> 
  	<li>
  		<a></a>
  	</li>

    {% for each in app_collection_set %}
    {% get_memberof_objects_count each.pk groupid as count %}

    {% if app_set_id == each|safe %}
      {% if '/new/' in request.path %}
      <li class="active-app-set-edit">
      {% else %}
      <li class="active-app-set-view">
      {% endif %}
    {% else %}
    <li>
    {% endif %}
    
      <div class="row">
        {% if each.type_of or each.name == "Caste" or each.name == "NUSSD Course" %}
          <a class="large-8 columns" href="{% url 'mis:mis_app_detail' groupid app_id each.pk %}" title="View all {{each.name}}'s">
            {{each.name}} ({{count}})
          </a>

          {% if gstaff_access %}
          <a class="large-4 columns" href="{% url 'mis:mis_app_instance_create' groupid app_id each.pk %}" title="Add {{each.name}}">
            +&nbsp;Add
          </a>
          {% endif %}

        {% else %}
          {{each.name}}
        {% endif %}
      </div>
  	</li>

  	{% endfor %}
  </ul>
{% endblock %}

{% block body_content %} 
  {% check_is_gstaff groupid request.user as gstaff_access %}  

  {% if nodes %}
    {% autopaginate nodes 25 %}
  
    <div id="myModal" class="reveal-modal" data-reveal style="height:500px;overflow:scroll;"> 
     {% blocktrans %} <h3>Are you sure you want to delete? All of the following related data also will be deleted:</h3> {% endblocktrans %} 
      <input class="button tiny confirmDeleteObjects" type="button" value="Confirm">
      <input class="button tiny cancelDeleteObjects" type="button" value="Cancel">
      <div id="deletion_results"></div>
      <a class="close-reveal-modal">&#215;</a>
    </div>

    <div class="row" style="margin-top: 1rem;">
      <form method="POST">
        {% csrf_token %}
        <div class="large-5 large-push-7 columns">
          <div class="row collapse">
            <div class="large-10 columns">
              <input type="text" name="search" value="" placeholder="By name...">
            </div>
            <div class="large-2 columns end">
              <input type="submit" class="button postfix" value="Search">
              <input type="hidden" name="class" value="{{class_name}}">
            </div>
          </div>
        </div>
      </form>
    </div>
  {% endif %}

  <table>
    <thead>
      {% if nodes %}
        <th class="width_s_no counter">{% trans "S. #" %}</th>
        {% for each_key in nodes_keys %}
        <th class="width_{{each_key.0}}">{{each_key.1}}</th>
        {% endfor %}
        {% if gstaff_access %}
        <th class="width_edit">{% trans "Edit" %}</th>
        <th class="width_delete"><input class="margin-0r checkedAll" type="checkbox"><br><input class="button tiny margin-0r deleteObjects" type="button" value="Delete"></th>
        {% endif %}
      {% endif %}
    </thead>
    
    <tbody>
      {% for each in nodes %}
        <tr>
          <td class="counter">{{forloop.counter}}.</td>
          {% for each_key in nodes_keys %}
          {% if forloop.counter == 1 %}
          <td>{{each|get_dict_item:each_key.0|title}}</td>
          {% elif forloop.counter > 2 %}
          <td>{{each|get_dict_item:each_key.0|default:"--"}}</td>
          {% else %}
          <td>{{each|get_dict_item:each_key.0}}</td>
          {% endif %}
          {% endfor %}
          {% if gstaff_access %}
          <td class="name"><a href="{% url 'mis:mis_app_instance_edit' groupid app_id app_set_id each|get_dict_item:'_id' %}" target="_blank" class="button tiny expand margin-0r width_edit">Edit</a></td>
          <td id="{{each|get_dict_item:'_id'}}" class="width_delete objectsCheckbox"> <input type="checkbox"> </td>
          {% endif %}
        </tr>
        
      {% empty %}
{'fraction_non_alphanumeric': 0.17641799940399325, 'fraction_numerical': 0.01271481076785537, 'mean_word_length': 2.227957678743187, 'pattern_counts': {'":': 0, '<': 152, '<?xml version=': 0, '>': 154, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '133061', 'n_tokens_mistral': 3671, 'n_tokens_neox': 3283, 'n_words': 725}