Added an option to filter for only undone items on the shopping list (closes #452)

This commit is contained in:
Bernd Bestel
2020-01-24 22:26:36 +01:00
parent ad54253d72
commit 3cbeea7d95
4 changed files with 21 additions and 1 deletions

View File

@@ -282,6 +282,20 @@ $(document).on('click', '.order-listitem-button', function(e)
console.error(xhr);
}
);
var statusInfoCell = $("#shoppinglistitem-" + listItemId + "-status-info");
if (done == 1)
{
statusInfoCell.text(statusInfoCell.text().replace("xxUNDONExx", ""));
}
else
{
statusInfoCell.text(statusInfoCell.text() + " xxUNDONExx");
}
shoppingListTable.rows().invalidate().draw(false);
$("#status-filter").trigger("change");
});
function OnListItemRemoved()