← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 5576: Name encoding bug fixed.

 

Merge authors:
  Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 5576 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Sat 2011-12-24 13:03:43 +0100
message:
  Name encoding bug fixed.
modified:
  dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/app.js


--
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-visualizer/src/main/webapp/dhis-web-visualizer/app/app.js'
--- dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/app.js	2011-12-22 22:14:17 +0000
+++ dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/app.js	2011-12-24 12:01:38 +0000
@@ -1069,7 +1069,7 @@
                             for (var i = 0; i < f.indicators.length; i++) {
                                 indiment.push(f.indicators[i]);
                                 this.indicatorIds.push(f.indicators[i].internalId);
-                                records.push({id: f.indicators[i].internalId, s: f.indicators[i].shortName, name: f.indicators[i].shortName, parent: null});
+                                records.push({id: f.indicators[i].internalId, s: DV.util.string.getEncodedString(f.indicators[i].shortName), name: DV.util.string.getEncodedString(f.indicators[i].shortName), parent: null});
                             }
                             DV.store.indicator.selected.removeAll();
                             DV.store.indicator.selected.add(records);
@@ -1081,7 +1081,7 @@
                             for (var i = 0; i < f.dataElements.length; i++) {
                                 indiment.push(f.dataElements[i]);
                                 this.dataelementIds.push(f.dataElements[i].internalId);
-                                records.push({id: f.dataElements[i].internalId, s: f.dataElements[i].shortName, name: f.dataElements[i].shortName, parent: null});
+                                records.push({id: f.dataElements[i].internalId, s: DV.util.string.getEncodedString(f.dataElements[i].shortName), name: DV.util.string.getEncodedString(f.dataElements[i].shortName), parent: null});
                             }
                             DV.store.dataelement.selected.removeAll();
                             DV.store.dataelement.selected.add(records);
@@ -1089,7 +1089,7 @@
                             DV.util.multiselect.filterAvailable(DV.cmp.dimension.dataelement.available, DV.cmp.dimension.dataelement.selected);
                         }
                         for (var i = 0; i < indiment.length; i++) {
-                            f.names.data.push(indiment[i].shortName);
+                            f.names.data.push(DV.util.string.getEncodedString(indiment[i].shortName));
                         }
                         
                         this.relativePeriods = f.relativePeriods;
@@ -1098,8 +1098,8 @@
                         
                         for (var i = 0; i < f.organisationUnits.length; i++) {
                             this.organisationunitIds.push(f.organisationUnits[i].internalId);
-                            f.names.organisationunit.push(f.organisationUnits[i].name);
-                            DV.cmp.dimension.organisationunit.treepanel.storage[f.organisationUnits[i].internalId] = f.organisationUnits[i].name;
+                            f.names.organisationunit.push(DV.util.string.getEncodedString(f.organisationUnits[i].name));
+                            DV.cmp.dimension.organisationunit.treepanel.storage[f.organisationUnits[i].internalId] = DV.util.string.getEncodedString(f.organisationUnits[i].name);
                         }
                         
                         this.series.names = f.names[this.series.dimension];