Fixed that default_consume_location_id wasn't copied on copying a product (fixes #2223)

This commit is contained in:
Bernd Bestel 2023-05-12 20:48:44 +02:00
parent 8bdb74a8e0
commit 48564b5286
No known key found for this signature in database
GPG Key ID: 71BD34C0D4891300
2 changed files with 2 additions and 0 deletions

View File

@ -37,6 +37,7 @@
- Fixed that sorting by the "Value" and "Min. stock amount" columns on the stock overview page didn't work
- Fixed that the consumed amount was wrong, when consuming multiple substituted subproducts at once and when multiple/different conversion factors were involved
- Fixed that for a product's average price, only currently in-stock items were considered, not already consumed ones
- Fixed that when copying a product, the field "Default consume location" was not copied along
### Shopping list

View File

@ -430,6 +430,7 @@ if (Grocy.EditMode == "create" && GetUriParam("copy-of") != undefined)
$("#default_best_before_days_after_thawing").val(sourceProduct.default_best_before_days_after_thawing);
$("#quick_consume_amount").val(sourceProduct.quick_consume_amount);
$("#quick_open_amount").val(sourceProduct.quick_open_amount);
$("#default_consume_location_id").val(sourceProduct.default_consume_location_id);
Grocy.FrontendHelpers.ValidateForm('product-form');
},