Closed (fixed)
Project:
Revision Moderation
Version:
5.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Reporter:
Created:
6 Dec 2007 at 23:37 UTC
Updated:
15 Apr 2008 at 22:04 UTC
Jump to comment: Most recent file
| Comment | File | Size | Author |
|---|---|---|---|
| #10 | screenshot.GIF | 25.96 KB | cwgordon7 |
| #8 | revision_moderation_05.patch | 12.95 KB | cwgordon7 |
| #6 | revision_moderation_04.patch | 12.09 KB | cwgordon7 |
| #5 | revision_moderation_02.patch | 12.37 KB | cwgordon7 |
| #3 | revision_moderation_01.patch | 9.47 KB | cwgordon7 |
Comments
Comment #1
cwgordon7 commentedSetting to patch (code needs review) for lack of a better option.
File attached:
Comment #2
cwgordon7 commentedOops, I left debug code in there:
Comment #3
cwgordon7 commentedSorry, it's as a patch now.
Comment #4
webchickA very short review, since I'm off in a second.
a) Contrary to the task description, this should actually be against the DRUPAL-5 branch rather than HEAD, since it has some additional bug fixes/features. Sorry about that. :( The patch doesn't cleanly apply to DRUPAL-5, unfortunately, but probably just minor things.
b) Don't worry about porting Views integration. Views for D6 isn't ready, so this is out of scope of the ticket. You hadn't tried this yet, but I just wanted to point this out "for the record." :)
c) The actions integration stuff needs updating to Drupal 6, and this is a bit more involved than simply removing the "if module_exists()" stuff. Without giving away too many details (since you like challenges :)) it's a new hook that needs to be implemented. You'll know it's working properly when Trigger module is enabled, and you see Revision Moderation's actions show up under admin/build/trigger/node.
Comment #5
cwgordon7 commentedPatch re-rolled for review with actions support & against DRUPAL-5 branch.
Comment #6
cwgordon7 commentedPatch re-rolled after discussion with chx on irc.
Comment #7
webchickI tested this pretty thoroughly, and confirmed that it's almost entirely there. There were only a couple of regressions:
a) Exemption is not working properly... users with administer nodes permissions are /always/ exempt from the revision moderation, regardless of whether the setting on the administer form is checked or not.
b) If, as a non-privileged user, I edit a node that has one of my existing revisions in moderation, I get the notice:
I cannot seem to duplicate this notice on content types without the revision moderation checkbox flagged.
Otherwise, tested action integration, editing with unprivileged/privileged users, etc. Fix those two things and this should be RTBC. :)
Comment #8
cwgordon7 commentedOk, this, I believe fixes problem a.
Comment #9
webchickHm. That didn't seem to fix it. I still can't get users with 'administer nodes' permissions to go through the same revision process as everyone else, regardless of the setting on the admin form.
Create a role 'admin', give that role 'administer nodes' permissions, and create a user 'blah' and add them to the admin role.
Uncheck the "Exempt admins from moderation" checkbox on the settings form.
In 5.x, upon editing a node, you get the message that your revision is pending moderation
In 6.x, it just edits it directly.
We want the behvaviour in 5.x
On a quick inspection of the code though, I'm not sure /why/ it's not working. You didn't seem to touch that line. The only thing I can think is if the menu permission is overriding it somehow, but that seems odd.
Spend another half hour or so and see if you can fix it, and if not we'll go ahead and mark it complete anyway, since it's 99.9% there. I'll have to look sometime when I have a bit more time (unfortunately, I'm leaving Wed and will be sans Internet access for about 2 weeks so I'm swamped with last-minute work stuff atm).
Comment #10
cwgordon7 commentedI was unable to duplicate the problem, even after following your instructions precisely. I get this screenshot message for a test admin with the administer nodes permission (the checkbox does not show up, and posts are forced into "pending revision" mode.)
Comment #11
add1sun commentedOk, I talked to webchick and she said go ahead and mark the google task closed and she'll continue the weird troubleshooting here.
"This message approved by webchick." ;-)
Comment #12
webchickCrap. I am SO sorry, cwgordon. I just did a fresh install and indeed was unable to reproduce the bugs I was seeing. NO idea what was messed up on my previous install, but I apologize for the false alarm.
Thanks a lot for your patience, and also your hard work on this issue. :)
Committing this in a sec.
Comment #13
(not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.
Comment #14
ogunden commentedI'd love to be able to use this, but I can't get the patch to apply cleanly to any of the released versions. Can this be released as a 6.x development release?