Case of the Week - documentation

Documentation about the "Case of the Week" system.

Overview

When a "Case of the Week" is posted, Emed Residents will be able to log in to the site, view the Case, and comment on it. Seven days after the Case is posted, the "Outcome" field will become visible to Residents.

(Emed Residents are Drupal users who have the role "emed resident" and do not have any other roles.)

How It Works

When a node of the content type "Case of the Week" is created, it is Unpublished by default. Residents do not have the "administer nodes" permission and hence cannot access unpublished content.

Each COTW node has a "Publish date," and the system will change the status of the node from unpublished to published at that time (within an hour of the exact date/time). Now, Residents can view and comment on the Case, with the exception of the "Outcome" field, which is still protected.

Seven days after the node is published, the "Outcome" field will become visible to Residents.

More details

The cotw node has a "Outcome Visible?" field.

The module will set this field to "Yes" if 7 days or more after Publish Date.

The editor/owner can set it to "Yes" earlier than that if desired.

Residents have the permission "view COTW Outcome if visible." When they view a COTW node, the module gets their permissions, and checks the value of the field on the node. If the user has the right permissions, and the field says "Yes," they can see the Outcome.


What is Displayed Where

There is a block in the right sidebar showing the most recently published Case of the Week. Right now this block is visible only on this page: "Margrit Test"

There is a list of Cases on the list page

There is also a more detailed Administrative List of COTW nodes, restricted by role.