{% extends 'oef/base.html' %}


{% block content %}

<h2>Entries</h2>
Count: <span id="count">{{ entries|length }}</span>

<button
_="on click hide <li.inactive-True/> then show <li.inactive-False/> then set #count.innerHTML to length of <li.inactive-False/>"
>Hide inactive</button>
<button
_="on click hide <li.inactive-False/> then show <li.inactive-True/> then set #count.innerHTML to length of <li.inactive-True/>"
>Hide active</button>

<ul>
{% for entry in entries %}
<li class="inactive-{{entry.inactive}}"><a href='{{entry.get_absolute_url}}'>{{entry.exam_code}} / {{entry.exam_name}}</a></li>
    
{% endfor %}
</ul>
    

{% endblock %}

{% block css %}
<style type="text/css">
    .inactive-True a {
        color: darkred;
        text-decoration: none;
    }
    .inactive-False a {
        text-decoration: none;
    }
    </style>
{% endblock %}