Automated merge with ssh://openslides.org/openslides

This commit is contained in:
Emanuel Schuetze 2012-04-18 18:29:34 +02:00
commit 67db762575
4 changed files with 23 additions and 37 deletions

View File

@ -65,19 +65,25 @@ $(function() {
} }
}); });
}); });
// hide closed items // filter to show/hide closed items
$('#action_field span').after($('<a id="hidelink" class="hidelink hide" title="hide" href="#"><span></span></a>').click(function () { $('#hide_closed_items').click(function(event) {
// show all items
if ($.cookie('Slide.HideClosed') == 1) { if ($.cookie('Slide.HideClosed') == 1) {
$.cookie('Slide.HideClosed', 0); $.cookie('Slide.HideClosed', 0);
hideClosedSlides(false); hideClosedSlides(false);
} else { $('#hide_closed_items').attr('checked', false);
}
else { // hide closed items
$.cookie('Slide.HideClosed', 1); $.cookie('Slide.HideClosed', 1);
hideClosedSlides(true); hideClosedSlides(true);
$('#hide_closed_items').attr('checked', true);
} }
})); });
if ($.cookie('Slide.HideClosed') === null) { if ($.cookie('Slide.HideClosed') === null) {
$('#hide_closed_items').attr('checked', false);
$.cookie('Slide.HideClosed', 0); $.cookie('Slide.HideClosed', 0);
} else if ($.cookie('Slide.HideClosed') == 1) { } else if ($.cookie('Slide.HideClosed') == 1) {
hideClosedSlides(true); hideClosedSlides(true);
$('#hide_closed_items').attr('checked', true);
} }
}); });

View File

@ -1,4 +1,5 @@
a.close_link.closed span { /* agenda item open/closed */
a.close_link span {
background-image: url(../images/icons/task-complete-grey.png); background-image: url(../images/icons/task-complete-grey.png);
background-repeat: no-repeat; background-repeat: no-repeat;
background-position: center; background-position: center;
@ -6,32 +7,11 @@ a.close_link.closed span {
height: 16px; height: 16px;
display: inline-block; display: inline-block;
} }
a.close_link.open span { a.close_link.closed span {
background-image: url(../images/icons/task-complete.png); background-image: url(../images/icons/task-complete.png);
background-repeat: no-repeat;
background-position: center;
width: 16px;
height: 16px;
display: inline-block;
} }
a.hidelink.hide span { /* agenda item inactive/active */
background-image: url(../images/icons/layer-visible-off.png);
background-repeat: no-repeat;
background-position: center;
width: 16px;
height: 16px;
display: inline-block;
}
a.hidelink.show span {
background-image: url(../images/icons/layer-visible-on.png);
background-repeat: no-repeat;
background-position: center;
width: 16px;
height: 16px;
display: inline-block;
}
/* activate link */
a.activate_link span { a.activate_link span {
background-image: url(../images/icons/task-accepted-grey.png); background-image: url(../images/icons/task-accepted-grey.png);
background-repeat: no-repeat; background-repeat: no-repeat;
@ -43,4 +23,3 @@ a.activate_link span {
a.activate_link.active span { a.activate_link.active span {
background-image: url(../images/icons/task-accepted.png); background-image: url(../images/icons/task-accepted.png);
} }

View File

@ -5,7 +5,7 @@
{% if item.active %}activeline{% endif %}"> {% if item.active %}activeline{% endif %}">
<td> <td>
{% if perms.agenda.can_manage_agenda %} {% if perms.agenda.can_manage_agenda %}
<a class="close_link {% if item.closed %}closed{% else %}open{% endif %}" href="{% if item.closed %}{% url item_open item.id %}{% else %}{% url item_close item.id %}{% endif %}"> <a class="close_link {% if item.closed %}closed{% endif %}" href="{% if item.closed %}{% url item_open item.id %}{% else %}{% url item_close item.id %}{% endif %}">
<span></span> <span></span>
</a> </a>
{% elif item.closed %} {% elif item.closed %}

View File

@ -40,6 +40,12 @@
{% block content %} {% block content %}
<h1>{% trans "Agenda" %}</h1> <h1>{% trans "Agenda" %}</h1>
<p>
{%trans "Filter" %}:
<input type="checkbox" id="hide_closed_items"> {%trans "Hide closed items" %}
</p>
{{ items|length }} {% trans "items" %}<span id="hiddencount"></span>
{% if items %} {% if items %}
<form action="/agenda/" method="post">{% csrf_token %} <form action="/agenda/" method="post">{% csrf_token %}
{% if perms.agenda.can_manage_agenda %} {% if perms.agenda.can_manage_agenda %}
@ -50,7 +56,6 @@
</em> </em>
</div> </div>
{% endif %} {% endif %}
<table id="menu-overview" class="agendatable"> <table id="menu-overview" class="agendatable">
<tr> <tr>
<th style="width: 1px;">{% trans "Done" %}</th> <th style="width: 1px;">{% trans "Done" %}</th>
@ -63,13 +68,9 @@
<tr class="topline {% if overview %}activeline{% endif %}"> <tr class="topline {% if overview %}activeline{% endif %}">
<td></td> <td></td>
<td> <td>
<b>{% trans "Agenda" %} ({{ items|length }} {% trans "items" %}<span id="hiddencount"></span>)</b> <b>{% trans "Agenda" %}</b>
</td>
<td>
<span id="action_field" style="width: 1px; white-space: nowrap;">
<span></span>
</span>
</td> </td>
<td></td>
</tr> </tr>
{% for item in items %} {% for item in items %}