Quantcast
Channel: Developer to developer
Viewing all articles
Browse latest Browse all 9076

Display SelectMany-items in PropertyList:s with SelectItem:s Text-part when multiple items selected

$
0
0

When having a PropertyList with Selection Factories, like this.

[PropertyDefinitionTypePlugIn]
public class FooBarSettingsPropertyList : PropertyList<FooBarSettings>
{
}
public class FooBarSettings
{
    [SelectOne(SelectionFactoryType = typeof(FooSelectionFactory))]
    public virtual string FooSelection { get; set; }
    [SelectMany(SelectionFactoryType = typeof(BarSelectionFactory))]
    public virtual string BarSelection { get; set; }
}

We have an ok presentation of FooSelection and BarSelection when selecting only one item, the Text part of SelectItem is presented.

However, when we select many Bar:s, so that there is the ID(a string in GUID-format) comma-separated stored in DB, we are seeing the comma-separated string of GUID:s, not the comma-separated presentation of Text-parts of the SelectionFactory.

Expected output would be something like Kaka, Baka, Smaka, Foo, Bar or something.

I don't think we should be expected to implement Dojo/Dijit stuff to fix this, maybe it should work using string[] or List<string>, or some extra UIHint, or it should simply just work out-of-the-box.


Viewing all articles
Browse latest Browse all 9076

Trending Articles