November Happy Hour will be moved to Thursday December 5th.

IList<string> still not working in with CollectionEditor objects

Vote:
 

The bug fixed in EPiServer.CMS.UI 12.19.0 (CMS-27369) still appears to not work for CollectionEditorDescriptor.

Here's a trimmed snippet that should illustrate the problem:

    [ContentType(DisplayName = "Bar Chart")]
    public class BarChartBlock : BlockData
    {
        [CultureSpecific]
        [Display(Name = "Title", GroupName = SystemTabNames.Content, Order = 10)]
        public virtual string Title { get; set; }

        [CultureSpecific]
        [Display(Name = "Data Labels", GroupName = SystemTabNames.Content, Order = 20)]
        public virtual IList<string> DataLabels { get; set; }

        [CultureSpecific]
        [Display(Name = "Data Sets", GroupName = SystemTabNames.Content, Order = 30)]
        [EditorDescriptor(EditorDescriptorType = typeof(CollectionEditorDescriptor<BarChartDataSet>))]
        public virtual IList<BarChartDataSet> DataSets { get; set; }
    }

    public class BarChartDataSet
    {
        [CultureSpecific]
        [Required]
        [Display(Name = "Label", GroupName = SystemTabNames.Content, Order = 10)]
        public virtual string Label { get; set; }

        [Display(Name = "Values", GroupName = SystemTabNames.Content, Order = 20)]
        public virtual IList<string> Values { get; set; }
    }

    [PropertyDefinitionTypePlugIn(DisplayName = "Bar Chart Data Set")]
    public class BarChartDataSetProperty : PropertyList<BarChartDataSet> { }

The Item Details modal currently still shows Values as a textarea:

#302280
May 24, 2023 13:35
Matthew Jimenez - Jun 05, 2023 20:24
This might be bug CMS-27855 - hard to tell as it lacks a description
Vote:
 

Tested this against an updated copy of Foundation and it fails there as well.

#302284
May 24, 2023 16:34
Vote:
 

I think according to this - https://world.optimizely.com/blogs/bartosz-sekula/dates/2023/1/official-list-property-support/ They are more plain now. Just don't need EditorDescriptor and PropertyList at all.

#302334
May 25, 2023 13:08
Matthew Jimenez - May 25, 2023 13:14
A new feature to have this be block-based was added, but the old mechanism still exists. I do not believe there is a way to transition existing content. However, the addition of the new feature is what caused this new bug for us.
Vote:
 

I can confirm that this issue was CMS-27855, and is fixed in EPiServer.CMS.UI 12.21.0.

However, due to a number of other changes including inline blocks and admin updates, I'll need to hold off on updating for the moment.

#304545
Jul 03, 2023 22:23
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.