=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/javascript/attribute.js' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/javascript/attribute.js 2014-04-18 08:58:14 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-program/src/main/webapp/dhis-web-maintenance-program/javascript/attribute.js 2014-04-18 10:22:11 +0000 @@ -77,7 +77,8 @@ function typeOnChange() { - if( getFieldValue('valueType')=="combo"){ + var type = getFieldValue('valueType'); + if( type=="combo"){ showById("optionSetRow"); enable("optionSetId"); } @@ -85,6 +86,13 @@ hideById("optionSetRow"); disable("optionSetId"); } + + if( type=="number" || type=='string' || type=='letter' ){ + enable("unique"); + } + else{ + disable("unique"); + } } function uniqueOnChange(){