mirror of
https://github.com/grocy/grocy.git
synced 2025-08-20 12:20:22 +00:00
Adapt shopping list add expired products for #851
This commit is contained in:
@@ -174,12 +174,21 @@ $(document).on('click', '#add-products-below-min-stock-amount', function(e)
|
||||
);
|
||||
});
|
||||
|
||||
$(document).on('click', '#add-overdue-products', function(e)
|
||||
$(document).on('click', '#add-overdue-expired-products', function(e)
|
||||
{
|
||||
Grocy.Api.Post('stock/shoppinglist/add-overdue-products', { "list_id": $("#selected-shopping-list").val() },
|
||||
function(result)
|
||||
{
|
||||
window.location.href = U('/shoppinglist?list=' + $("#selected-shopping-list").val());
|
||||
Grocy.Api.Post('stock/shoppinglist/add-expired-products', { "list_id": $("#selected-shopping-list").val() },
|
||||
function(result)
|
||||
{
|
||||
window.location.href = U('/shoppinglist?list=' + $("#selected-shopping-list").val());
|
||||
},
|
||||
function(xhr)
|
||||
{
|
||||
console.error(xhr);
|
||||
}
|
||||
);
|
||||
},
|
||||
function(xhr)
|
||||
{
|
||||
|
Reference in New Issue
Block a user