diff --git a/Sheaft.Application.Handlers/Commands/ProductCommandsHandler.cs b/Sheaft.Application.Handlers/Commands/ProductCommandsHandler.cs index 574f7a403..c6fd42fc3 100644 --- a/Sheaft.Application.Handlers/Commands/ProductCommandsHandler.cs +++ b/Sheaft.Application.Handlers/Commands/ProductCommandsHandler.cs @@ -381,6 +381,9 @@ private async Task> CreateProductCommandFromRowData else createProductCommand.Vat = vat; + if (string.IsNullOrWhiteSpace(quantityPerUnitStr)) + quantityPerUnitStr = "1"; + if (!decimal.TryParse(quantityPerUnitStr, NumberStyles.Any, new CultureInfo("en-US"), out decimal qtyPerUnit)) return Failed(new ValidationException(MessageKind.CreateProduct_QtyPerUnit_Invalid_Line, i)); else