Community

complex noderefrence content profile views relationships

hi there this has been a sticky one for me. using drupal 6, content profil with auto assign role

i have the following content types universty, university_author and events, university_author is a content profile node associated with user who is able to create nodes of the type "event" (from content profile module).during registration (the point of creation of the content profile university_author)the university_author content profile node refrences the university content type so as to have the relationship --> a university_author belonging to a university x can create content type events. The challenge is to display event nodes on the university page // i followed the following tutorial http://groups.drupal.org/node/98444#comments. i successfuly managed to connect the three nodes with node references and also managed to display the event nodes on the university pages as all these nodes share an existing cck field named university_connect. The problem is that this single cck field is what i use to reference the universities on registration (on the node reference im using a view to select the university nodes)

in order to get the event nodes to display on the university page requires that they select the university (via reference on the event node) this is obviously cumbersome , so i passed arguments to this view to detect the user id to automatically know that the event node being created is by a university_author belonging to a university x. But when i do this, this view (which depends on the shared node reference) dosen't show the universities for referencing on registration. So its an either or situation, its either i have a nice node reference for universities on university_author registration at the cost of having to always select the university among a long list every time the university_author publishes an event node. Any ideas on how i can have a both.

register the university author using content profile (university_author node) node reference university and have them create events articles that with views can appear on the university page. I have had long night trying to figure this out. I will be very appreciative for any attempts at a solution. Also if there are easier ways of implementing this in drupal 7 please let me know i would be really happy.

thanks

Comments

Organic Groups?

Hello again!

It sounds like you're trying to do something similar to the Organic Groups module. Here's how it might work in your situation:

  1. Download and enable Organic Groups
  2. Look in the blocks list for a "Group details" block. Move it somewhere it can be seen (sidebar, etc).
  3. Edit the University content type and make it a "group" type.
  4. Edit the Event content type and make it a "group post" type.
  5. Create one or more University nodes. Your user will automatically join each group.
  6. From /node/add, create an Event node. Note that on the edit form, there is now an "Audience" list which lists every group your user is a member of. When you save this event, it will appear in each one of the groups you select from this Audience list.
  7. Visit a group node. Note the Group details block at the side, allowing you to create an Event by clicking a link. When you click that link, note that the Audience list is pre-populated.

Organic Groups uses Views to display the group posts associated with a group. You can modify this view to change how it works / looks.

Some other nice features of Organic Groups are that users can sign up for Groups when they register, more-granular access control over who can do what in a group (use OG User Roles if you want even-more-granular control), and groups can be Open (anyone can join), Moderated (people have to be approved before they join), By-Invite (a group member has to invite a person before they can join) or Closed (only the person who created the group can invite people).

Some disadvantages of Organic Groups are the lack of good documentation and that the Drupal 6 version is slightly brittle (you can change how certain things work, but you may run into trouble if you try to change other things). If you can, experiment with Organic Groups on a test Drupal installation so you can learn how it works.

One more thing: if you use Organic Groups for Drupal 7, use the 7.x-2.x branch... the 1.x branch turned out to be too abstract and too confusing.

You may also want to check out the Drupal Distributions named Drupal Commons, Open Atrium and OpenScholar. These projects are full Drupal sites with Organic Groups installed and configured out-of-the-box, so you can get a website up-and-running really quickly (just add content, theme and you're done).

Thank you for taking your

Thank you for taking your time on this, i guess the question then is, how does one make the content created by user registered in certain group appear in all or some of the group nodes

let me give you an example, sorry for shifting the case study.
a user registers on to the site and selects a group area ie Toronto, this user(shop keeper) adds a node of type jacket, according to your proposal, for the jacket node to appear on the Toronto page the user has to select Toronto on the groups option available on node creation. What im interested in is, for the jacket item or any nodes created by a user belonging to a group should appear on the page of that group, the system should know which group the user belongs in and be able to have views of nodes created by the user on the groups that they belong to, i have tried a couple of argument combinations on views using organic groups still havent managed. any ideas. perhaps this requires custom php argument im not sure whatever the case let me know, if you have understood my dilema n if u have any thoughts on this, once again thank you for taking your time on this, it means a lot.

cheers