← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 2371: (GIS) Unnecessary code removed.

 

Merge authors:
  Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 2371 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: trunk
timestamp: Thu 2010-10-14 15:07:38 +0200
message:
  (GIS) Unnecessary code removed.
modified:
  dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/mapping/script/index.js
  dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Mapping.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/index.js'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/mapping/script/index.js	2010-10-13 10:40:40 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/mapping/script/index.js	2010-10-14 13:05:47 +0000
@@ -233,14 +233,8 @@
 									Ext.getCmp('view_cb').getStore().load();
 									Ext.getCmp('mapview_cb').getStore().load();
 									Ext.getCmp('viewname_tf').reset();
-								},
-								failure: function() {
-									alert( 'Error: addOrUpdateMapView' );
 								}
 							});
-						},
-						failure: function() {
-									alert( 'Error: getAllMapViews' );
 						}
 					});
 				}
@@ -283,9 +277,6 @@
                             if (v == Ext.getCmp('mapview_cb').getValue()) {
                                 Ext.getCmp('mapview_cb').clearValue();
                             }
-						},
-						failure: function() {
-							alert( i18n_status , i18n_error_while_saving_data );
 						}
 					});
 				}
@@ -326,9 +317,6 @@
 							Ext.getCmp('view_cb').getStore().load();
 							Ext.getCmp('view_cb').clearValue();
 							Ext.getCmp('mapview_cb').getStore().load();
-						},
-						failure: function() {
-							alert(i18n_status, i18n_error_while_saving_data);
 						}
 					});
 				}
@@ -675,14 +663,8 @@
                                     Ext.getCmp('predefinedmaplegendstartvalue_tf').reset();
                                     Ext.getCmp('predefinedmaplegendendvalue_tf').reset();
                                     Ext.getCmp('predefinedmaplegendcolor_cp').reset();
-                                },
-                                failure: function() {
-                                    alert( 'Error: addOrUpdateMapLegend' );
                                 }
                             });
-                        },
-                        failure: function() {
-                            alert( 'Error: getAllMapLegends' );
                         }
                     });
                 }
@@ -719,9 +701,6 @@
                             Ext.message.msg(true, i18n_legend+ ' <span class="x-msg-hl">' + mlrv + '</span> ' + i18n_was_deleted);
                             Ext.getCmp('predefinedmaplegend_cb').getStore().load();
                             Ext.getCmp('predefinedmaplegend_cb').clearValue();
-                        },
-                        failure: function() {
-                            alert( 'Error: deleteMapLegend' );
                         }
                     });
                 }
@@ -799,9 +778,6 @@
 							Ext.getCmp('maplegendset_cb').getStore().load();
 							Ext.getCmp('predefinedmaplegendsetname_tf').reset();
 							Ext.getCmp('predefinednewmaplegend_ms').reset();							
-                        },
-                        failure: function() {
-                            alert( 'Error: addOrUpdateMapLegendSet' );
                         }
                     });
                 }
@@ -890,9 +866,6 @@
                                     }
                                     
                                     Ext.getCmp('predefinedmaplegendsetindicator_ms').setValue(indicatorString);							
-                                },
-                                failure: function() {
-                                    alert( i18n_status , i18n_error_while_saving_data );
                                 }
                             });
                         }
@@ -939,9 +912,6 @@
                         success: function(r) {
                             Ext.message.msg(true, i18n_legend_set+' <span class="x-msg-hl">' + lsrw + '</span> ' + i18n_was_updated);
                             Ext.getCmp('predefinedmaplegendsetindicator_cb').getStore().load();
-                        },
-                        failure: function() {
-                            alert( 'Error: assignIndicatorsToMapLegendSet' );
                         }
                     });
                 }
@@ -992,9 +962,6 @@
                                     }
                                     
                                     Ext.getCmp('predefinedmaplegendsetdataelement_ms').setValue(dataElementString);							
-                                },
-                                failure: function() {
-                                    alert( i18n_status , i18n_error_while_saving_data );
                                 }
                             });
                         }
@@ -1041,9 +1008,6 @@
                         success: function(r) {
                             Ext.message.msg(true, i18n_legend_set+' <span class="x-msg-hl">' + lsrw + '</span> ' + i18n_was_updated);
                             Ext.getCmp('predefinedmaplegendsetdataelement_cb').getStore().load();
-                        },
-                        failure: function() {
-                            alert( 'Error: assignDataElementsToMapLegendSet' );
                         }
                     });
                 }
