From 47a6260d27c7566fc61961e6322a3dfc0e373ef1 Mon Sep 17 00:00:00 2001 From: Bernd Bestel Date: Sat, 9 Mar 2019 17:04:34 +0100 Subject: [PATCH] Show the plural form of stock QU unit when showing purchase to stock conversion factor on purchase page when QU units are different (references #169) --- public/viewjs/purchase.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/viewjs/purchase.js b/public/viewjs/purchase.js index 0d766eda..f5b906d5 100644 --- a/public/viewjs/purchase.js +++ b/public/viewjs/purchase.js @@ -114,7 +114,7 @@ Grocy.Components.ProductPicker.GetPicker().on('change', function(e) } else { - $('#amount_qu_unit').text(productDetails.quantity_unit_purchase.name + " (" + L("will be multiplied a factor of #1 to get #2", parseInt(productDetails.product.qu_factor_purchase_to_stock).toString(), productDetails.quantity_unit_stock.name) + ")"); + $('#amount_qu_unit').text(productDetails.quantity_unit_purchase.name + " (" + L("will be multiplied a factor of #1 to get #2", parseInt(productDetails.product.qu_factor_purchase_to_stock).toString(), Pluralize(2, productDetails.quantity_unit_stock.name, productDetails.quantity_unit_stock.name_plural)) + ")"); } if (productDetails.product.allow_partial_units_in_stock == 1)