From 0499c599b81a428689ea476e46a72155d11e09ba Mon Sep 17 00:00:00 2001 From: artem-dudarev Date: Thu, 17 May 2018 15:25:04 +0200 Subject: [PATCH] Fixed corrupted decimal values --- .../Domain/Common/DynamicPropertyConverter.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/VirtoCommerce.Storefront/Domain/Common/DynamicPropertyConverter.cs b/VirtoCommerce.Storefront/Domain/Common/DynamicPropertyConverter.cs index 5be1d8b28..95d52d583 100644 --- a/VirtoCommerce.Storefront/Domain/Common/DynamicPropertyConverter.cs +++ b/VirtoCommerce.Storefront/Domain/Common/DynamicPropertyConverter.cs @@ -1,11 +1,12 @@ -using Newtonsoft.Json.Linq; +using System.Globalization; using System.Linq; +using Newtonsoft.Json.Linq; using VirtoCommerce.Storefront.Model; using coreDto = VirtoCommerce.Storefront.AutoRestClients.CoreModuleApi.Models; using platformDto = VirtoCommerce.Storefront.AutoRestClients.PlatformModuleApi.Models; namespace VirtoCommerce.Storefront.Domain -{ +{ public static class DynamicPropertyConverter { public static DynamicProperty ToDynamicProperty(this coreDto.DynamicObjectProperty propertyDto) @@ -88,7 +89,7 @@ private static DynamicPropertyDictionaryItem ToDictItem(this platformDto.Dynamic private static LocalizedString ToLocalizedString(this coreDto.DynamicPropertyObjectValue dto) { - return new LocalizedString(new Language(dto.Locale), dto.Value.ToString()); + return new LocalizedString(new Language(dto.Locale), string.Format(CultureInfo.InvariantCulture, "{0}", dto.Value)); } private static coreDto.DynamicPropertyObjectValue ToPropertyValueDto(this DynamicPropertyDictionaryItem dictItem)