diff --git a/source/generated/org/alfresco/repo/webservice/action/Condition.java b/source/generated/org/alfresco/repo/webservice/action/Condition.java index b35f5380e0..cd0cc3e3bd 100644 --- a/source/generated/org/alfresco/repo/webservice/action/Condition.java +++ b/source/generated/org/alfresco/repo/webservice/action/Condition.java @@ -183,7 +183,7 @@ public class Condition implements java.io.Serializable { elemField.setFieldName("id"); elemField.setXmlName(new javax.xml.namespace.QName("http://www.alfresco.org/ws/service/action/1.0", "id")); elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string")); - elemField.setNillable(false); + elemField.setNillable(true); typeDesc.addFieldDesc(elemField); elemField = new org.apache.axis.description.ElementDesc(); elemField.setFieldName("conditionName"); diff --git a/source/java/org/alfresco/repo/webservice/action/ActionWebService.java b/source/java/org/alfresco/repo/webservice/action/ActionWebService.java index 8291cb9d6c..252db84810 100644 --- a/source/java/org/alfresco/repo/webservice/action/ActionWebService.java +++ b/source/java/org/alfresco/repo/webservice/action/ActionWebService.java @@ -669,30 +669,33 @@ public class ActionWebService extends AbstractWebService implements ActionServic // Set the parameters NamedValue[] namedValues = webServiceAction.getParameters(); - for (NamedValue namedValue : namedValues) + if (namedValues != null) { - // Get the type of the property - DataTypeDefinition propertyType = null; - ActionDefinition actionDefintion = this.actionService.getActionDefinition(action.getActionDefinitionName()); - ParameterDefinition propertyDefintion = actionDefintion.getParameterDefintion(namedValue.getName()); - if (propertyDefintion != null) + for (NamedValue namedValue : namedValues) { - propertyType = this.dictionaryService.getDataType(propertyDefintion.getType()); + // Get the type of the property + DataTypeDefinition propertyType = null; + ActionDefinition actionDefintion = this.actionService.getActionDefinition(action.getActionDefinitionName()); + ParameterDefinition propertyDefintion = actionDefintion.getParameterDefintion(namedValue.getName()); + if (propertyDefintion != null) + { + propertyType = this.dictionaryService.getDataType(propertyDefintion.getType()); + } + + // Convert the value into the correct type + Serializable value = null; + if (propertyType != null) + { + value = (Serializable)DefaultTypeConverter.INSTANCE.convert(propertyType, namedValue.getValue()); + } + else + { + value = namedValue.getValue(); + } + + // Set the parameter + action.setParameterValue(namedValue.getName(), value); } - - // Convert the value into the correct type - Serializable value = null; - if (propertyType != null) - { - value = (Serializable)DefaultTypeConverter.INSTANCE.convert(propertyType, namedValue.getValue()); - } - else - { - value = namedValue.getValue(); - } - - // Set the parameter - action.setParameterValue(namedValue.getName(), value); } // Set the conditions @@ -752,30 +755,33 @@ public class ActionWebService extends AbstractWebService implements ActionServic // Set the condition parameters NamedValue[] namedValues = webServiceCondition.getParameters(); - for (NamedValue namedValue : namedValues) + if (namedValues != null) { - // Get the type of the property - DataTypeDefinition propertyType = null; - ActionConditionDefinition actionConditionDefintion = this.actionService.getActionConditionDefinition(actionCondition.getActionConditionDefinitionName()); - ParameterDefinition propertyDefintion = actionConditionDefintion.getParameterDefintion(namedValue.getName()); - if (propertyDefintion != null) + for (NamedValue namedValue : namedValues) { - propertyType = this.dictionaryService.getDataType(propertyDefintion.getType()); + // Get the type of the property + DataTypeDefinition propertyType = null; + ActionConditionDefinition actionConditionDefintion = this.actionService.getActionConditionDefinition(actionCondition.getActionConditionDefinitionName()); + ParameterDefinition propertyDefintion = actionConditionDefintion.getParameterDefintion(namedValue.getName()); + if (propertyDefintion != null) + { + propertyType = this.dictionaryService.getDataType(propertyDefintion.getType()); + } + + // Convert the value into the correct type + Serializable value = null; + if (propertyType != null) + { + value = (Serializable)DefaultTypeConverter.INSTANCE.convert(propertyType, namedValue.getValue()); + } + else + { + value = namedValue.getValue(); + } + + // Set the parameter + actionCondition.setParameterValue(namedValue.getName(), value); } - - // Convert the value into the correct type - Serializable value = null; - if (propertyType != null) - { - value = (Serializable)DefaultTypeConverter.INSTANCE.convert(propertyType, namedValue.getValue()); - } - else - { - value = namedValue.getValue(); - } - - // Set the parameter - actionCondition.setParameterValue(namedValue.getName(), value); } return actionCondition; @@ -1025,6 +1031,8 @@ public class ActionWebService extends AbstractWebService implements ActionServic } catch (Throwable exception) { + exception.printStackTrace(); + if (logger.isDebugEnabled()) { logger.error("Unexpected error occurred", exception); diff --git a/source/wsdl/action-service.wsdl b/source/wsdl/action-service.wsdl index 1c8be0a0ec..f982248dff 100644 --- a/source/wsdl/action-service.wsdl +++ b/source/wsdl/action-service.wsdl @@ -50,7 +50,7 @@ - +