Move removeCompleted
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Peter Stuifzand 2020-11-14 08:18:20 +01:00
parent 8de01dc68f
commit 4518621790

View File

@ -114,6 +114,15 @@ function connectContextMenu(editor) {
editor.actions.markDone.call(editor, id)
}
},
removeCompleted: {
name: 'Remove completed',
callback: function (key, opt) {
let item = $(this).parents('.list-item')
let id = item.attr('data-id')
editor.actions.removeCompleted.call(editor, id)
editor.render()
}
},
sort: {
name: 'Sort',
items: [
@ -156,16 +165,6 @@ function connectContextMenu(editor) {
]
},
removeCompleted: {
name: 'Remove completed',
callback: function (key, opt) {
let item = $(this).parents('.list-item')
let id = item.attr('data-id')
editor.actions.removeCompleted.call(editor, id)
editor.render()
}
}
// TODO
// - Sort
// - Date (on item) (new-old)