=== modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js' --- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js 2010-12-13 07:15:27 +0000 +++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js 2010-12-14 03:45:27 +0000 @@ -375,7 +375,7 @@ */ function getFieldValue( fieldId ) { - if ( getTypeById( fieldId ) == 'select-multiple' ) + if ( getTypeById( fieldId, 'multiple' ) ) { return jQuery("#" + fieldId).val()[0]; } @@ -389,9 +389,9 @@ * @param fieldId the identifier of the element. * @return the type of the element with the given identifier. */ -function getTypeById( fieldId ) +function getTypeById( fieldId, attribute ) { - return byId(fieldId).type; + return jQuery("#" + fieldId).attr( attribute ); } /**