dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #43623
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 22114: Fixed issue with upgrade of option combo names
------------------------------------------------------------
revno: 22114
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2016-03-02 18:21:16 +0100
message:
Fixed issue with upgrade of option combo names
modified:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryService.java
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/DefaultDataElementCategoryService.java
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.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-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryService.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryService.java 2016-03-01 22:30:53 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryService.java 2016-03-02 17:21:16 +0000
@@ -534,6 +534,8 @@
List<DataElementCategoryCombo> getDataElementCategoryCombosBetweenByName( String name, int first, int max );
+ void updateCategoryOptionComboNames();
+
// -------------------------------------------------------------------------
// DataElementOperand
// -------------------------------------------------------------------------
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/DefaultDataElementCategoryService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/DefaultDataElementCategoryService.java 2016-03-01 22:30:53 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/DefaultDataElementCategoryService.java 2016-03-02 17:21:16 +0000
@@ -758,6 +758,12 @@
return options.size() == categoryOptionCombo.getCategoryOptions().size();
}
+ @Override
+ public void updateCategoryOptionComboNames()
+ {
+ categoryOptionComboStore.updateNames();
+ }
+
// -------------------------------------------------------------------------
// DataElementOperand
// -------------------------------------------------------------------------
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java 2016-03-02 04:34:21 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java 2016-03-02 17:21:16 +0000
@@ -33,7 +33,7 @@
import org.amplecode.quick.StatementManager;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-import org.hisp.dhis.dataelement.CategoryOptionComboStore;
+import org.hisp.dhis.dataelement.DataElementCategoryService;
import org.hisp.dhis.jdbc.StatementBuilder;
import org.hisp.dhis.organisationunit.OrganisationUnitService;
import org.hisp.dhis.system.startup.AbstractStartupRoutine;
@@ -69,7 +69,7 @@
private OrganisationUnitService organisationUnitService;
@Autowired
- private CategoryOptionComboStore categoryOptionComboStore;
+ private DataElementCategoryService categoryService;
// -------------------------------------------------------------------------
// Execute
@@ -905,7 +905,7 @@
organisationUnitService.updatePaths();
- categoryOptionComboStore.updateNames();
+ categoryService.updateCategoryOptionComboNames();
executeSql( "alter table trackedentitydatavalue alter column storedby TYPE character varying(255)" );
executeSql( "alter table datavalue alter column storedby TYPE character varying(255)" );