На днях при редактировании свойств товаров в административной панели (версии 3.7) столкнулся с проблемой точки в десятичных числах при выборе русского языка (culture ru-ru). Как выяснилось, фильтр использования admin-панели в Global.asax.cs может работать правильно лишь в случае совпадения номеров локального и внешнего http портов сайта, что скорее является исключением, а не правилом. Использование .Contains("/admin"), возможно, решит проблему?
Those url which don't starts with admin find this kind of issue. You can solve this issue by writing this code in your controller. var culture = new CultureInfo("en-US"); Thread.CurrentThread.CurrentCulture = culture; Thread.CurrentThread.CurrentUICulture = culture;
In the Global.asax.cs file replace the line: if (webHelper.GetThisPageUrl(false).StartsWith(string.Format("{0}admin", webHelper.GetStoreLocation()),StringComparison.InvariantCultureIgnoreCase))
on: if (webHelper.GetThisPageUrl(false).Contains("/admin"))
and the problem is fixed for all who do not use to bind site local port 80.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.