diff --git a/changelog/56_UNRELEASED_2020-xx-xx.md b/changelog/56_UNRELEASED_2020-xx-xx.md new file mode 100644 index 00000000..6b20a665 --- /dev/null +++ b/changelog/56_UNRELEASED_2020-xx-xx.md @@ -0,0 +1,5 @@ +### Stock fixes +- Fixed purchase/consume/inventory problems when `FEATURE_FLAG_STOCK_LOCATION_TRACKING` was set to `false` + +### Shopping list fixes +- Optimized the new compact view (there was a little too much white space at the sides of the page) diff --git a/public/viewjs/consume.js b/public/viewjs/consume.js index 601b2f00..70f622d3 100644 --- a/public/viewjs/consume.js +++ b/public/viewjs/consume.js @@ -20,10 +20,6 @@ { jsonData.location_id = $("#location_id").val(); } - else - { - jsonData.location_id = 1; - } if (Grocy.FeatureFlags.GROCY_FEATURE_FLAG_RECIPES && Grocy.Components.RecipePicker.GetValue().toString().length > 0) { diff --git a/public/viewjs/inventory.js b/public/viewjs/inventory.js index 47ad6365..5bed121c 100644 --- a/public/viewjs/inventory.js +++ b/public/viewjs/inventory.js @@ -21,10 +21,7 @@ { jsonData.location_id = Grocy.Components.LocationPicker.GetValue(); } - else - { - jsonData.location_id = 1; - } + jsonData.price = price; var bookingResponse = null; diff --git a/public/viewjs/purchase.js b/public/viewjs/purchase.js index 0541d626..c035c054 100644 --- a/public/viewjs/purchase.js +++ b/public/viewjs/purchase.js @@ -34,10 +34,6 @@ { jsonData.location_id = Grocy.Components.LocationPicker.GetValue(); } - else - { - jsonData.location_id = 1; - } Grocy.Api.Post('stock/products/' + jsonForm.product_id + '/add', jsonData, function(result) diff --git a/views/consume.blade.php b/views/consume.blade.php index 72ffae88..b2bf4355 100644 --- a/views/consume.blade.php +++ b/views/consume.blade.php @@ -57,8 +57,6 @@