Why not do as the http://drupal.org/project/savedraft module and add another button "Save as draft" or an "Publish" and "Unpublish" instead of having a tab, which is a little confusing as to how the rest of Drupal works?

Comments

simon georges’s picture

Category: feature » support
Status: Active » Fixed

I suppose you're looking for Publish button then, aren't you? ;-)

lsolesen’s picture

Category: support » feature
Status: Fixed » Active

Not really. I need the permission s from this module. But I think the tab is strange for an action.

simon georges’s picture

simon georges’s picture

As a side note, it seems "Publish button" has its own permissions as well.

lsolesen’s picture

If using a tab / button is the only difference, then maybe you should work together. I still think a button is a wiser choice for an UI.

simon georges’s picture

I think the point of this module was to be extremely fast / simple, meaning you shouldn't have to edit the node to publish it. That said, this has been opened on "Publish Button" issue queue (since "Publish Content" existed before "Publish Button" was created), see #1627700: What about "Publish Content" module?. You're welcome to propose a patch here as well, I'll gladly review it.

hansfn’s picture

FYI: I'm planning to write a patch that merges the functionality of "Publish Button" into this module. The modules are too similar to be separate ...

simon georges’s picture

Great, thanks!

pjmcghee’s picture

I have a similar question. I have a variant for the node view page for a specific content type. I use tab tamer because the tabs along the top disrupt my CSS but I still want to have the "edit" function available on the view screen for the node.

Can I change the tab into a button? write some new code and create an edit button on that screen? any advice at all would be most welcome!

johnennew’s picture

Please find attached a patch which adds an option to have a publish / unpublish button instead of tabs. This also provides the functionality asked for in #1345850: Use MENU_LOCAL_ACTION instead of MENU_LOCAL_TASK.

So the options provided by the patch are:
1. Tabs (default)
2. Button
3. Local actions (links on the view page)
4. None (just the publish/unpublish checkbox)

This patch also:
1. Cleans up DCS in the module file and starts to reduce complexity of some of the access controls - the rest can happen after applying #2040911: Add hooks to modify access control to allow other modules to make use of this functionality such as Organic Groups which refactors the access control methods.
2. Cleans up DCS in the install file, removes a left over D6 update hook and adds an update hook which moves from the old tab on/off option to the new multiple choice options preserving the websites old selection.
3. Adds a suite of tests for checkbox method and button publish methods

johnennew’s picture

Status: Active » Needs review

switching to needs review - over to you testbot.

simon georges’s picture

ceng, you now have commit access to the projet, if you want to do some changes, go ahead ;-)

johnennew’s picture

Status: Needs review » Fixed

OK, committed this to 7.x-1.x

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.