=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/java/org/hisp/dhis/patient/action/patientattribute/GetPatientAttributeListAction.java' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/java/org/hisp/dhis/patient/action/patientattribute/GetPatientAttributeListAction.java 2011-03-31 01:42:05 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/java/org/hisp/dhis/patient/action/patientattribute/GetPatientAttributeListAction.java 2011-10-04 07:05:02 +0000 @@ -28,10 +28,12 @@ package org.hisp.dhis.patient.action.patientattribute; import java.util.ArrayList; -import java.util.Collection; +import java.util.Collections; +import java.util.List; import org.hisp.dhis.patient.PatientAttribute; import org.hisp.dhis.patient.PatientAttributeService; +import org.hisp.dhis.patient.comparator.PatientAttributeComparator; import com.opensymphony.xwork2.Action; @@ -57,9 +59,9 @@ // Output // ------------------------------------------------------------------------- - private Collection patientAttributes = new ArrayList(); + private List patientAttributes = new ArrayList(); - public Collection getPatientAttributes() + public List getPatientAttributes() { return patientAttributes; } @@ -71,7 +73,9 @@ public String execute() throws Exception { - patientAttributes = patientAttributeService.getAllPatientAttributes(); + patientAttributes = new ArrayList(patientAttributeService.getAllPatientAttributes()); + + Collections.sort( patientAttributes, new PatientAttributeComparator() ); return SUCCESS; } === modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/updatePatientAttibuteForm.vm' --- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/updatePatientAttibuteForm.vm 2011-09-29 04:17:34 +0000 +++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-patient/src/main/webapp/dhis-web-maintenance-patient/updatePatientAttibuteForm.vm 2011-10-04 07:05:02 +0000 @@ -45,7 +45,7 @@ $i18n.getString( "name" ) * - + $i18n.getString( "description" ) *