Portal Engine Questions on portal engine and web parts.
Version 6.x > Portal Engine > nested repeater with content View modes: 
User avatar
Member
Member
jheavner-ce - 3/12/2012 6:26:34 PM
   
nested repeater with content
I have a custom doctype of Event and one of the fields in my Event type is a LocationID that is a foreign key to another custom doctype of Location. Since Locations are generic (used by many events) they don't live in the content tree with the event but live under a Locations node. When I display an Event I need to also display the Locations that go along with it. I tried using a Nested Repeater but it seems like the nested data needs to live in the tree under the parent. I looked at the Universal viewer with custom query web part but I haven't been able to find enough documentation to do anything with the control.

Can someone please tell me what I need to do to make this work?

User avatar
Member
Member
jheavner-ce - 3/12/2012 6:33:27 PM
   
RE:nested repeater with content
As an aside, I could find the related Location data using just a custom query that selects against my Location doctype and joins back to my Event type on a given NodeAliasPath and then tying the results to repeater that's tied to that query.

This just feels like a backward approach. I'd rather do it without having to write custom SQL.

User avatar
Kentico Consulting
Kentico Consulting
kentico_borisp - 3/15/2012 7:48:53 AM
   
RE:nested repeater with content
Hello,

You could use a repeater displaying the locations with a custom where condition, which would display only locations for the current document according to your foreign key.
Another approach would be to use the hierarchical viewer web part which is also faster as multiple repeaters displayed inside of each other.

Best regards,
Boris Pocatko