The permissions settings for node reference do not respect the permissions of the user since they have a hard coded "NODE_PUBLISHED" check for "status".

This creates a problem for creating draft content for review / development. The unpublished content does not show up in the rendered form.

We have a permission for viewing unpublished content (for content creators and reviewers) and node reference should respect this. If the user can see the content otherwise, it should render when it is a field.

I will attach a patch in the next comment where I have removed this line to fix the issue.

Comments

damontgomery’s picture

Here is the patch.

Tested with Drupal 7.12 and 7.x-2.0 of References.

spleshka’s picture

Priority: Normal » Major
StatusFileSize
new714 bytes

I've got similar bug: every user can choose unpublished nodes in select list. It is wrong! Here is another patch that solves this problem.

GrandmaGlassesRopeMan’s picture

GrandmaGlassesRopeMan’s picture

damontgomery’s picture

Status: Needs review » Fixed

This seems to be fixed in 2.1 since the change causing the issue was reverted.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.