Last updated November 15, 2012. Created by wusel on April 28, 2012.
Edited by calliandra, Sam Moore. Log in to edit this page.

This Cookbook shows, how you can have some different Event-types in one Event-Calendar for Drupal 7 (http://drupal.org/node/1477602). The Event-calendar shows every user only the for his role(s) allowed Event-types. You can use this e.g. to differ in internal, administrative and public Events.

Cookbook:

Step 1: Build the Event-types

  1. If not enabled, (download, install to your modules-path like sites/all/modules and) enable the Module "References" (http://drupal.org/project/references).
  2. If not enabled, download and install the Content Access module http://drupal.org/project/content_access
  3. On the first event-type, you create a Date-field.
  4. Configure the Date-field suitably (especially set "Time zone handling" to "No time zone conversion" [1]), before you use an Event-type by adding content. After adding content to one Event-type, you cannot change the setting of these Date-fields.
  5. On the next Event-type Add existing field, select the Date-field you created from the "Field to share" popup. The Label doesn't matter.
  6. And so on for the next event-type.
  7. Visit 'http://example.com/admin/structure/types/manage/<your event type>/access' and set the permissions for an event-type.

In the module Calendar you have only ONE date-field from several event-types (and no problems in the calendar).

Step 2: Add one or more events per Event-type

To test:
Click several times on "Add content" in the Navigation-menu, select the Event-type, add Title, Date/Time and Body as you like, Click on "Save".

Step 3: View the event-calendar

Visit 'http://example.com/calendar-node-field-event-date'.
Hint:
Login as an (test-)user from another user-group to view the visible events.

Good luck!

Looking for support? Visit the Drupal.org forums, or join #drupal-support in IRC.

Comments

As I already had the Entity Reference Module installed, and the Reference page mentions its probable deprecation in favor of it, I went ahead and tried this using Entity Reference.
This works just fine!

What is the point of References or Entity Reference here? Although I have Entity Reference module installed for other purposes in my site, it is not mentioned why I need it for this specific cookbook.

This is a Cookbook, which shows how you can do something.

Feel free to change one module with another compareable, like you can read in Update re: Module dependencies. I have never tested this, so I cannot say this is ok (and put it in the Cookbook).
But I think, this may be ok.

[Added]
You need one of these modules for 'Add existing field'. You can find this info, if you try this cookbook (always on a new drupal-install) without these modules!
[/Added]

Wusel