dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #10959
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 3027: Improved code.
Merge authors:
Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 3027 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Mon 2011-03-14 16:32:16 +0100
message:
Improved code.
modified:
dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/mapping/script/global.js
dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Choropleth.js
dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Symbol.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-mapping/src/main/webapp/dhis-web-mapping/mapping/script/global.js'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/mapping/script/global.js 2011-03-09 13:58:41 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/mapping/script/global.js 2011-03-14 15:30:53 +0000
@@ -451,9 +451,7 @@
mask: null,
- exportValues: null,
-
- topLevelUnit: null
+ exportValues: null
};
G.user = {
=== modified file 'dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Choropleth.js'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Choropleth.js 2011-03-03 14:42:07 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Choropleth.js 2011-03-14 15:30:53 +0000
@@ -588,7 +588,7 @@
style: 'cursor:pointer',
node: {attributes: {hasChildrenWithCoordinates: false}},
selectedNode: null,
- treeWindow: false,
+ treeWindow: null,
listeners: {
'focus': {
scope: this,
@@ -836,7 +836,7 @@
scope: this,
success: function(r) {
var rootNode = Ext.util.JSON.decode(r.responseText).organisationUnits[0];
- G.vars.topLevelUnit = {
+ var rootUnit = {
id: rootNode.id,
name: rootNode.name,
level: 1,
@@ -866,10 +866,10 @@
dataUrl: G.conf.path_mapping + 'getOrganisationUnitChildren' + G.conf.type
}),
root: {
- id: G.vars.topLevelUnit.id,
- text: G.vars.topLevelUnit.name,
- level: G.vars.topLevelUnit.level,
- hasChildrenWithCoordinates: G.vars.topLevelUnit.hasChildrenWithCoordinates,
+ id: rootUnit.id,
+ text: rootUnit.name,
+ level: rootUnit.level,
+ hasChildrenWithCoordinates: rootUnit.hasChildrenWithCoordinates,
nodeType: 'async',
draggable: false,
expanded: true
=== modified file 'dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Symbol.js'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Symbol.js 2011-03-03 14:42:07 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Symbol.js 2011-03-14 15:30:53 +0000
@@ -587,7 +587,7 @@
style: 'cursor:pointer',
node: {attributes: {hasChildrenWithCoordinates: false}},
selectedNode: null,
- treeWindow: false,
+ treeWindow: null,
listeners: {
'focus': {
scope: this,
@@ -857,9 +857,10 @@
scope: this,
success: function(r) {
var rootNode = Ext.util.JSON.decode(r.responseText).organisationUnits[0];
- G.vars.topLevelUnit = {
+ var rootUnit = {
id: rootNode.id,
name: rootNode.name,
+ level: 1,
hasChildrenWithCoordinates: rootNode.hasChildrenWithCoordinates
};
@@ -886,9 +887,10 @@
dataUrl: G.conf.path_mapping + 'getOrganisationUnitChildren' + G.conf.type
}),
root: {
- id: G.vars.topLevelUnit.id,
- text: G.vars.topLevelUnit.name,
- hasChildrenWithCoordinates: G.vars.topLevelUnit.hasChildrenWithCoordinates,
+ id: rootUnit.id,
+ text: rootUnit.name,
+ level: rootUnit.level,
+ hasChildrenWithCoordinates: rootUnit.hasChildrenWithCoordinates,
nodeType: 'async',
draggable: false,
expanded: true