Merged BRANCHES/DEV/V3.3-BUG-FIX to HEAD:

22910: Fixed ALF-872: TinyMCE Insert/edit Link dialog does not display properly in IE6
   22914: Merged DEV/BELARUS/HEAD-2010_04_28 to V3.3-BUG-FIX
        ALF-2315: WCM Schema: Inconsistent error if not filling in required fields
   22918: Merged DEV/BELARUS/V3.3-BUG-FIX-2010_06_24 to V3.3-BUG-FIX
        ALF-2931: WCM Forms - min/maxLength ignored for xs:string elements
   22940: Merged DEV/BELARUS/V3.3-2010_05_26 to V3.3-BUG-FIX
        ALF-2742: Impossibility to manage site for MS Excel
   22949: (RECORD ONLY) Added "continuous-without-distribute" target

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@22958 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Gavin Cornwell
2010-10-07 13:34:33 +00:00
parent c0fb578036
commit dc916dda18
3 changed files with 57 additions and 10 deletions

View File

@@ -2486,7 +2486,7 @@ public class Schema2XForms implements Serializable
case XSConstants.STRING_DT:
{
result = xformsDocument.createElementNS(NamespaceConstants.XFORMS_NS,
NamespaceConstants.XFORMS_PREFIX + ":textarea");
NamespaceConstants.XFORMS_PREFIX + ":textarea");
if (appearance == null || appearance.length() == 0)
{
appearance = "compact";
@@ -2843,7 +2843,7 @@ public class Schema2XForms implements Serializable
typeName);
}
final StringList lexicalPatterns = ((XSSimpleTypeDefinition)controlType).getLexicalPattern();
// NOTE: from glen.johnson@alfresco.com
// Workaround to fix issue WCM-952
//
@@ -2878,8 +2878,22 @@ public class Schema2XForms implements Serializable
}
constraints.add("chiba:match(., '" + pattern + "',null)");
}
}
XSSimpleTypeDefinition simpleControlType = ((XSSimpleTypeDefinition) controlType);
if (simpleControlType.isDefinedFacet(XSSimpleTypeDefinition.FACET_MAXLENGTH))
{
constraints.add("string-length(.) <= " + simpleControlType.getLexicalFacetValue(XSSimpleTypeDefinition.FACET_MAXLENGTH));
}
if (simpleControlType.isDefinedFacet(XSSimpleTypeDefinition.FACET_MINLENGTH))
{
constraints.add("string-length(.) >= " + simpleControlType.getLexicalFacetValue(XSSimpleTypeDefinition.FACET_MINLENGTH));
}
}
final short constraintType =
(owner != null && owner instanceof XSElementDeclaration
? ((XSElementDeclaration)owner).getConstraintType()