Closed (duplicate)
Project:
Views (for Drupal 7)
Version:
7.x-3.x-dev
Component:
node data
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
13 Oct 2010 at 09:58 UTC
Updated:
6 Jun 2012 at 14:11 UTC
Jump to comment: Most recent file
Comments
Comment #1
ygerasimov commentedI propose to have a check of access with _node_revision_access() and if access is denied change link to node/$nid to display the revision. Please review the patch.
Comment #2
merlinofchaos commenteddereine, can you review this?
Comment #3
dawehnerThe question is what should happen if the user has no access to the revision. Shouldn't the link disappear totally?
This could be configurable.
The code looks fine beside
(the missing space)
Comment #4
ygerasimov commentedThank you for the review. I have changed (object)array.
Comment #5
ygerasimov commentedI have added options to substitute link with link to node if user has no access to node revision. Please review the patch.
Comment #6
ygerasimov commentedTabs problem in patch fixed.
Comment #7
dawehnerCurrent usage of the handler will brake. You should either convert the existing settings or create other options. Thanks
Please use spaces instead of tabs here.
The rest looks fine in general.
Comment #8
ygerasimov commentedThank you for the review. Please check attached patch. I only add new option 'link_to_node_revision_replace' so I hope it will not break anything existing.
Comment #9
merlinofchaos commentedThat can't work. I suspsect the #tree isn't need in the latest patch anyway?
Should be
Also, while it's not your code, but since you're patching this already and it needs to go back for one more reroll, can you fix the code style on this?
The . operator on the last bit should have spaces to either side. Not sure how I keep letting these little things slip through.
Comment #10
merlinofchaos commentedComment #11
ygerasimov commentedThank you for the review. I also removed second empty line in the end of the file and added empty line before
Please review attached patch.
Comment #12
dawehnerWe could work a bit on the description
What about
The rest looks fine.
Comment #13
ygerasimov commentedYes, this description looks better.
Comment #14
dawehnerSo.
Perhaps you could find a even better one.
Comment #15
merlinofchaos commentedPatch does not apply to 3.x branch.
NOte that this is a new feature and as such I am unlikely to commit it to 2.x, so let's redo this against 3.x only.
Comment #16
keyano commentedThank you for this patch!
In the latest version of views instead of $values->{$this->aliases['nid']}
$nid = $this->get_value($values, 'nid'); is used, but everything seems to work as expected.
Comment #17
johnvThis is still the case in D7.
IMO root cause is Drupal core, which disables the page when only one revision exists. It should be dealt with there.
Tagging this as a duplicate of #808730: Show the Revisions tab/page even when only one revision exists.