mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-26 03:58:49 +01:00
add ui for changing state of context to closed. This fixes #645
This commit is contained in:
parent
acab98d4c7
commit
4df340bd7b
12 changed files with 114 additions and 86 deletions
|
|
@ -783,16 +783,24 @@ var ContextListPage = {
|
|||
update_state_count: function(state, count) {
|
||||
$('#'+state+'-contexts-count').html(count);
|
||||
},
|
||||
update_all_states_count: function (active_count, hidden_count, completed_count) {
|
||||
$(["active", "hidden"]).each(function() {
|
||||
update_all_states_count: function (active_count, hidden_count, closed_count) {
|
||||
$(["active", "hidden", "closed"]).each(function() {
|
||||
ContextListPage.update_state_count(this, eval(this+'_count'));
|
||||
});
|
||||
},
|
||||
show_or_hide_all_state_containers: function (show_active, show_hidden, show_completed) {
|
||||
$(["active", "hidden"]).each(function() {
|
||||
show_or_hide_all_state_containers: function (show_active, show_hidden, show_closed) {
|
||||
$(["active", "hidden", "closed"]).each(function() {
|
||||
ContextListPage.set_state_container_visibility(this, eval('show_'+this));
|
||||
ContextListPage.hide_empty_message(this, !eval('show_'+this));
|
||||
});
|
||||
},
|
||||
hide_empty_message: function(state, set_visible) {
|
||||
if(set_visible) {
|
||||
$('div#'+state+'-contexts-empty-nd').slideDown("fast");
|
||||
} else {
|
||||
$('div#'+state+'-contexts-empty-nd').slideUp("fast");
|
||||
}
|
||||
},
|
||||
set_state_container_visibility: function (state, set_visible) {
|
||||
if (set_visible) {
|
||||
$('#list-'+state+'-contexts-container').slideDown("fast");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue