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

Is it "safe" to use the generic PropertyList?

Vote:
 

Hi!

Would you say it's "safe" to use the generic PropertyList?

In the developer documentation it says the following:

This topic describes unsupported functionality in Episerver CMS. Episerver recommends using ContentArea and Blocks for lists of complex objects. Using PropertyList<T> together with complex types requires additional custom functionality to fully ensure data consistency, portability and functionality.

I'm not so keen on investing a lot of time in using the generic PropertyList if it's to be deprecated.

However, it seems like it would be easier to work with the property list - for editors - rather than blocks.

#204404
May 31, 2019 8:40
Vote:
 

Thanks Ollie!

After looking at the release notes you provided a link to it must be as you say, the documentation has not been updated.

Not the first and not the last time documentation's been lagging behind (referring to documentation in general) :-)

#204412
May 31, 2019 11:10
Vote:
 

Hi,

Using simple value types, such as string, datetime (IList<string>) and so on is supported now. But complex types (IList<MyClass>) are still in beta.

#204418
May 31, 2019 15:36
Vote:
 

And to answer your question, I wouldn't be afraid of using it with complex types. Just be cautious with changing your type that is stored in the list since Episerver may not handle the migration that well. In most cases this is not a problem, and if there is, you can always override the serialization to handle it. I can't imagine that they would deprecate it.

#204419
May 31, 2019 15:40
Vote:
 

@Johan

Thanks for the info!

#204449
Jun 03, 2019 8:07
Vote:
 

PropertyList is not being deprecated, but neither is the documentation not up to date. Complex type is simply a scenario that's not supported for PropertyList and where we suggest using Blocks instead. It is however not "still in beta" as Johan is saying. The beta stamp was removed for CMS 11, but it was decided to limit it to value types and there are currently no immediate plans to add the functionality that we feel is missing to put our support behind it. It could be that we instead will focus on improving the editor experience for block editing with this scenario in mind.

So in regards to using it with complex type I would probably not be afraid of using it, but recommend that you test your implementation carefully. After all, CMS includes implementation based on it such as PropertyContentReferenceList that are supported. But know that it relies on additional implentation details to be able to provide functionality for things such as export/import, cache safety, link tracking and default values.

#204458
Jun 03, 2019 12:38
Hiep To Dinh - Jul 26, 2019 14:12
Hi Henrik,

We have problems when publishing a page has IList
Vote:
 

Hi guys,

We have problems when publishing a page has IList<T> property that EPiServer Find throws this error ( we have upgraded to the latest version for EPiServer Find recently )

An exception occurred while indexing (Content): MapperParsingException object mapping for [EventPage] with array for [TicketItems] tried to parse as array, but got EOF, is there a mismatch in types for the same field?
Event page has IList<TicketClassModel> TicketItems property like below.
[EditorDescriptor(EditorDescriptorType = typeof(CollectionEditorDescriptor<TicketClassModel>))]
public virtual IList<TicketClassModel> TicketItems { get; set; }

Do you have any idea regarding this issue?

Thanks.

#205896
Jul 26, 2019 14:13
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.