Forums / Setup & design / Multi-person article-edit before publishing?

Multi-person article-edit before publishing?

Author Message

André Bischof

Monday 04 April 2005 5:20:20 am

Hello alltogether,

I have to allow editors to work on the same article, before it gets published. If they both work with drafts they don't see the content added by the other author.

Thus they would have to publish the article, but then the article can be seen by the users before its ready.

Is there a possibility that two (or more) persons can work on the same article without publishing it?

I played with workflows, but that didn't help either.

Kind regards,
André

Personal weblog and more: http://bischof.homelinux.net

Paul Borgermans

Monday 04 April 2005 6:47:26 am

Hi,

This is how I would implement this, just by using template code:

- add a boolean (checkbox) field to the article class to mark it for "public" display, for exampel "is_ready".
- in the article display (full/line) views add a check on both the boolean field and the current user groups to see if an editor is logged in and act accordingly in a {section show=....}

{* init $current user if necessary with let current_user=fetch(user,current_user)
and 
suppose the group (object id) of the editors group is 13 *}
{section show=or($current_user.groups|contains(13),$node.data_map.is_ready.content)}
{* display the article *}
{section-else}
{* do not display the article, but maybe show some kind of a message *}
{/section}

hth

-paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Xavier Dutoit

Monday 04 April 2005 6:56:29 am

Hi,

I've had a similar problem but with content spread over several nodes.

What I did was to create a new section "under construct". When the user publish the content (no save draft button), it goes to the underconstruct section. On the template for this section, I've added a button "publish" that call a custom module to change the section to the standard one.

Obvioulsy, with access rights, you can define we can read/edit content in the under construct section.

X+

http://www.sydesy.com

André Bischof

Monday 04 April 2005 8:12:02 am

Hello Paul, Xavier,

thanks first for your quick answers!

But I don't understand your solutions. As far as I understand Paul, he keeps articles from getting visible - that's nice, 'cause my editors could no save (not save draft) and the next editor can modify the article. But what about all published articles which still exist? Wouldn't they become invisible?

Xavier, if I understand you right, it is necassary to write an custom module - this is far beyond my possibilities.

I think I try Pauls solution, maybe I can solve it with a mysql update over all existing articles or modify the template language (which is new for me too) to look after the checkbox only if it exists.

I'll try that first thing tomorrow!

Thanks and kind regards,
André

Personal weblog and more: http://bischof.homelinux.net

eZ debug

Timing: Jan 18 2025 21:08:06
Script start
Timing: Jan 18 2025 21:08:06
Module start 'content'
Timing: Jan 18 2025 21:08:06
Module end 'content'
Timing: Jan 18 2025 21:08:07
Script end

Main resources:

Total runtime0.1779 sec
Peak memory usage2,048.0000 KB
Database Queries141

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0083 588.9766180.8125
Module start 'content' 0.00830.0060 769.789198.0547
Module end 'content' 0.01430.1636 867.8438526.3750
Script end 0.1778  1,394.2188 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00372.0759200.0002
Check MTime0.00150.8683200.0001
Mysql Total
Database connection0.00130.717210.0013
Mysqli_queries0.127671.72221410.0009
Looping result0.00130.74481390.0000
Template Total0.163091.610.1630
Template load0.00100.566610.0010
Template processing0.162091.061610.1620
Override
Cache load0.00070.385510.0007
Sytem overhead
Fetch class attribute can translate value0.00100.549710.0010
XML
Image XML parsing0.00030.148310.0003
General
dbfile0.00231.3057200.0001
String conversion0.00000.003930.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0002 secs