← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 2768: (GIS) Point radius validation improved + Radius calculation bug fixed.

 

Merge authors:
  Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 2768 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2011-01-27 16:18:22 +0100
message:
  (GIS) Point radius validation improved + Radius calculation bug fixed.
modified:
  dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/core/GeoStat/Symbol.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/resources/mapfish/core/GeoStat/Symbol.js'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/core/GeoStat/Symbol.js	2011-01-07 10:58:35 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/core/GeoStat/Symbol.js	2011-01-27 15:16:58 +0000
@@ -108,7 +108,7 @@
 				var value = feature.attributes[this.indicator];
                 var size = (value - this.minVal) / (this.maxVal - this.minVal) *
 					(this.maxSize - this.minSize) + this.minSize;
-                return size;
+                return size || this.minSize;
             },	this
 		);
 		this.extendStyle(null, {'pointRadius': '${calculateRadius}'}, {'calculateRadius': calculateRadius});

=== 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-01-26 00:07:38 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Symbol.js	2011-01-27 15:16:58 +0000
@@ -811,6 +811,9 @@
             fieldLabel: 'Low radius',
 			labelSeparator: G.conf.labelseparator,
             width: G.conf.combo_number_width_small,
+            allowDecimals: false,
+            allowNegative: false,
+            minValue: 1,
             value: 5,
             listeners: {
                 'change': {
@@ -828,6 +831,9 @@
             fieldLabel: 'High radius',
 			labelSeparator: G.conf.labelseparator,
             width: G.conf.combo_number_width_small,
+            allowDecimals: false,
+            allowNegative: false,
+            minValue: 1,
             value: 20,
             listeners: {
                 'change': {