Support Group v1 content

Created on 17 May 2022, about 2 years ago
Updated 12 December 2023, 7 months ago

Problem/Motivation

I believe because of the way Groups handles access control, even if you generate an access token for a piece of Group content, Groups isn't aware of this it will deny access. In my testing I could not get access_unpublished to work for any content which belongs to a group.

Steps to reproduce

Install Group, Group Node, and Access Unpublished. Setup a Group Type, and add allow content type to it. Create group content of that type. Create a link with Access Unpublished - it will result in Access Denied.

Proposed resolution

I think Group's access control model needs to be extended per documentation at https://www.drupal.org/docs/contributed-modules/group/extending-groups-a... β†’ . In that overridden access control handler, it will need to check with access_unpublished_entity_access and use that as the access result. I have implemented this as a proof of concept - will submit a PR on drupalcode.

Remaining tasks

Code review - especially permissions handling. Test coverage.

User interface changes

The proof of concept adds group level permissions so access_unpublished can be allowed per group type and group role.

API changes

N/A

Data model changes

N/A

✨ Feature request
Status

Needs review

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States msielski

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024