OpenWaves GenericListProperty in 7.5


I've been porting a few of the OpenWaves EPiserver properties to 7.5 and everything has been going well until I gave the GenericList a shot. The (main) problem is the following line.

var metadataViewModel = MetadataViewModel.CreateFromModelMetadata(modelMetadata as ExtendedMetadata, localizationService);

The MetadataViewModel has been deprecated(?) in 7.5 and been replaced with (as far as i can understand it) the MetadataStoreModel. This class is unfortunately missing the CreateFromModelMetadata method and I have no clue how to fix this. :-/

If anyone successfully ported the genericlist to 7.5 I'd love to hear about how you did it. =)

Jan 20, 2014 9:16

Did you solve this somehow? I would love to have a property of generic blocks!

Jan 30, 2014 14:26

Isn't that a ContentArea?

Jan 30, 2014 14:30

Hm, yes that might work;

Initially I needed a "list property" where each property in the list models an image with link, thumbnail, texts etc. I have successfully used EPiImageGallery for this purpose, but I needed something more flexible and "more compatible" with EPiServer 7+. So I thought of a property of type IEnumerable<MyImageBlock> together with an easy edit interface where you add/remove/edit MyImage blocks.

But you are absolutely right - ContentArea is pretty much what I'm looking for! Especially now (7.5) when you can easily restrict the content type of a ContentArea. I have not yet worked with the ContentArea type programatically, but it should be easy enough to play with the ContentArea.Items collection and get hold of block data via ContentAreaItem.GetContent().

Thank you for getting me on the right track Mark, and sorry if hijacked this thread :x

Jan 30, 2014 21:19

No worries, and I don't think you hijacked the thread :)

Jan 30, 2014 21:26
* 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.