Howto create a view of node + list of node with nodereference to it?

mattyoung - September 23, 2009 - 20:13

I have content types 'class' and 'class_session', 'class' contains information of a class, 'class_session' has a nodereference to 'class' + its time, instructors, signup, etc.

I want to create a view of like this:

class                            class_session
-----                             ---------------
One leg dancing                    Session 1
                                  Session 2
                                  Session 3

Off key singing                     Session 1
                                   Session 2
                                   Session 3

each row displaying the 'class' data plus all class_session associated with this class link by the nodereference.

How can I do this?

Is creating views_handler_field() the way?

Is there any documentation on this?

You could use the Node

nevets - September 23, 2009 - 20:17

You could use the Node Referrer module to had a field to the class type that allows for a back reference from a class session. I know this allow you to show the back references when viewing a class node and am guessing the field is available in a view.

_

WorldFallz - September 23, 2009 - 20:25

You might also want to take a look at http://www.lullabot.com/articles/photo-galleries-views-attach -- substitute "class" for gallery and "class session" for image and you've basically got the same setup.

_
Don't be a Help Vampire - read and abide the forum guidelines.
If you find my assistance useful, please pay it forward to your fellow drupalers.

 
 

Drupal is a registered trademark of Dries Buytaert.