dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #27821
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 13863: csd: Minor refactor names of strings
------------------------------------------------------------
revno: 13863
committer: Bob Jolliffe <bobjolliffe@xxxxxxxxx>
branch nick: dhis2
timestamp: Mon 2014-01-27 10:01:17 +0000
message:
csd: Minor refactor names of strings
modified:
dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/csd/webapi/CsdController.java
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/csd/webapi/CsdController.java'
--- dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/csd/webapi/CsdController.java 2014-01-27 09:53:53 +0000
+++ dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/csd/webapi/CsdController.java 2014-01-27 10:01:17 +0000
@@ -78,6 +78,7 @@
import java.util.Date;
import java.util.List;
import java.util.Map;
+import org.hisp.dhis.organisationunit.OrganisationUnitGroupSet;
/**
* @author Morten Olav Hansen <mortenoh@xxxxxxxxx>
@@ -88,10 +89,14 @@
{
private static final String SOAP_CONTENT_TYPE = "application/soap+xml";
- // Name of group
- private static final String FACILITY_DISCRIMINATOR = "Health Facility";
-
- private static final String FACILITY_STATUS_DISCRIMINATOR = "Status";
+ // Name of group all facilities belong to
+ private static final String FACILITY_DISCRIMINATOR_GROUP = "Health Facility";
+
+ // groupset for status codelist - open, closed, etc
+ private static final String FACILITY_STATUS_GROUPSET = "Status";
+
+ // groupset for facility type codelist
+ private static final String FACILITY_TYPE_GROUPSET = "Type";
// -------------------------------------------------------------------------
// Dependencies
@@ -235,7 +240,7 @@
for ( OrganisationUnitGroup group : organisationUnit.getGroups() )
{
- if ( group.getName().equals( FACILITY_DISCRIMINATOR ) )
+ if ( group.getName().equals( FACILITY_DISCRIMINATOR_GROUP ) )
{
isFacility = true;
break;
@@ -293,7 +298,7 @@
}
if ( organisationUnitGroup.getGroupSet() != null &&
- FACILITY_STATUS_DISCRIMINATOR.equals( organisationUnitGroup.getGroupSet().getName() ) )
+ FACILITY_STATUS_GROUPSET.equals( organisationUnitGroup.getGroupSet().getName() ) )
{
facilityStatus = organisationUnitGroup.getCode();
continue;