Hi all,

I use Draft to edit some pages of a website. It's not just a draft usage for blog post for example as it seems to be made for. First af all, for this usage i check the "Allow draft when editing" option, it's great but in a more collaborative way, i like to view and edit drafts of other users.

So i have already add this feature in my own version of draft with :

$form['draft']['edit_all_draft'] = array(
  '#type' => 'checkbox',
  '#title' => t('Allow editing drafts of other users'),
  '#default_value' => variable_get('edit_all_draft', 0),
  '#description' => t('If checked then the module will allow you to edit drafts off all users, even if you're not the owner of the draft.'),
  );

in the admin code, and :

} elseif ($result->uid != $user->uid && !variable_get('edit_all_draft', 0) ) {

on line 124 of draft.module.

Would you maintain this simple solution ? Maybe it could be specific to the user account with a small tweak.

Best regards,
MR

Comments

mattew’s picture

sorry :

$form['draft']['edit_all_draft'] = array(
  '#type' => 'checkbox',
  '#title' => t('Allow editing drafts of other users'),
  '#default_value' => variable_get('edit_all_draft', 0),
  '#description' => t('If checked then the module will allow you to edit drafts off all users, even if you\'re not the owner of the draft.'),
);

(escape the simple quote)