Merged V2.1 to HEAD

6309: Fixed AWC-1195 - Email space users.
   6311: AWC-1378
   6319: Fixed minor caching bug
   6320, 6326: Some fixes to the raw content download servlet available on /dr
   6324: Fix for AWC-1444 (workflow history issue)
   6325: Exceptions that occur in NavigatorPluginBean now correctly logged to the console


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6720 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2007-09-10 12:58:48 +00:00
parent bf4349d64d
commit f9bad97b04
9 changed files with 74 additions and 69 deletions

View File

@@ -55,7 +55,6 @@ import org.apache.commons.logging.LogFactory;
public class UIWorkflowHistory extends SelfRenderingComponent
{
protected WorkflowInstance value = null;
protected Boolean completedMode = null;
private static final Log logger = LogFactory.getLog(UIWorkflowHistory.class);
@@ -85,17 +84,15 @@ public class UIWorkflowHistory extends SelfRenderingComponent
// standard component attributes are restored by the super class
super.restoreState(context, values[0]);
this.value = (WorkflowInstance)values[1];
this.completedMode = (Boolean)values[2];
}
@Override
public Object saveState(FacesContext context)
{
Object values[] = new Object[3];
Object values[] = new Object[2];
// standard component attributes are saved by the super class
values[0] = super.saveState(context);
values[1] = this.value;
values[2] = this.completedMode;
return values;
}
@@ -116,7 +113,7 @@ public class UIWorkflowHistory extends SelfRenderingComponent
logger.debug("Retrieving workflow history for workflow instance: " + wi);
WorkflowTaskQuery query = new WorkflowTaskQuery();
query.setActive(!getCompletedMode());
query.setActive(null);
query.setProcessId(wi.id);
query.setTaskState(WorkflowTaskState.COMPLETED);
query.setOrderBy(new WorkflowTaskQuery.OrderBy[] {
@@ -257,34 +254,4 @@ public class UIWorkflowHistory extends SelfRenderingComponent
{
this.value = value;
}
/**
* @return Returns whether the history is for a completed workflow instance
*/
public boolean getCompletedMode()
{
if (this.completedMode == null)
{
ValueBinding vb = getValueBinding("completedMode");
if (vb != null)
{
this.completedMode = (Boolean)vb.getValue(getFacesContext());
}
}
if (this.completedMode == null)
{
this.completedMode = Boolean.FALSE;
}
return this.completedMode;
}
/**
* @param completedMode Sets whether the history is for a completed workflow instance
*/
public void setCompletedMode(boolean completedMode)
{
this.completedMode = Boolean.valueOf(completedMode);
}
}

View File

@@ -36,7 +36,6 @@ import org.alfresco.web.ui.common.tag.HtmlComponentTag;
public class WorkflowHistoryTag extends HtmlComponentTag
{
private String value;
private String completedMode;
/**
* @see javax.faces.webapp.UIComponentTag#getComponentType()
@@ -62,7 +61,6 @@ public class WorkflowHistoryTag extends HtmlComponentTag
super.setProperties(component);
setStringProperty(component, "value", this.value);
setBooleanProperty(component, "completedMode", this.completedMode);
}
/**
@@ -72,7 +70,6 @@ public class WorkflowHistoryTag extends HtmlComponentTag
{
super.release();
this.value = null;
this.completedMode = null;
}
/**
@@ -84,14 +81,4 @@ public class WorkflowHistoryTag extends HtmlComponentTag
{
this.value = value;
}
/**
* Sets whether the component is showing history for a completed workflow
*
* @param completedMode
*/
public void setCompletedMode(String completedMode)
{
this.completedMode = completedMode;
}
}