Author: kien_nguyen
Date: 2010-06-17 05:45:20 -0400 (Thu, 17 Jun 2010)
New Revision: 3355
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component/UIAccountEditInputSet.java
Log:
GTNPORTAL-1325 Should validate First/Last name field is between 1-45 chars in user and
group management
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component/UIAccountEditInputSet.java
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component/UIAccountEditInputSet.java 2010-06-17
03:58:55 UTC (rev 3354)
+++
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component/UIAccountEditInputSet.java 2010-06-17
09:45:20 UTC (rev 3355)
@@ -65,12 +65,10 @@
MandatoryValidator.class).addValidator(StringLengthValidator.class, 3,
30).addValidator(
ResourceValidator.class).addValidator(ExpressionValidator.class,
Utils.USER_NAME_VALIDATOR_REGEX,
"ResourceValidator.msg.Invalid-char"));
- addUIFormInput(new UIFormStringInput("firstName", "firstName",
null).setMaxLength(45).addValidator(
- StringLengthValidator.class, 3,
45).addValidator(MandatoryValidator.class).addValidator(
- ExpressionValidator.class, Utils.FIRST_CHARACTER_NAME_VALIDATOR_REGEX,
"FirstCharacterNameValidator.msg"));
- addUIFormInput(new UIFormStringInput("lastName", "lastName",
null).setMaxLength(45).addValidator(
- StringLengthValidator.class, 3,
45).addValidator(MandatoryValidator.class).addValidator(
- ExpressionValidator.class, Utils.FIRST_CHARACTER_NAME_VALIDATOR_REGEX,
"FirstCharacterNameValidator.msg"));
+ addUIFormInput(new UIFormStringInput("firstName", "firstName",
null).addValidator(
+ StringLengthValidator.class, 1, 45).addValidator(MandatoryValidator.class));
+ addUIFormInput(new UIFormStringInput("lastName", "lastName",
null).addValidator(
+ StringLengthValidator.class, 1, 45).addValidator(MandatoryValidator.class));
addUIFormInput(new UIFormStringInput("email", "email",
null).addValidator(MandatoryValidator.class).addValidator(
EmailAddressValidator.class));
UIFormCheckBoxInput<Boolean> uiCheckbox = new
UIFormCheckBoxInput<Boolean>(CHANGEPASS, null, false);