I have a website configured were users in "publishers" role can create/edit content and "editors" can approve it for display. If a "publisher" edits a node, a new revision is automatically made and the node is unpublished and placed back in the moderation queue for "editors" to approve.

The problem is when a vistor to the website tries to view a node that was once approved in the past, but has since been edited and moved back to the moderation queue they see the ACCESS DENIED screen.

I would like to create a module that instead of ACCESS DENIED, displays the last revision of a node that was "published" (approved by the "editor" or administrator).

I dont want to reinvent the wheel. Anyone else out their doing something simillar?

My connection to the internet is very expensive, so I cannot search much on the Drupal site to find simillar posts. Thanks in advance for responding here or pointing me to other discussions of this topic.

Comments

jsaints’s picture

Seems that there is no easy way to accomplish this without patching drupal core.

node_access function seems only to call external hooks based upon content type. There would need to be a a nodeapi type hook that would allow a custom module to change node_access return value and display the last approved revision instead of ACCESS DENIED.

sepeck’s picture

IIRC, there are two different approaches in the patch queue against Drupal core. You could dig through those and use them as a starting point.

-Steven Peck
---------
Test site, always start with a test site.
Drupal Best Practices Guide -|- Black Mountain

-Steven Peck
---------
Test site, always start with a test site.
Drupal Best Practices Guide

dkruglyak’s picture

Where are these patches?

Same goes for letting users recall the nodes they submitted from moderation queue for more editing. This is needed since they often want to change things once submitted.

cfennell’s picture

Yep, this is something I would also love to see. Have you made any progress since you last posted? If so, could you drop me a note to let me know how it went? (libsys *-[at]-* gmail.com) - or just post your results here? Thanks!

cfennell’s picture

Have a look at this module:

http://drupal.org/project/workflow

Now that I've begun to roll over to 4.7, I've noticed that there is a node_revision table. Based on what I've seen, I think it may be possible to have a non-live future draft version of a page. This looks promising.

patchak’s picture

I tried to install workflow module and I'm not sure the module could do that??

Any ideas about how to achieve that kind of fonctionnality?

Thanks

rnsi’s picture

Has there been any progress made on this? I'd like to help if I can.

patchak’s picture

Yes someone is building the module, and I could have a little help paying the fees, If you could contribute some money I would really appreciate!

Thanks

rnsi’s picture

1) How much are you looking for?
2) When will it be ready?
3) Will this cause any issues with core upgrades?
4) What are the dependencies (if any)?

patchak’s picture

The module will cost 350$ so I think you could chip in 100$ and maybe another user would like to help as well?? If not are you ready/willing to split the costs??

As fait as I know this will be a module soit should not be too hard to upgrade it when core changes.. But it depends of course if core is changed radically in the future.

It should be ready this week, maybe next week...

And finally.. I don,t know yet...I,ll try to get some more details for you!

We keep in touch then, cya

Patchak

rnsi’s picture

Do you have a description of how this would work, ie, user edits existing page... then what? If this module will solve my problems, I may be able to help. What I'm looking for is the functionality described in the origonal post - A user edits a published page, the revision is saved as a draft and the origonal page is still live. The moderator approves the draft, and it becomes the new live published page. I want to avoid using a clone process or similar. This needs to be real simple.

westin’s picture

I'm also interested in this; it seems like this is crucial to a CMS system for any web sites that involve people who aren't web publishers creating and editing content.

The workflow module looks promising, but I noticed a feature request for being able to approve edits, so I'm guessing that it doesn't yet do what's being described here (i.e. sending edited pages for approval, leaving the previous revision visible until approved).

I'm hoping someone will correct me and tell me that, in fact, this functionality is already available!

Greg

cfennell’s picture

Have a look at what webchick came up with:
http://drupal.org/project/revision_moderation

I'm really hoping this kind of functionality makes it into the core.....