Hi,

I have a website that works with workbench moderation and I need to grant access for some administrators and Users to content moderation, in another hand I need to give access with a condition.

So the list of permissions that I need:

View all @node_type in @state
View own @node_type in @state

Edit all @node_type in @state
Edit own @node_type in @state

Delete all @node_type in @state
Delete own @node_type in @state

Overview of new access structure(access with a condition):
The user sees the last version published of content( because the node points to the last revision published) even the current version of the content is unpublished(Expired OR Draft OR Needs Review).

So what if I need to prevent View access to the last version published of content(node view page) if its current version is unpublished?

I found the following modules that don't meet the needs:

  1. workbench_moderation_state_access: Add permissions for each state only on Edit operations in addition it use
    hook_node_access() instead of hook_node_grands()
    So this module doesn't support View operation in addition it uses the hook_node_access() that not recommended see https://www.phase2technology.com/blog/drupal-7-node-access-grants-locks-...
  2. workbench_access_content_type

Can someone help me to figure out with module or patch or any other solution?

Thanks

CommentFileSizeAuthor
#8 LWMSP.jpg9.03 KBm.attar
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Mhammad Attar created an issue. See original summary.

Mhammad Attar’s picture

Issue summary: View changes
Mhammad Attar’s picture

I added a sandbox module that add permissions by @content_type in @state in all operations(View|Edit|Delete)
https://www.drupal.org/sandbox/mhammadattar/2789129

m.attar’s picture

Issue summary: View changes
Mhammad Attar’s picture

Issue summary: View changes
Mhammad Attar’s picture

Issue summary: View changes
Mhammad Attar’s picture

m.attar’s picture

FileSize
9.03 KB