mirror of
https://github.com/grocy/grocy.git
synced 2026-04-06 12:56:15 +02:00
Set no best buy date if purchase location is freezer
This commit is contained in:
parent
dd6b062af4
commit
45eaebb65d
|
|
@ -285,6 +285,19 @@ if (GetUriParam("flow") === "shoppinglistitemtostock")
|
||||||
$('#amount').val(GetUriParam("amount"));
|
$('#amount').val(GetUriParam("amount"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Grocy.Components.LocationPicker.GetPicker().on('change', function(e)
|
||||||
|
{
|
||||||
|
if ($('option:selected', this).data('freezer') == 1)
|
||||||
|
{
|
||||||
|
$("#datetimepicker-shortcut").click();
|
||||||
|
} else {
|
||||||
|
if ($("#datetimepicker-shortcut").is(":checked"))
|
||||||
|
{
|
||||||
|
$("#datetimepicker-shortcut").click();
|
||||||
|
Grocy.Components.ProductPicker.GetPicker().trigger('change');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
function UndoStockBooking(bookingId)
|
function UndoStockBooking(bookingId)
|
||||||
{
|
{
|
||||||
Grocy.Api.Post('stock/bookings/' + bookingId.toString() + '/undo', { },
|
Grocy.Api.Post('stock/bookings/' + bookingId.toString() + '/undo', { },
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user