How to link a collection of custom IContent types under a page?
-
Without having tried it my self bit could you use a property of type LinkItemCollection?
You could then use IPermanentLinkMapper to get permanentlinks to your items which you then can store in the collection.
We have in our backlog a story that we should support collections of types (e.g. String, ContentReference etc) but I cant promise anything if/when that will be available.
-
-
I didn't think of ContentArea but of course that is a much better alternative. It is much nicer to work with than LinkItemCollection.
-
Ah. Thank you. ContentArea seems to do the trick.
Next thing is that editor needs to be able to drag my custom Service contents to the ContentArea. I thought about writing a gui plugin which lists all the custom IContents on the site, just like the one that lists Blocks. I'll get back to you if and when I stumble to any new problems :)-Marko
Hello,
I'm a bit lost here with this new EpiServer 7 and its IContent model. Could someone please explain me some things.
Here's an example what I'm trying to do. I want a list of services somewhere and I need to be able to create (service) stations and link services to them.
In Epi6 I would've created Service-class as Page Type and then custom property to hold a list of Services but now in Epi7 I don't know how to do this. I want to create Service as IContent, since it doesn't have a template and is never rendered to user.
I went through the API but found nothing like ContentReferenceCollection, allthough I found ContentReference. I tried to use PageReferenceCollection but that keeps saying me that it cannot be mapped to a PropertyDefinitionType. I'm not even sure if this is the correct way to link custom IContent stuff to the pages.
Any help will be greatly appreciated.