@@ -1148,10 +1112,6 @@
 			params: {id: topic},
 			success: function(r) {
 				Ext.getCmp(tab).body.update('<div id="help">' + r.responseText + '</div>');
-			},
-			failure: function() {
-				alert('Error: getHelpText');
-				return;
 			}
 		});
 	}
@@ -1296,8 +1256,7 @@
 							}
 							
 							Ext.getCmp('newnamecolumn_cb').getStore().loadData(data, false);
-						},
-						failure: function() {}
+						}
 					});
 				},
 				scope: this
@@ -1952,9 +1911,6 @@
                     Ext.message.msg(true, i18n_overlay + ' <span class="x-msg-hl">' + mln + '</span> '+i18n_was_deleted);
                     Ext.getCmp('maplayer_cb').getStore().load();
                     Ext.getCmp('maplayer_cb').clearValue();
-                },
-                failure: function() {
-                    alert( i18n_status , i18n_error_while_saving_data );
                 }
             });
             
@@ -2047,11 +2003,9 @@
 									Ext.getCmp('maplayername_tf').reset();
 									Ext.getCmp('maplayermapsourcefile_cb').clearValue();
 									Ext.getCmp('maplayerpathwmsoverlay_tf').reset();
-								},
-								failure: function() {}
+								}
 							});
-						},
-						failure: function() {}
+						}
 					});
 				}
 			}
@@ -2097,18 +2051,12 @@
                     {
                         title: '<span class="panel-tab-title">'+i18n_new+'</span>',
                         id: 'overlay0',
-                        items:
-                        [
-                            newMapLayerPanel
-                        ]
+                        items: [newMapLayerPanel]
                     },
                     {
                         title: '<span class="panel-tab-title">'+i18n_delete+'</span>',
                         id: 'overlay1',
-                        items:
-                        [
-                            deleteMapLayerPanel
-                        ]
+                        items: [deleteMapLayerPanel]
                     }
                 ]
             }
@@ -2171,9 +2119,6 @@
                             }
                         });
                     }
-                },
-                failure: function() {
-                    alert( 'Error: deleteMapLayer' );
                 }
             });
             
@@ -2240,11 +2185,9 @@
 									Ext.getCmp('maplayerbaselayersname_tf').reset();
 									Ext.getCmp('maplayerbaselayersurl_tf').reset();
 									Ext.getCmp('maplayerbaselayerslayer_tf').reset();
-								},
-								failure: function() {}
+								}
 							});
-						},
-						failure: function() {}
+						}
 					});
 				}
 			}
@@ -2638,9 +2581,6 @@
 						
 					MAP.addLayer(treeLayer);
 				}
-			},
-			failure: function() {
-				alert('Error: getAllMapLayers');
 			}
 		});
 	}

=== modified file 'dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Mapping.js'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Mapping.js	2010-10-11 23:06:18 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/resources/mapfish/widgets/geostat/Mapping.js	2010-10-14 13:05:47 +0000
@@ -213,10 +213,7 @@
                                         Ext.message.msg(true, i18n_all_relations_for_the_map + '<span class="x-msg-hl"> ' + Ext.getCmp('maps_cb').getRawValue() + '</span> ' + i18n_removed);
                                         
                                         mapping.classify(true, true);
-                                    },
-                                    failure: function() {
-                                        alert( i18n_error_while_deleting_relation_map_and_oranisation_unit );
-                                    } 
+                                    }
                                 });
                             },
                             scope: this
@@ -267,10 +264,7 @@
 										Ext.message.msg(true, msg);
 										
 										mapping.classify(true, true);
-									},
-									failure: function() {
-										alert(i18n_error_while_deleting_relation_map_and_oranisation_unit);
-									} 
+									}
 								});
                             },
                             scope: this
@@ -303,10 +297,7 @@
 													mapping.relation = false;
 													Ext.getCmp('filter_tf').setValue('');
 													mapping.classify(true, true);
-												},
-												failure: function() {
-													alert( 'Error: addOrUpdateMapOrganisationUnitRelation' );
-												} 
+												}
 											});
 										}
 										else {
@@ -463,15 +454,9 @@
                        
                         Ext.getCmp('grid_gp').getStore().load();
                         mapping.classify(false, position);
-                    },
-                    failure: function() {
-                        alert( 'Error: addOrUpdateMapOrganisationUnitRelations' );
-                    } 
+                    }
                 });
-            },
-            failure: function() {
-                alert( i18n_status , i18n_error_while_retrieving_data );
-            } 
+            }
         });
     },