I am trying to retrieve an IList of an object containg an image and a url. The image is a contentreference, with the Image url hint. When trying to retrieve this through the content delivery api I am just getting a string value back
The IList is a list of this object
public class SocialMediaLink
{
[Display(Name = "Social Link Icon", Order = 10)]
[UIHint(UIHint.Image)]
public virtual ContentReference SocialLinkIcon { get; set; }
[Display(Name = "Social Link Url", Order = 20)]
[JsonConverter(typeof(UrlConverter))]
public virtual Url SocialLinkUrl { get; set; }
}
Property is like this
[Display(Name = "Social Media Links", Order = 40, GroupName = TabNames.Footer)]
[EditorDescriptor(EditorDescriptorType = typeof(CollectionEditorDescriptor<SocialMediaLink>))]
public virtual IList<SocialMediaLink> FooterListOfSocialLinkProperty { get; set; }
I have a property model
public class SocialMediaLinkPropertyModel : PropertyModel<IList<SocialMediaLink>, SocialMediaLinkProperty>
{
public SocialMediaLinkPropertyModel(SocialMediaLinkProperty type) : base(type)
{
base.Value = type.List;
}
}
and a property list
[PropertyDefinitionTypePlugIn]
public class SocialMediaLinkProperty : PropertyList<SocialMediaLink>
{
}
When I call the page in the api this is all I get.
Hi Folks,
I am trying to retrieve an IList of an object containg an image and a url. The image is a contentreference, with the Image url hint. When trying to retrieve this through the content delivery api I am just getting a string value back
The IList is a list of this object
Property is like this
I have a property model
and a property list
When I call the page in the api this is all I get.
I have a single contentreference as a property on the page which is set up the same way, but works perfectly
Anyone any idea?