dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #00765
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 203: Fixed path to action classes. Add map bug fixed.
------------------------------------------------------------
revno: 203
committer: Jan Henrik Overland janhenrik.overland@xxxxxxxxx
branch nick: trunk
timestamp: Mon 2009-04-20 18:32:44 +0200
message:
Fixed path to action classes. Add map bug fixed.
modified:
gis/dhis-gis-geostat/demos/geostat/config.js
gis/dhis-gis-geostat/demos/geostat/geostat.js
gis/dhis-gis-geostat/mfbase/mapfish/widgets/geostat/Choropleth.js
gis/dhis-gis-geostat/mfbase/mapfish/widgets/geostat/Mapping.js
=== modified file 'gis/dhis-gis-geostat/demos/geostat/config.js'
--- gis/dhis-gis-geostat/demos/geostat/config.js 2009-04-14 13:21:16 +0000
+++ gis/dhis-gis-geostat/demos/geostat/config.js 2009-04-20 16:32:44 +0000
@@ -1,5 +1,7 @@
-// LOCALHOST + TOMCAT
-localhost = 'http://localhost:8180';
+// AJAX REQUESTS
+
+path = '../../dhis-web-mapping/';
+type = '.action';
// MAP
init_longitude = 0;
=== modified file 'gis/dhis-gis-geostat/demos/geostat/geostat.js'
--- gis/dhis-gis-geostat/demos/geostat/geostat.js 2009-04-20 14:48:47 +0000
+++ gis/dhis-gis-geostat/demos/geostat/geostat.js 2009-04-20 16:32:44 +0000
@@ -51,7 +51,7 @@
})
});
- map.addLayers([jpl_wms, vmap0, choroplethLayer, propSymbolLayer]);
+ map.addLayers([jpl_wms, vmap0, choroplethLayer]);
var selectFeatureChoropleth = new OpenLayers.Control.newSelectFeature(
choroplethLayer,
@@ -72,7 +72,7 @@
map.setCenter(new OpenLayers.LonLat(init_longitude, init_latitude), init_zoom); // config.js
var organisationUnitLevelStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getOrganisationUnitLevels.action',
+ url: path + 'getOrganisationUnitLevels' + type,
baseParams: { format: 'json' },
root: 'organisationUnitLevels',
fields: ['id', 'level', 'name'],
@@ -80,7 +80,7 @@
});
var organisationUnitStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getOrganisationUnitsAtLevel.action',
+ url: path + 'getOrganisationUnitsAtLevel' + type,
root: 'organisationUnits',
fields: ['id', 'name'],
sortInfo: { field: 'name', direction: 'ASC' },
@@ -88,7 +88,7 @@
});
var existingMapsStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getAllMaps.action',
+ url: path + 'getAllMaps' + type,
baseParams: { format: 'jsonmin' },
root: 'maps',
fields: ['id', 'mapLayerPath', 'organisationUnitLevel'],
@@ -100,7 +100,7 @@
fieldLabel: 'Organisation unit',
typeAhead: true,
editable: false,
- valueField: 'name',
+ valueField: 'id',
displayField: 'name',
emptyText: 'Required',
mode: 'remote',
@@ -136,11 +136,11 @@
if (level1 >= level2)
{
- organisationUnitLevelCombo2.reset();
+ organisationUnitLevelComboBox.reset();
Ext.Msg.show({
title:'Register shapefiles',
- msg: '<p style="padding-top:8px">Level must be lower than ' + orgunit + '!</p>',
+ msg: '<p style="padding-top:8px">' + orgunit + ' must be devided into a lower level than itself!</p>',
buttons: Ext.Msg.OK,
animEl: 'elId',
maxWidth: 300,
@@ -175,7 +175,7 @@
});
var newNameColumnTextField = new Ext.form.TextField({
- id: 'namecolumn_tf',
+ id: 'newnamecolumn_tf',
emptyText: 'Required',
width: combo_width
});
@@ -267,7 +267,7 @@
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/addOrUpdateMap.action',
+ url: path + 'addOrUpdateMap' + type,
method: 'GET',
params: { mapLayerPath: mlp, organisationUnitId: oui, organisationUnitLevelId: ouli, uniqueColumn: uc, nameColumn: nc,
longitude: lon, latitude: lat, zoom: zoom},
@@ -314,7 +314,7 @@
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/addOrUpdateMap.action',
+ url: path + 'addOrUpdateMap' + type,
method: 'GET',
params: { mapLayerPath: mlp, organisationUnitId: oui, organisationUnitLevelId: ouli, uniqueColumn: uc, nameColumn: nc,
longitude: lon, latitude: lat, zoom: zoom},
@@ -356,7 +356,7 @@
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/deleteMapByMapLayerPath.action',
+ url: path + 'deleteMapByMapLayerPath' + type,
method: 'GET',
params: { mapLayerPath: mlp },
@@ -434,7 +434,7 @@
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/getMapByMapLayerPath.action',
+ url: path + 'getMapByMapLayerPath' + type,
method: 'GET',
params: { mapLayerPath: mlp, format: 'json' },
@@ -855,7 +855,7 @@
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/addOrUpdateMapOrganisationUnitRelation.action',
+ url: path + 'addOrUpdateMapOrganisationUnitRelation' + type,
method: 'GET',
params: { mapLayerPath: mlp, organisationUnitId: organisationUnitId, featureId: featureId },
@@ -942,7 +942,7 @@
{
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/getMapByMapLayerPath.action',
+ url: path + 'getMapByMapLayerPath' + type,
method: 'GET',
params: { mapLayerPath: 'who:Indian_state', format: 'json' },
@@ -975,7 +975,7 @@
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/getMapValues.action',
+ url: path + 'getMapValues' + type,
method: 'GET',
params: { indicatorId: indicatorId, periodId: periodId, level: level, format: 'json' },
@@ -997,7 +997,7 @@
var periodId = Ext.getCmp('period_cb').getValue();
var level = pointLayer;
- var url = 'getMapValues.action';
+ var url = 'getMapValues' + type;
format = 'json';
Ext.Ajax.request(
@@ -1024,7 +1024,7 @@
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/getAvailableMapOrganisationUnitRelations.action',
+ url: path + 'getAvailableMapOrganisationUnitRelations' + type,
method: 'GET',
params: { mapLayerPath: mlp, format: 'json' },
@@ -1051,7 +1051,7 @@
Ext.Ajax.request(
{
- url: '/dhis-web-mapping/getAvailableMapOrganisationUnitRelations.action',
+ url: path + 'getAvailableMapOrganisationUnitRelations' + type,
method: 'GET',
params: { mapLayerPath: mlp, format: 'json' },
=== modified file 'gis/dhis-gis-geostat/mfbase/mapfish/widgets/geostat/Choropleth.js'
--- gis/dhis-gis-geostat/mfbase/mapfish/widgets/geostat/Choropleth.js 2009-04-20 14:29:53 +0000
+++ gis/dhis-gis-geostat/mfbase/mapfish/widgets/geostat/Choropleth.js 2009-04-20 16:32:44 +0000
@@ -142,7 +142,7 @@
initComponent : function() {
indicatorGroupStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getAllIndicatorGroups.action',
+ url: path + 'getAllIndicatorGroups' + type,
baseParams: { format: 'json' },
root: 'indicatorGroups',
fields: ['id', 'name'],
@@ -150,14 +150,14 @@
});
indicatorStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getIndicatorsByIndicatorGroup.action',
+ url: path + 'getIndicatorsByIndicatorGroup' + type,
root: 'indicators',
fields: ['id', 'name'],
autoLoad: false
});
periodTypeStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getAllPeriodTypes.action',
+ url: path + 'getAllPeriodTypes' + type,
baseParams: { format: 'json' },
root: 'periodTypes',
fields: ['id', 'name'],
@@ -165,7 +165,7 @@
});
periodStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getPeriodsByPeriodType.action',
+ url: path + 'getPeriodsByPeriodType' + type,
baseParams: { periodTypeId: '9', format: 'json' },
root: 'periods',
fields: ['id', 'startDate'],
@@ -173,7 +173,7 @@
});
mapStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getAllMaps.action',
+ url: path + 'getAllMaps' + type,
baseParams: { format: 'jsonmin' },
root: 'maps',
fields: ['id', 'mapLayerPath', 'organisationUnitLevel'],
@@ -181,7 +181,7 @@
});
levelStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getOrganisationUnitLevels.action',
+ url: path + 'getOrganisationUnitLevels' + type,
baseParams: { format: 'json' },
root: 'organisationUnitLevels',
fields: ['level', 'name'],
@@ -189,7 +189,7 @@
});
legendStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getLegendMinAndMaxOfIndicator.action',
+ url: path + 'getLegendMinAndMaxOfIndicator' + type,
root: 'legendSet',
fields: ['id', 'name'],
autoLoad: false
@@ -208,7 +208,7 @@
mode: 'remote',
forceSelection: true,
triggerAction: 'all',
- emptyText: 'Select group',
+ emptyText: 'Required',
selectOnFocus: true,
width: combo_width,
store: indicatorGroupStore,
@@ -250,8 +250,6 @@
var iId = Ext.getCmp('indicator_cb').getValue();
legendStore.baseParams = { indicatorId: iId, format: 'json' };
legendStore.reload();
-
- this.classify(false);
}
}
}
@@ -299,15 +297,7 @@
emptyText: 'Select period',
selectOnFocus: true,
width: combo_width,
- store: periodStore,
- listeners: {
- 'select': {
- fn: function()
- {
- this.classify(false);
- }
- }
- }
+ store: periodStore
},
{
@@ -375,7 +365,7 @@
fn: function()
{
var iId = Ext.getCmp('indicator_cb').getValue();
- var url = '/dhis-web-mapping/getLegendMinAndMaxOfIndicator.action';
+ var url = path + 'getLegendMinAndMaxOfIndicator' + type;
var format = 'json';
Ext.Ajax.request({
=== modified file 'gis/dhis-gis-geostat/mfbase/mapfish/widgets/geostat/Mapping.js'
--- gis/dhis-gis-geostat/mfbase/mapfish/widgets/geostat/Mapping.js 2009-04-20 14:29:53 +0000
+++ gis/dhis-gis-geostat/mfbase/mapfish/widgets/geostat/Mapping.js 2009-04-20 16:32:44 +0000
@@ -142,7 +142,7 @@
initComponent : function() {
mapStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getAllMaps.service',
+ url: path + 'getAllMaps' + type,
baseParams: { format: 'jsonmin' },
root: 'maps',
fields: ['id', 'mapLayerPath', 'organisationUnitLevel'],
@@ -150,7 +150,7 @@
});
gridStore = new Ext.data.JsonStore({
- url: '/dhis-web-mapping/getAvailableMapOrganisationUnitRelations.service',
+ url: path + 'getAvailableMapOrganisationUnitRelations' + type,
root: 'mapOrganisationUnitRelations',
fields: ['id', 'organisationUnit', 'organisationUnitId', 'featureId'],
autoLoad: false
--
Trunk
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.