05-03-2007 05:59 AM
05-04-2007 07:44 AM
/*
* (non-Javadoc)
* @see org.alfresco.web.bean.workflow.ManageTaskDialog#getAdditionalButtons()
*/
public List<DialogButtonConfig> getAdditionalButtons()
{
List<DialogButtonConfig> buttons = null;
if (this.task != null)
{
// get the transitions available from this task and
// show them in the dialog as additional buttons
this.transitions = this.task.path.node.transitions;
boolean isPooledTask = isPooledTask();
if (isPooledTask || this.transitions != null)
{
buttons = new ArrayList<DialogButtonConfig>(this.transitions.length + 1);
if (isPooledTask)
{
if (this.taskNode.getProperties().get(ContentModel.PROP_OWNER) == null)
{
buttons.add(new DialogButtonConfig("button_take_ownership", null, "take_ownership",
"#{DialogManager.bean.takeOwnership}", "false", null));
}
else
{
buttons.add(new DialogButtonConfig("button_return_to_pool", null, "return_ownership",
"#{DialogManager.bean.returnOwnership}", "false", null));
}
}
//ADDED A TEST ON OWNERSHIP.
if (this.isOwnedByCurrentUser() && this.transitions != null)
{
for (WorkflowTransition trans : this.transitions)
{
buttons.add(new DialogButtonConfig(ID_PREFIX + trans.title, trans.title, null,
"#{DialogManager.bean.transition}", "false", null));
}
}
}
}
return buttons;
}
05-07-2007 05:10 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.