=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addDataSet.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addDataSet.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addDataSet.js 2011-03-23 02:37:17 +0000 @@ -7,18 +7,18 @@ required : true, alphanumericwithbasicpuncspaces : r.dataSet.name.alphanumericwithbasicpuncspaces, firstletteralphabet : r.dataSet.name.firstletteralphabet, - range : r.dataSet.name.range + rangelength : r.dataSet.name.length }, shortName : { required : true, alphanumericwithbasicpuncspaces : r.dataSet.shortName.alphanumericwithbasicpuncspaces, firstletteralphabet : r.dataSet.shortName.firstletteralphabet, - range : r.dataSet.shortName.range + rangelength : r.dataSet.shortName.length }, code : { alphanumericwithbasicpuncspaces : r.dataSet.code.alphanumericwithbasicpuncspaces, notOnlyDigits : r.dataSet.code.notOnlyDigits, - range : r.dataSet.code.range + rangelength : r.dataSet.code.length }, frequencySelect : { required : true @@ -36,9 +36,9 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.dataSet.name.range[1] ); - jQuery( "#shortName" ).attr( "maxlength", r.dataSet.shortName.range[1] ); - jQuery( "#code" ).attr( "maxlength", r.dataSet.code.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.dataSet.name.length[1] ); + jQuery( "#shortName" ).attr( "maxlength", r.dataSet.shortName.length[1] ); + jQuery( "#code" ).attr( "maxlength", r.dataSet.code.length[1] ); checkValueIsExist( "name", "validateDataSet.action" ); checkValueIsExist( "shortName", "validateDataSet.action" ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addSection.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addSection.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/addSection.js 2011-03-23 02:37:17 +0000 @@ -5,7 +5,7 @@ var rules = { sectionName : { required : true, - range : r.section.name.range + rangelength : r.section.name.length }, selectedList : { required : true @@ -23,7 +23,7 @@ 'rules' : rules } ); - jQuery( "#sectionName" ).attr( "maxlength", r.section.name.range[1] ); + jQuery( "#sectionName" ).attr( "maxlength", r.section.name.length[1] ); checkValueIsExist( "sectionName", "validateSection.action", { dataSetId : function() === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editDataSet.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editDataSet.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editDataSet.js 2011-03-23 02:37:17 +0000 @@ -7,18 +7,18 @@ required : true, alphanumericwithbasicpuncspaces : r.dataSet.name.alphanumericwithbasicpuncspaces, firstletteralphabet : r.dataSet.name.firstletteralphabet, - range : r.dataSet.name.range + rangelength : r.dataSet.name.length }, shortName : { required : true, alphanumericwithbasicpuncspaces : r.dataSet.shortName.alphanumericwithbasicpuncspaces, firstletteralphabet : r.dataSet.shortName.firstletteralphabet, - range : r.dataSet.shortName.range + rangelength : r.dataSet.shortName.length }, code : { alphanumericwithbasicpuncspaces : r.dataSet.code.alphanumericwithbasicpuncspaces, notOnlyDigits : r.dataSet.code.notOnlyDigits, - range : r.dataSet.code.range + rangelength : r.dataSet.code.length }, frequencySelect : { required : true @@ -36,9 +36,9 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.dataSet.name.range[1] ); - jQuery( "#shortName" ).attr( "maxlength", r.dataSet.shortName.range[1] ); - jQuery( "#code" ).attr( "maxlength", r.dataSet.code.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.dataSet.name.length[1] ); + jQuery( "#shortName" ).attr( "maxlength", r.dataSet.shortName.length[1] ); + jQuery( "#code" ).attr( "maxlength", r.dataSet.code.length[1] ); checkValueIsExist( "name", "validateDataSet.action", { dataSetId : function() === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editSection.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editSection.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/editSection.js 2011-03-23 02:37:17 +0000 @@ -5,7 +5,7 @@ var rules = { sectionName : { required : true, - range : r.section.name.range + rangelength : r.section.name.length } }; @@ -20,7 +20,7 @@ 'rules' : rules } ); - jQuery( "#sectionName" ).attr( "maxlength", r.section.name.range[1] ); + jQuery( "#sectionName" ).attr( "maxlength", r.section.name.length[1] ); checkValueIsExist( "sectionName", "validateSection.action", { dataSetId : function() === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/viewDataEntryForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/viewDataEntryForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/viewDataEntryForm.js 2011-03-23 02:37:17 +0000 @@ -5,7 +5,7 @@ var rules = { nameField : { required : true, - range : r.dataEntry.name.range + rangelength : r.dataEntry.name.length } }; @@ -17,7 +17,7 @@ 'rules' : rules } ); - jQuery( "#nameField" ).attr( "maxlength", r.dataEntry.name.range[1] ); + jQuery( "#nameField" ).attr( "maxlength", r.dataEntry.name.length[1] ); jQuery( "#dataElementSelection" ).resizable( { minHeight : 210, === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitForm.js 2011-03-23 02:37:17 +0000 @@ -5,15 +5,15 @@ var rules = { name : { required : true, - range : r.organisationUnit.name.range + rangelength : r.organisationUnit.name.length }, shortName : { required : true, - range : r.organisationUnit.shortName.range + rangelength : r.organisationUnit.shortName.length }, code : { required : true, - range : r.organisationUnit.code.range + rangelength : r.organisationUnit.code.length }, openingDate : { required : true @@ -29,20 +29,20 @@ }, url : { url : true, - range : r.organisationUnit.url.range + rangelength : r.organisationUnit.url.length }, contactPerson : { - range : r.organisationUnit.contactPerson.range + rangelength : r.organisationUnit.contactPerson.length }, address : { - range : r.organisationUnit.address.range + rangelength : r.organisationUnit.address.length }, email : { email : true, - range : r.organisationUnit.email.range + rangelength : r.organisationUnit.email.length }, phoneNumber : { - range : r.organisationUnit.phoneNumber.range + rangelength : r.organisationUnit.phoneNumber.length } }; @@ -56,14 +56,14 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.organisationUnit.name.range[1] ); - jQuery( "#shortName" ).attr( "maxlength", r.organisationUnit.shortName.range[1] ); - jQuery( "#code" ).attr( "maxlength", r.organisationUnit.code.range[1] ); - jQuery( "#url" ).attr( "maxlength", r.organisationUnit.url.range[1] ); - jQuery( "#contactPerson" ).attr( "maxlength", r.organisationUnit.contactPerson.range[1] ); - jQuery( "#address" ).attr( "maxlength", r.organisationUnit.address.range[1] ); - jQuery( "#email" ).attr( "maxlength", r.organisationUnit.email.range[1] ); - jQuery( "#phoneNumber" ).attr( "maxlength", r.organisationUnit.phoneNumber.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.organisationUnit.name.length[1] ); + jQuery( "#shortName" ).attr( "maxlength", r.organisationUnit.shortName.length[1] ); + jQuery( "#code" ).attr( "maxlength", r.organisationUnit.code.length[1] ); + jQuery( "#url" ).attr( "maxlength", r.organisationUnit.url.length[1] ); + jQuery( "#contactPerson" ).attr( "maxlength", r.organisationUnit.contactPerson.length[1] ); + jQuery( "#address" ).attr( "maxlength", r.organisationUnit.address.length[1] ); + jQuery( "#email" ).attr( "maxlength", r.organisationUnit.email.length[1] ); + jQuery( "#phoneNumber" ).attr( "maxlength", r.organisationUnit.phoneNumber.length[1] ); checkValueIsExist( "name", "validateOrganisationUnit.action" ); datePickerValid( 'openingDate', false ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitGroupForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitGroupForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitGroupForm.js 2011-03-23 02:37:17 +0000 @@ -5,7 +5,7 @@ var rules = { name : { required : true, - range : r.organisationUnitGroup.name.range + rangelength : r.organisationUnitGroup.name.length } }; @@ -16,7 +16,7 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.organisationUnitGroup.name.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.organisationUnitGroup.name.length[1] ); checkValueIsExist( "name", "validateOrganisationUnitGroup.action" ); } ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitGroupSetForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitGroupSetForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/addOrganisationUnitGroupSetForm.js 2011-03-23 02:37:17 +0000 @@ -5,11 +5,11 @@ var rules = { name : { required : true, - range : r.organisationUnitGroupSet.name.range + rangelength : r.organisationUnitGroupSet.name.length }, description : { required : true, - range : r.organisationUnitGroupSet.description.range + rangelength : r.organisationUnitGroupSet.description.length } }; @@ -24,8 +24,8 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.organisationUnitGroupSet.name.range[1] ); - jQuery( "#description" ).attr( "maxlength", r.organisationUnitGroupSet.description.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.organisationUnitGroupSet.name.length[1] ); + jQuery( "#description" ).attr( "maxlength", r.organisationUnitGroupSet.description.length[1] ); checkValueIsExist( "name", "validateOrganisationUnitGroupSet.action" ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitForm.js 2011-03-23 02:37:17 +0000 @@ -5,15 +5,15 @@ var rules = { name : { required : true, - range : r.organisationUnit.name.range + rangelength : r.organisationUnit.name.length }, shortName : { required : true, - range : r.organisationUnit.shortName.range + rangelength : r.organisationUnit.shortName.length }, code : { required : true, - range : r.organisationUnit.code.range + rangelength : r.organisationUnit.code.length }, openingDate : { required : true @@ -29,20 +29,20 @@ }, url : { url : true, - range : r.organisationUnit.url.range + rangelength : r.organisationUnit.url.length }, contactPerson : { - range : r.organisationUnit.contactPerson.range + rangelength : r.organisationUnit.contactPerson.length }, address : { - range : r.organisationUnit.address.range + rangelength : r.organisationUnit.address.length }, email : { email : true, - range : r.organisationUnit.email.range + rangelength : r.organisationUnit.email.length }, phoneNumber : { - range : r.organisationUnit.phoneNumber.range + rangelength : r.organisationUnit.phoneNumber.length } }; @@ -55,12 +55,12 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.organisationUnit.name.range[1] ); - jQuery( "#shortName" ).attr( "maxlength", r.organisationUnit.shortName.range[1] ); - jQuery( "#code" ).attr( "maxlength", r.organisationUnit.code.range[1] ); - jQuery( "#url" ).attr( "maxlength", r.organisationUnit.url.range[1] ); - jQuery( "#contactPerson" ).attr( "maxlength", r.organisationUnit.contactPerson.range[1] ); - jQuery( "#address" ).attr( "maxlength", r.organisationUnit.address.range[1] ); - jQuery( "#email" ).attr( "maxlength", r.organisationUnit.email.range[1] ); - jQuery( "#phoneNumber" ).attr( "maxlength", r.organisationUnit.phoneNumber.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.organisationUnit.name.length[1] ); + jQuery( "#shortName" ).attr( "maxlength", r.organisationUnit.shortName.length[1] ); + jQuery( "#code" ).attr( "maxlength", r.organisationUnit.code.length[1] ); + jQuery( "#url" ).attr( "maxlength", r.organisationUnit.url.length[1] ); + jQuery( "#contactPerson" ).attr( "maxlength", r.organisationUnit.contactPerson.length[1] ); + jQuery( "#address" ).attr( "maxlength", r.organisationUnit.address.length[1] ); + jQuery( "#email" ).attr( "maxlength", r.organisationUnit.email.length[1] ); + jQuery( "#phoneNumber" ).attr( "maxlength", r.organisationUnit.phoneNumber.length[1] ); } ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitGroupForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitGroupForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitGroupForm.js 2011-03-23 02:37:17 +0000 @@ -1,20 +1,17 @@ -jQuery(document).ready(function() -{ +jQuery(document).ready( function(){ var r = getValidationRules(); - + var rules = { - name : { - required : true, - range : r.organisationUnitGroup.name.range + name: { + required:true, + rangelength : r.organisationUnitGroup.name.length } }; - validation2('updateOrganisationUnitGroupForm', function( form ) + validation2( 'updateOrganisationUnitGroupForm', function( form ) { form.submit() }, { - form.submit() - }, { - 'rules' : rules - }); + 'rules': rules + }); - jQuery("#name").attr("maxlength", r.organisationUnitGroup.name.range[1]); -}); + jQuery( "#name" ).attr( "maxlength", r.organisationUnitGroup.name.length[1] ); +}); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitGroupSetForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitGroupSetForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/javascript/updateOrganisationUnitGroupSetForm.js 2011-03-23 02:37:17 +0000 @@ -5,11 +5,11 @@ var rules = { name : { required : true, - range : r.organisationUnitGroupSet.name.range + rangelength : r.organisationUnitGroupSet.name.length }, description : { required : true, - range : r.organisationUnitGroupSet.description.range + rangelength : r.organisationUnitGroupSet.description.length } }; @@ -24,8 +24,8 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.organisationUnitGroupSet.name.range[1] ); - jQuery( "#description" ).attr( "maxlength", r.organisationUnitGroupSet.description.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.organisationUnitGroupSet.name.length[1] ); + jQuery( "#description" ).attr( "maxlength", r.organisationUnitGroupSet.description.length[1] ); checkValueIsExist( "name", "validateOrganisationUnitGroupSet.action", { id : $organisationUnitGroupSet.id === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addRoleForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addRoleForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addRoleForm.js 2011-03-23 02:37:17 +0000 @@ -7,11 +7,11 @@ var rules = { name : { required : true, - range : r.role.name.range + rangelength : r.role.name.length }, description : { required : true, - range : r.role.description.range + rangelength : r.role.description.length } } @@ -24,8 +24,8 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.role.name.range[1] ); - jQuery( "#description" ).attr( "maxlength", r.role.description.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.role.name.length[1] ); + jQuery( "#description" ).attr( "maxlength", r.role.description.length[1] ); /* remote validation */ checkValueIsExist( "name", "validateRole.action" ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addUserForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addUserForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addUserForm.js 2011-03-23 02:37:17 +0000 @@ -7,13 +7,13 @@ required : true, firstletteralphabet : r.user.username.firstletteralphabet, alphanumeric : r.user.username.alphanumeric, - range : r.user.username.range + rangelength : r.user.username.length }, rawPassword : { required : true, password : true, notequalto : '#username', - range : r.user.password.range + rangelength : r.user.password.length }, retypePassword : { required : true, @@ -21,18 +21,18 @@ }, surname : { required : true, - range : r.user.name.range + rangelength : r.user.name.length }, firstName : { required : true, - range : r.user.name.range + rangelength : r.user.name.length }, email : { email : true, - range : r.user.email.range + rangelength : r.user.email.length }, phoneNumber : { - range : r.user.phone.range + rangelength : r.user.phone.length }, roleValidator : { required : true @@ -50,13 +50,13 @@ 'rules' : rules } ); - jQuery( "#username" ).attr( "maxlength", r.user.username.range[1] ); - jQuery( "#rawPassword" ).attr( "maxlength", r.user.password.range[1] ); - jQuery( "#retypePassword" ).attr( "maxlength", r.user.password.range[1] ); - jQuery( "#surname" ).attr( "maxlength", r.user.name.range[1] ); - jQuery( "#firstName" ).attr( "maxlength", r.user.name.range[1] ); - jQuery( "#email" ).attr( "maxlength", r.user.email.range[1] ); - jQuery( "#phoneNumber" ).attr( "maxlength", r.user.phone.range[1] ); + jQuery( "#username" ).attr( "maxlength", r.user.username.length[1] ); + jQuery( "#rawPassword" ).attr( "maxlength", r.user.password.length[1] ); + jQuery( "#retypePassword" ).attr( "maxlength", r.user.password.length[1] ); + jQuery( "#surname" ).attr( "maxlength", r.user.name.length[1] ); + jQuery( "#firstName" ).attr( "maxlength", r.user.name.length[1] ); + jQuery( "#email" ).attr( "maxlength", r.user.email.length[1] ); + jQuery( "#phoneNumber" ).attr( "maxlength", r.user.phone.length[1] ); /* remote validation */ checkValueIsExist( "username", "validateUser.action" ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addUserGroupForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addUserGroupForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/addUserGroupForm.js 2011-03-23 02:37:17 +0000 @@ -7,7 +7,7 @@ required : true, alphanumericwithbasicpuncspaces : r.userGroup.name.alphanumericwithbasicpuncspaces, firstletteralphabet : r.userGroup.name.firstletteralphabet, - range : r.userGroup.name.range + rangelength : r.userGroup.name.length }, memberValidator : { required : true @@ -25,7 +25,7 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.userGroup.name.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.userGroup.name.length[1] ); /* remote validation */ checkValueIsExist( "name", "validateUserGroup.action" ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateRoleForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateRoleForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateRoleForm.js 2011-03-23 02:37:17 +0000 @@ -7,11 +7,11 @@ var rules = { name : { required : true, - range : r.role.name.range + rangelength : r.role.name.length }, description : { required : true, - range : r.role.description.range + rangelength : r.role.description.length } }; @@ -24,8 +24,8 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.role.name.range[1] ); - jQuery( "#description" ).attr( "maxlength", r.role.description.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.role.name.length[1] ); + jQuery( "#description" ).attr( "maxlength", r.role.description.length[1] ); /* remote validation */ checkValueIsExist( "name", "validateRole.action", { === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateUserForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateUserForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateUserForm.js 2011-03-23 02:37:17 +0000 @@ -6,27 +6,27 @@ rawPassword : { password : true, notequalto : '#username', - range : r.user.password.range + rangelength : r.user.password.length }, retypePassword : { required : false, equalTo : '#rawPassword', - range : r.user.password.range + rangelength : r.user.password.length }, surname : { required : true, - range : r.user.name.range + rangelength : r.user.name.length }, firstName : { required : true, - range : r.user.name.range + rangelength : r.user.name.length }, email : { email : true, - range : r.user.email.range + rangelength : r.user.email.length }, phoneNumber : { - range : r.user.phone.range + rangelength : r.user.phone.length }, roleValidator : { required : true @@ -44,11 +44,11 @@ 'rules' : rules } ); - jQuery( "#rawPassword" ).attr( "maxlength", r.user.password.range[1] ); - jQuery( "#retypePassword" ).attr( "maxlength", r.user.password.range[1] ); - jQuery( "#surname" ).attr( "maxlength", r.user.name.range[1] ); - jQuery( "#firstName" ).attr( "maxlength", r.user.name.range[1] ); - jQuery( "#email" ).attr( "maxlength", r.user.email.range[1] ); - jQuery( "#phoneNumber" ).attr( "maxlength", r.user.phone.range[1] ); + jQuery( "#rawPassword" ).attr( "maxlength", r.user.password.length[1] ); + jQuery( "#retypePassword" ).attr( "maxlength", r.user.password.length[1] ); + jQuery( "#surname" ).attr( "maxlength", r.user.name.length[1] ); + jQuery( "#firstName" ).attr( "maxlength", r.user.name.length[1] ); + jQuery( "#email" ).attr( "maxlength", r.user.email.length[1] ); + jQuery( "#phoneNumber" ).attr( "maxlength", r.user.phone.length[1] ); } ); === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateUserGroupForm.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateUserGroupForm.js 2011-03-22 10:50:42 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/webapp/dhis-web-maintenance-user/javascript/updateUserGroupForm.js 2011-03-23 02:37:17 +0000 @@ -7,7 +7,7 @@ required : true, alphanumericwithbasicpuncspaces : r.userGroup.name.alphanumericwithbasicpuncspaces, firstletteralphabet : r.userGroup.name.firstletteralphabet, - range : r.userGroup.name.range + rangelength : r.userGroup.name.length }, memberValidator : { required : true @@ -25,5 +25,5 @@ 'rules' : rules } ); - jQuery( "#name" ).attr( "maxlength", r.userGroup.name.range[1] ); + jQuery( "#name" ).attr( "maxlength", r.userGroup.name.length[1] ); } );