Optimized product picker barcode clear handling (fixes #2745)

This commit is contained in:
Bernd Bestel
2025-05-26 20:20:40 +02:00
parent d6f3595684
commit 8560becb83
4 changed files with 4 additions and 3 deletions

View File

@@ -202,6 +202,7 @@ $('#save-purchase-button').on('click', function(e)
}
Grocy.Components.ProductAmountPicker.Reset();
Grocy.Components.ProductPicker.Clear();
$("#purchase-form").removeAttr("data-used-barcode");
$("#display_amount").attr("min", Grocy.DefaultMinAmount);
$('#display_amount').val(Grocy.UserSettings.stock_default_purchase_amount);
@@ -216,7 +217,6 @@ $('#save-purchase-button').on('click', function(e)
{
Grocy.Components.DateTimePicker.Clear();
}
Grocy.Components.ProductPicker.SetValue('');
if (Grocy.FeatureFlags.GROCY_FEATURE_FLAG_STOCK_PRICE_TRACKING)
{
Grocy.Components.ShoppingLocationPicker.SetValue('');