AB3649 - Refactored services injected into ctor instead of methods
This commit is contained in:
@@ -59,12 +59,12 @@ namespace Umbraco.Core.PropertyEditors
|
||||
/// <summary>
|
||||
/// Converts a property value to a value for the editor.
|
||||
/// </summary>
|
||||
object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null);
|
||||
object ToEditor(IProperty property, string culture = null, string segment = null);
|
||||
|
||||
// TODO: / deal with this when unplugging the xml cache
|
||||
// why property vs propertyType? services should be injected! etc...
|
||||
IEnumerable<XElement> ConvertDbToXml(IProperty property, IDataTypeService dataTypeService, ILocalizationService localizationService, bool published);
|
||||
XNode ConvertDbToXml(IPropertyType propertyType, object value, IDataTypeService dataTypeService);
|
||||
string ConvertDbToString(IPropertyType propertyType, object value, IDataTypeService dataTypeService);
|
||||
IEnumerable<XElement> ConvertDbToXml(IProperty property, bool published);
|
||||
XNode ConvertDbToXml(IPropertyType propertyType, object value);
|
||||
string ConvertDbToString(IPropertyType propertyType, object value);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,6 +20,8 @@ namespace Umbraco.Core.PropertyEditors
|
||||
/// </summary>
|
||||
public class DataValueEditor : IDataValueEditor
|
||||
{
|
||||
protected readonly IDataTypeService _dataTypeService;
|
||||
protected readonly ILocalizationService _localizationService;
|
||||
private string _view;
|
||||
|
||||
/// <summary>
|
||||
@@ -29,14 +31,18 @@ namespace Umbraco.Core.PropertyEditors
|
||||
{
|
||||
ValueType = ValueTypes.String;
|
||||
Validators = new List<IValueValidator>();
|
||||
_dataTypeService = Current.Services.DataTypeService;
|
||||
_localizationService = Current.Services.LocalizationService;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="DataValueEditor"/> class.
|
||||
/// </summary>
|
||||
public DataValueEditor(string view, params IValueValidator[] validators) // not used
|
||||
public DataValueEditor(IDataTypeService dataTypeService, ILocalizationService localizationService, string view, params IValueValidator[] validators) // not used
|
||||
: this()
|
||||
{
|
||||
_dataTypeService = dataTypeService;
|
||||
_localizationService = localizationService;
|
||||
View = view;
|
||||
Validators.AddRange(validators);
|
||||
}
|
||||
@@ -232,7 +238,7 @@ namespace Umbraco.Core.PropertyEditors
|
||||
/// The object returned will automatically be serialized into json notation. For most property editors
|
||||
/// the value returned is probably just a string but in some cases a json structure will be returned.
|
||||
/// </remarks>
|
||||
public virtual object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public virtual object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var val = property.GetValue(culture, segment);
|
||||
if (val == null) return string.Empty;
|
||||
@@ -283,7 +289,7 @@ namespace Umbraco.Core.PropertyEditors
|
||||
/// <summary>
|
||||
/// Converts a property to Xml fragments.
|
||||
/// </summary>
|
||||
public IEnumerable<XElement> ConvertDbToXml(IProperty property, IDataTypeService dataTypeService, ILocalizationService localizationService, bool published)
|
||||
public IEnumerable<XElement> ConvertDbToXml(IProperty property, bool published)
|
||||
{
|
||||
published &= property.PropertyType.SupportsPublishing;
|
||||
|
||||
@@ -301,7 +307,7 @@ namespace Umbraco.Core.PropertyEditors
|
||||
if (pvalue.Segment != null)
|
||||
xElement.Add(new XAttribute("segment", pvalue.Segment));
|
||||
|
||||
var xValue = ConvertDbToXml(property.PropertyType, value, dataTypeService);
|
||||
var xValue = ConvertDbToXml(property.PropertyType, value);
|
||||
xElement.Add(xValue);
|
||||
|
||||
yield return xElement;
|
||||
@@ -317,12 +323,12 @@ namespace Umbraco.Core.PropertyEditors
|
||||
/// <para>Returns an XText or XCData instance which must be wrapped in a element.</para>
|
||||
/// <para>If the value is empty we will not return as CDATA since that will just take up more space in the file.</para>
|
||||
/// </remarks>
|
||||
public XNode ConvertDbToXml(IPropertyType propertyType, object value, IDataTypeService dataTypeService)
|
||||
public XNode ConvertDbToXml(IPropertyType propertyType, object value)
|
||||
{
|
||||
//check for null or empty value, we don't want to return CDATA if that is the case
|
||||
if (value == null || value.ToString().IsNullOrWhiteSpace())
|
||||
{
|
||||
return new XText(ConvertDbToString(propertyType, value, dataTypeService));
|
||||
return new XText(ConvertDbToString(propertyType, value));
|
||||
}
|
||||
|
||||
switch (ValueTypes.ToStorageType(ValueType))
|
||||
@@ -330,11 +336,11 @@ namespace Umbraco.Core.PropertyEditors
|
||||
case ValueStorageType.Date:
|
||||
case ValueStorageType.Integer:
|
||||
case ValueStorageType.Decimal:
|
||||
return new XText(ConvertDbToString(propertyType, value, dataTypeService));
|
||||
return new XText(ConvertDbToString(propertyType, value));
|
||||
case ValueStorageType.Nvarchar:
|
||||
case ValueStorageType.Ntext:
|
||||
//put text in cdata
|
||||
return new XCData(ConvertDbToString(propertyType, value, dataTypeService));
|
||||
return new XCData(ConvertDbToString(propertyType, value));
|
||||
default:
|
||||
throw new ArgumentOutOfRangeException();
|
||||
}
|
||||
@@ -343,7 +349,7 @@ namespace Umbraco.Core.PropertyEditors
|
||||
/// <summary>
|
||||
/// Converts a property value to a string.
|
||||
/// </summary>
|
||||
public virtual string ConvertDbToString(IPropertyType propertyType, object value, IDataTypeService dataTypeService)
|
||||
public virtual string ConvertDbToString(IPropertyType propertyType, object value)
|
||||
{
|
||||
if (value == null)
|
||||
return string.Empty;
|
||||
|
||||
@@ -560,7 +560,7 @@ namespace Umbraco.Core.Services.Implement
|
||||
var propertyEditor = Current.PropertyEditors[propertyType.PropertyEditorAlias];
|
||||
return propertyEditor == null
|
||||
? Array.Empty<XElement>()
|
||||
: propertyEditor.GetValueEditor().ConvertDbToXml(property, _dataTypeService, _localizationService, published);
|
||||
: propertyEditor.GetValueEditor().ConvertDbToXml(property, published);
|
||||
}
|
||||
|
||||
// exports an IContent item descendants.
|
||||
|
||||
@@ -236,7 +236,6 @@
|
||||
<Compile Include="Models\IDataValueEditor.cs" />
|
||||
<Compile Include="Models\Identity\IdentityMapDefinition.cs" />
|
||||
<Compile Include="Models\Identity\UserLoginInfoWrapper.cs" />
|
||||
<Compile Include="Models\IMedia.cs" />
|
||||
<Compile Include="Models\IMediaType.cs" />
|
||||
<Compile Include="Models\IMember.cs" />
|
||||
<Compile Include="Models\IMemberType.cs" />
|
||||
@@ -295,8 +294,6 @@
|
||||
<Compile Include="Services\Changes\ContentTypeChangeExtensions.cs" />
|
||||
<Compile Include="Services\IDataTypeService.cs" />
|
||||
<Compile Include="Services\IEntityService.cs" />
|
||||
<Compile Include="Services\IFileService.cs" />
|
||||
<Compile Include="Services\IMacroService.cs" />
|
||||
<Compile Include="Services\IMembershipMemberService.cs" />
|
||||
<Compile Include="Services\INotificationService.cs" />
|
||||
<Compile Include="Services\IPackagingService.cs" />
|
||||
|
||||
@@ -8,6 +8,7 @@ using Umbraco.Core.Logging;
|
||||
using Umbraco.Core.Models;
|
||||
using Umbraco.Core.PropertyEditors;
|
||||
using Umbraco.Core.Services;
|
||||
using Umbraco.Core.Services.Implement;
|
||||
using Umbraco.Tests.TestHelpers;
|
||||
|
||||
namespace Umbraco.Tests.Models
|
||||
@@ -35,9 +36,12 @@ namespace Umbraco.Tests.Models
|
||||
var factory = Mock.Of<IFactory>();
|
||||
Current.Factory = factory;
|
||||
|
||||
var dataTypeService = Mock.Of<IDataTypeService>();
|
||||
var localizationService = Mock.Of<ILocalizationService>();
|
||||
|
||||
var dataEditors = new DataEditorCollection(new IDataEditor[]
|
||||
{
|
||||
new DataEditor(Mock.Of<ILogger>()) { Alias = "editor", ExplicitValueEditor = new DataValueEditor("view") }
|
||||
new DataEditor(Mock.Of<ILogger>()) { Alias = "editor", ExplicitValueEditor = new DataValueEditor(dataTypeService, localizationService, "view") }
|
||||
});
|
||||
var propertyEditors = new PropertyEditorCollection(dataEditors);
|
||||
|
||||
@@ -46,7 +50,6 @@ namespace Umbraco.Tests.Models
|
||||
.Setup(x => x.Configuration)
|
||||
.Returns(null);
|
||||
|
||||
var dataTypeService = Mock.Of<IDataTypeService>();
|
||||
Mock.Get(dataTypeService)
|
||||
.Setup(x => x.GetDataType(It.IsAny<int>()))
|
||||
.Returns<int>(x => dataType);
|
||||
@@ -75,7 +78,7 @@ namespace Umbraco.Tests.Models
|
||||
// 1. if exact is set to true: culture cannot be null when the ContentVariation.Culture flag is set
|
||||
// 2. if wildcards is set to false: fail when "*" is passed in as either culture or segment.
|
||||
// 3. ContentVariation flag is ignored when wildcards are used.
|
||||
// 4. Empty string is considered the same as null
|
||||
// 4. Empty string is considered the same as null
|
||||
|
||||
#region Nothing
|
||||
|
||||
@@ -141,7 +144,7 @@ namespace Umbraco.Tests.Models
|
||||
#endregion
|
||||
|
||||
#region CultureAndSegment
|
||||
|
||||
|
||||
Assert4B(ContentVariation.CultureAndSegment, null, null, false, true, false, true);
|
||||
Assert4B(ContentVariation.CultureAndSegment, null, "", false, true, false, true);
|
||||
Assert4B(ContentVariation.CultureAndSegment, null, "*", false, false, false, true);
|
||||
@@ -163,7 +166,7 @@ namespace Umbraco.Tests.Models
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Asserts the result of <see cref="ContentVariationExtensions.ValidateVariation(ContentVariation, string, string, bool, bool, bool)"/>
|
||||
/// Asserts the result of <see cref="ContentVariationExtensions.ValidateVariation(ContentVariation, string, string, bool, bool, bool)"/>
|
||||
/// </summary>
|
||||
/// <param name="variation"></param>
|
||||
/// <param name="culture"></param>
|
||||
|
||||
@@ -25,7 +25,7 @@ namespace Umbraco.Tests.PropertyEditors
|
||||
/// to cache. Now we always just deal with strings and we'll keep the tests that show that.
|
||||
/// </remarks>
|
||||
[TestFixture]
|
||||
public class MultiValuePropertyEditorTests
|
||||
public class MultiValuePropertyEditorTests
|
||||
{
|
||||
[Test]
|
||||
public void DropDownMultipleValueEditor_Format_Data_For_Cache()
|
||||
@@ -51,7 +51,7 @@ namespace Umbraco.Tests.PropertyEditors
|
||||
|
||||
var valueEditor = dataType.Editor.GetValueEditor();
|
||||
((DataValueEditor) valueEditor).Configuration = dataType.Configuration;
|
||||
var result = valueEditor.ConvertDbToString(prop.PropertyType, prop.GetValue(), dataTypeService);
|
||||
var result = valueEditor.ConvertDbToString(prop.PropertyType, prop.GetValue());
|
||||
|
||||
Assert.AreEqual("Value 1,Value 2,Value 3", result);
|
||||
}
|
||||
@@ -78,7 +78,7 @@ namespace Umbraco.Tests.PropertyEditors
|
||||
var prop = new Property(1, new PropertyType(dataType));
|
||||
prop.SetValue("Value 2");
|
||||
|
||||
var result = dataType.Editor.GetValueEditor().ConvertDbToString(prop.PropertyType, prop.GetValue(), dataTypeService);
|
||||
var result = dataType.Editor.GetValueEditor().ConvertDbToString(prop.PropertyType, prop.GetValue());
|
||||
|
||||
Assert.AreEqual("Value 2", result);
|
||||
}
|
||||
|
||||
@@ -52,7 +52,7 @@ namespace Umbraco.Tests.PropertyEditors
|
||||
ValueType = ValueTypes.String
|
||||
};
|
||||
|
||||
var result = valueEditor.ToEditor(prop, new Mock<IDataTypeService>().Object);
|
||||
var result = valueEditor.ToEditor(prop);
|
||||
Assert.AreEqual(isOk, !(result is string));
|
||||
}
|
||||
|
||||
@@ -142,7 +142,7 @@ namespace Umbraco.Tests.PropertyEditors
|
||||
ValueType = valueType
|
||||
};
|
||||
|
||||
var result = valueEditor.ToEditor(prop, new Mock<IDataTypeService>().Object);
|
||||
var result = valueEditor.ToEditor(prop);
|
||||
Assert.AreEqual(expected, result);
|
||||
}
|
||||
|
||||
@@ -158,7 +158,7 @@ namespace Umbraco.Tests.PropertyEditors
|
||||
var prop = new Property(1, new PropertyType("test", ValueStorageType.Decimal));
|
||||
prop.SetValue(value);
|
||||
|
||||
var result = valueEditor.ToEditor(prop, new Mock<IDataTypeService>().Object);
|
||||
var result = valueEditor.ToEditor(prop);
|
||||
Assert.AreEqual("12.34", result);
|
||||
}
|
||||
|
||||
@@ -173,7 +173,7 @@ namespace Umbraco.Tests.PropertyEditors
|
||||
var prop = new Property(1, new PropertyType("test", ValueStorageType.Decimal));
|
||||
prop.SetValue(string.Empty);
|
||||
|
||||
var result = valueEditor.ToEditor(prop, new Mock<IDataTypeService>().Object);
|
||||
var result = valueEditor.ToEditor(prop);
|
||||
Assert.AreEqual(string.Empty, result);
|
||||
}
|
||||
|
||||
@@ -189,7 +189,7 @@ namespace Umbraco.Tests.PropertyEditors
|
||||
var prop = new Property(1, new PropertyType("test", ValueStorageType.Date));
|
||||
prop.SetValue(now);
|
||||
|
||||
var result = valueEditor.ToEditor(prop, new Mock<IDataTypeService>().Object);
|
||||
var result = valueEditor.ToEditor(prop);
|
||||
Assert.AreEqual(now.ToIsoString(), result);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -71,7 +71,7 @@ namespace Umbraco.Web.Models.Mapping
|
||||
dest.Culture = culture;
|
||||
|
||||
// if no 'IncludeProperties' were specified or this property is set to be included - we will map the value and return.
|
||||
dest.Value = editor.GetValueEditor().ToEditor(property, DataTypeService, culture);
|
||||
dest.Value = editor.GetValueEditor().ToEditor(property, culture);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
Validators.Add(new DateTimeValidator());
|
||||
}
|
||||
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture= null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture= null, string segment = null)
|
||||
{
|
||||
var date = property.GetValue(culture, segment).TryConvertTo<DateTime?>();
|
||||
if (date.Success == false || date.Result == null)
|
||||
|
||||
@@ -115,7 +115,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
/// <param name="culture"></param>
|
||||
/// <param name="segment"></param>
|
||||
/// <returns></returns>
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var val = property.GetValue(culture, segment);
|
||||
if (val == null) return string.Empty;
|
||||
|
||||
@@ -32,7 +32,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
/// This is called to merge in the prevalue crops with the value that is saved - similar to the property value converter for the front-end
|
||||
/// </summary>
|
||||
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var val = property.GetValue(culture, segment);
|
||||
if (val == null) return null;
|
||||
@@ -47,7 +47,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
value = new ImageCropperValue { Src = val.ToString() };
|
||||
}
|
||||
|
||||
var dataType = dataTypeService.GetDataType(property.PropertyType.DataTypeId);
|
||||
var dataType = _dataTypeService.GetDataType(property.PropertyType.DataTypeId);
|
||||
if (dataType?.Configuration != null)
|
||||
value.ApplyConfiguration(dataType.ConfigurationAs<ImageCropperConfiguration>());
|
||||
|
||||
@@ -161,7 +161,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
}
|
||||
|
||||
|
||||
public override string ConvertDbToString(IPropertyType propertyType, object value, IDataTypeService dataTypeService)
|
||||
public override string ConvertDbToString(IPropertyType propertyType, object value)
|
||||
{
|
||||
if (value == null || string.IsNullOrEmpty(value.ToString()))
|
||||
return null;
|
||||
@@ -172,7 +172,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
return val;
|
||||
|
||||
// more magic here ;-(
|
||||
var configuration = dataTypeService.GetDataType(propertyType.DataTypeId).ConfigurationAs<ImageCropperConfiguration>();
|
||||
var configuration = _dataTypeService.GetDataType(propertyType.DataTypeId).ConfigurationAs<ImageCropperConfiguration>();
|
||||
var crops = configuration?.Crops ?? Array.Empty<ImageCropperConfiguration.Crop>();
|
||||
|
||||
return JsonConvert.SerializeObject(new
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
_logger = logger ?? throw new ArgumentNullException(nameof(logger));
|
||||
}
|
||||
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var value = property.GetValue(culture, segment)?.ToString();
|
||||
|
||||
@@ -118,7 +118,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
_logger.Error<MultiUrlPickerValueEditor>("Error getting links", ex);
|
||||
}
|
||||
|
||||
return base.ToEditor(property, dataTypeService, culture, segment);
|
||||
return base.ToEditor(property, culture, segment);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -95,7 +95,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
/// <remarks>
|
||||
/// The legacy property editor saved this data as new line delimited! strange but we have to maintain that.
|
||||
/// </remarks>
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var val = property.GetValue(culture, segment);
|
||||
return val?.ToString().Split(new[] {Environment.NewLine}, StringSplitOptions.RemoveEmptyEntries)
|
||||
|
||||
@@ -33,9 +33,9 @@ namespace Umbraco.Web.PropertyEditors
|
||||
/// <param name="culture"></param>
|
||||
/// <param name="segment"></param>
|
||||
/// <returns></returns>
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var json = base.ToEditor(property, dataTypeService, culture, segment).ToString();
|
||||
var json = base.ToEditor(property, culture, segment).ToString();
|
||||
return JsonConvert.DeserializeObject<string[]>(json) ?? Array.Empty<string>();
|
||||
}
|
||||
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
|
||||
#region DB to String
|
||||
|
||||
public override string ConvertDbToString(IPropertyType propertyType, object propertyValue, IDataTypeService dataTypeService)
|
||||
public override string ConvertDbToString(IPropertyType propertyType, object propertyValue)
|
||||
{
|
||||
if (propertyValue == null || string.IsNullOrWhiteSpace(propertyValue.ToString()))
|
||||
return string.Empty;
|
||||
@@ -129,9 +129,9 @@ namespace Umbraco.Web.PropertyEditors
|
||||
{
|
||||
continue;
|
||||
}
|
||||
var tempConfig = dataTypeService.GetDataType(propType.DataTypeId).Configuration;
|
||||
var tempConfig = _dataTypeService.GetDataType(propType.DataTypeId).Configuration;
|
||||
var valEditor = propEditor.GetValueEditor(tempConfig);
|
||||
var convValue = valEditor.ConvertDbToString(propType, propValues[propAlias]?.ToString(), dataTypeService);
|
||||
var convValue = valEditor.ConvertDbToString(propType, propValues[propAlias]?.ToString());
|
||||
propValues[propAlias] = convValue;
|
||||
}
|
||||
catch (InvalidOperationException)
|
||||
@@ -152,7 +152,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
|
||||
// note: there is NO variant support here
|
||||
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var val = property.GetValue(culture, segment);
|
||||
if (val == null || string.IsNullOrWhiteSpace(val.ToString()))
|
||||
@@ -197,9 +197,9 @@ namespace Umbraco.Web.PropertyEditors
|
||||
propValues[propAlias] = tempProp.GetValue()?.ToString();
|
||||
continue;
|
||||
}
|
||||
var tempConfig = dataTypeService.GetDataType(propType.DataTypeId).Configuration;
|
||||
var tempConfig = _dataTypeService.GetDataType(propType.DataTypeId).Configuration;
|
||||
var valEditor = propEditor.GetValueEditor(tempConfig);
|
||||
var convValue = valEditor.ToEditor(tempProp, dataTypeService);
|
||||
var convValue = valEditor.ToEditor(tempProp);
|
||||
propValues[propAlias] = convValue == null ? null : JToken.FromObject(convValue);
|
||||
}
|
||||
catch (InvalidOperationException)
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
/// <param name="dataTypeService"></param>
|
||||
/// <param name="culture"></param>
|
||||
/// <param name="segment"></param>
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var val = property.GetValue(culture, segment);
|
||||
if (val == null)
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace Umbraco.Web.PropertyEditors
|
||||
/// <remarks>
|
||||
/// The object returned will always be a string and if the database type is not a valid string type an exception is thrown
|
||||
/// </remarks>
|
||||
public override object ToEditor(IProperty property, IDataTypeService dataTypeService, string culture = null, string segment = null)
|
||||
public override object ToEditor(IProperty property, string culture = null, string segment = null)
|
||||
{
|
||||
var val = property.GetValue(culture, segment);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user