Of course, Drupal being a great platform to extend, you can resolve this in your custom module.
In the
hook_accessfunction of your custom module, just try code similar to this:
if ($op == 'view' &&
(user_access('edit periodic updates') ||
user_access('edit own periodic updates')) &&
$node->status != 1) {
return TRUE;
}
What you are telling Drupal is if the node operation is 'view' and the user has one of the specified two role permissions and the node status is not published, then allow the view access.
Easy enough.
No comments:
Post a Comment