1

I tried creating a view where I display user's unpublished nodes.
The view works flawlessly for super user 1, but it doesn't work for authenticated users where no nodes are displayed though the authenticated user can directly access the unpublished node and edit it.
Things I tried:
1. Try different display formats (e.g. fields, full content)
2. Removed all kinds of filters
3. Removed all kinds of access rules for the view
4. Reviewed permissions:
a. Administer content is unchecked for authenticated user
b. View own unpublished content is checked for authenticated user
c. create/edit/delete content permissions are set for authenticated user
d. Bypass content access control unchecked for authenticated user

Is this normal or this is a views' bug?

UPDATE:
I posted my question on Drupal bug tracker. It seems that a module is causing the issue. https://www.drupal.org/node/2810077 I tried creating a new Drupal 8 installation with a view that shows unpublished content and now it displays all unpublished content regardless of user's permission...

3
  • Looks like you tried a lot of options already. Maybe you can post an export of your view (views.view.[view_name].yml) and your permissions (user.role.authenticated.yml) so we can try to reproduce the problem? Commented Oct 2, 2016 at 12:32
  • Super user 1 is not beholden to any permissions.
    – Kevin
    Commented Oct 2, 2016 at 14:56
  • Did you try my solution?
    – Yuseferi
    Commented Oct 3, 2016 at 8:48

1 Answer 1

0

Try view_unpublished module and check can you see unpublished nodes.

Description: This module allows you to grant access for specific user roles to view unpublished nodes of a specific type. Access control is quite granular in this regard.

Additionally, using this module does not require any modifications to your existing URL structure.

5
  • Is that Drupal 8 ready?
    – Kevin
    Commented Oct 2, 2016 at 18:33
  • @Kevin not yet, but do you know another solution ?
    – Yuseferi
    Commented Oct 2, 2016 at 18:46
  • I suppose you could overload the access check, compare owners, role and status.
    – Kevin
    Commented Oct 2, 2016 at 19:46
  • @Kevin it seems he is not a developer and looking for non-programmatically solution
    – Yuseferi
    Commented Oct 3, 2016 at 8:47
  • @zhilevan I'm not looking for non-programmatical solution. I'm trying to use a Drupal feature which is showing incorrect results Commented Oct 5, 2016 at 14:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.