← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 17507: PT DV GIS ER EV clear button.

 

Merge authors:
  Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 17507 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Mon 2014-11-17 16:48:57 +0100
message:
  PT DV GIS ER EV clear button.
modified:
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-reports/i18n/i18n_app.properties
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-reports/scripts/app.js
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-visualizer/i18n/i18n_app.properties
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-visualizer/scripts/app.js
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/i18n/i18n_app.properties
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/scripts/app.js
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-pivot/i18n/i18n_app.properties
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-pivot/scripts/app.js
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-visualizer/i18n/i18n_app.properties
  dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-visualizer/scripts/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-apps/src/main/webapp/dhis-web-event-reports/i18n/i18n_app.properties'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-reports/i18n/i18n_app.properties	2014-11-06 14:00:37 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-reports/i18n/i18n_app.properties	2014-11-17 15:42:17 +0000
@@ -173,3 +173,4 @@
 last_6_months=Last 6 months
 initializing=Initializing
 created_by=Created by
+clear_event_report=Clear event report

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-reports/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-reports/scripts/app.js	2014-11-13 10:43:12 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-reports/scripts/app.js	2014-11-17 15:42:17 +0000
@@ -7023,11 +7023,37 @@
 			iconCls: 'ns-button-icon-table',
 			toggleGroup: 'module',
 			pressed: true,
-			handler: function() {
-				if (!this.pressed) {
-					this.toggle();
-				}
-			}
+            menu: {},
+            handler: function(b) {
+                b.menu = Ext.create('Ext.menu.Menu', {
+                    closeAction: 'destroy',
+                    shadow: false,
+                    showSeparator: false,
+                    items: [
+                        {
+                            text: NS.i18n.clear_event_report + '&nbsp;&nbsp;', //i18n
+                            cls: 'ns-menu-item-noicon',
+                            handler: function() {
+                                window.location.href = ns.core.init.contextPath + '/dhis-web-event-reports';
+                            }
+                        }
+                    ],
+                    listeners: {
+                        show: function() {
+                            ns.core.web.window.setAnchorPosition(b.menu, b);
+                        },
+                        hide: function() {
+                            b.menu.destroy();
+                            defaultButton.toggle();
+                        },
+                        destroy: function(m) {
+                            b.menu = null;
+                        }
+                    }
+                });
+
+                b.menu.show();
+            }
 		});
 
 		centerRegion = Ext.create('Ext.panel.Panel', {
@@ -7082,7 +7108,7 @@
 										text: NS.i18n.go_to_event_charts + '&nbsp;&nbsp;', //i18n
 										cls: 'ns-menu-item-noicon',
 										handler: function() {
-											window.location.href = ns.core.init.contextPath + '/dhis-web-event-visualizer/index.html';
+											window.location.href = ns.core.init.contextPath + '/dhis-web-event-visualizer';
 										}
 									},
 									'-',

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-visualizer/i18n/i18n_app.properties'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-visualizer/i18n/i18n_app.properties	2014-11-06 14:00:37 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-visualizer/i18n/i18n_app.properties	2014-11-17 15:42:17 +0000
@@ -197,3 +197,4 @@
 last_6_months=Last 6 months
 initializing=Initializing
 created_by=Created by
+clear_event_chart=Clear event chart

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-visualizer/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-visualizer/scripts/app.js	2014-11-13 10:43:12 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-event-visualizer/scripts/app.js	2014-11-17 15:42:17 +0000
@@ -6665,11 +6665,37 @@
 			iconCls: 'ns-button-icon-chart',
 			toggleGroup: 'module',
 			pressed: true,
-			handler: function() {
-				if (!this.pressed) {
-					this.toggle();
-				}
-			}
+            menu: {},
+            handler: function(b) {
+                b.menu = Ext.create('Ext.menu.Menu', {
+                    closeAction: 'destroy',
+                    shadow: false,
+                    showSeparator: false,
+                    items: [
+                        {
+                            text: NS.i18n.clear_event_chart + '&nbsp;&nbsp;', //i18n
+                            cls: 'ns-menu-item-noicon',
+                            handler: function() {
+                                window.location.href = ns.core.init.contextPath + '/dhis-web-event-visualizer';
+                            }
+                        }
+                    ],
+                    listeners: {
+                        show: function() {
+                            ns.core.web.window.setAnchorPosition(b.menu, b);
+                        },
+                        hide: function() {
+                            b.menu.destroy();
+                            defaultButton.toggle();
+                        },
+                        destroy: function(m) {
+                            b.menu = null;
+                        }
+                    }
+                });
+
+                b.menu.show();
+            }
 		});
 
 		centerRegion = Ext.create('Ext.panel.Panel', {
@@ -6723,7 +6749,7 @@
 										text: NS.i18n.go_to_event_reports + '&nbsp;&nbsp;', //i18n
 										cls: 'ns-menu-item-noicon',
 										handler: function() {
-											window.location.href = ns.core.init.contextPath + '/dhis-web-event-reports/index.html';
+											window.location.href = ns.core.init.contextPath + '/dhis-web-event-reports';
 										}
 									},
 									'-',

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/i18n/i18n_app.properties'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/i18n/i18n_app.properties	2014-11-16 10:31:19 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/i18n/i18n_app.properties	2014-11-17 15:42:17 +0000
@@ -416,3 +416,4 @@
 initializing=Initializing
 created_by=Created by
 created_by=Created by
+clear_map=Clear map

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/scripts/app.js	2014-11-13 10:43:12 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/scripts/app.js	2014-11-17 15:42:17 +0000
@@ -8479,11 +8479,37 @@
 			iconCls: 'gis-button-icon-map',
 			toggleGroup: 'module',
 			pressed: true,
-			handler: function() {
-				if (!this.pressed) {
-					this.toggle();
-				}
-			}
+            menu: {},
+            handler: function(b) {
+                b.menu = Ext.create('Ext.menu.Menu', {
+                    closeAction: 'destroy',
+                    shadow: false,
+                    showSeparator: false,
+                    items: [
+                        {
+                            text: GIS.i18n.clear_map + '&nbsp;&nbsp;', //i18n
+                            cls: 'gis-menu-item-noicon',
+                            handler: function() {
+                                window.location.href = gis.init.contextPath + '/dhis-web-mapping';
+                            }
+                        }
+                    ],
+                    listeners: {
+                        show: function() {
+                            gis.util.gui.window.setAnchorPosition(b.menu, b);
+                        },
+                        hide: function() {
+                            b.menu.destroy();
+                            defaultButton.toggle();
+                        },
+                        destroy: function(m) {
+                            b.menu = null;
+                        }
+                    }
+                });
+
+                b.menu.show();
+            }
 		});
 
 		interpretationItem = Ext.create('Ext.menu.Item', {
@@ -8849,7 +8875,7 @@
 										text: GIS.i18n.go_to_pivot_tables + '&nbsp;&nbsp;', //i18n
 										cls: 'gis-menu-item-noicon',
 										handler: function() {
-											window.location.href = gis.init.contextPath + '/dhis-web-pivot/index.html';
+											window.location.href = gis.init.contextPath + '/dhis-web-pivot';
 										}
 									},
 									'-',
@@ -8905,7 +8931,7 @@
 										text: GIS.i18n.go_to_charts + '&nbsp;&nbsp;', //i18n
 										cls: 'gis-menu-item-noicon',
 										handler: function() {
-											window.location.href = gis.init.contextPath + '/dhis-web-visualizer/index.html';
+											window.location.href = gis.init.contextPath + '/dhis-web-visualizer';
 										}
 									},
 									'-',

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-pivot/i18n/i18n_app.properties'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-pivot/i18n/i18n_app.properties	2014-11-06 15:44:09 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-pivot/i18n/i18n_app.properties	2014-11-17 15:42:17 +0000
@@ -173,3 +173,4 @@
 last_6_months=Last 6 months
 created_by=Created by
 initializing=Initializing
+clear_pivot_table=Clear pivot table

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-pivot/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-pivot/scripts/app.js	2014-11-14 15:05:48 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-pivot/scripts/app.js	2014-11-17 15:42:17 +0000
@@ -5637,11 +5637,37 @@
 			iconCls: 'ns-button-icon-table',
 			toggleGroup: 'module',
 			pressed: true,
-			handler: function() {
-				if (!this.pressed) {
-					this.toggle();
-				}
-			}
+            menu: {},
+            handler: function(b) {
+                b.menu = Ext.create('Ext.menu.Menu', {
+                    closeAction: 'destroy',
+                    shadow: false,
+                    showSeparator: false,
+                    items: [
+                        {
+                            text: NS.i18n.clear_pivot_table + '&nbsp;&nbsp;', //i18n
+                            cls: 'ns-menu-item-noicon',
+                            handler: function() {
+                                window.location.href = ns.core.init.contextPath + '/dhis-web-pivot';
+                            }
+                        }
+                    ],
+                    listeners: {
+                        show: function() {
+                            ns.core.web.window.setAnchorPosition(b.menu, b);
+                        },
+                        hide: function() {
+                            b.menu.destroy();
+                            defaultButton.toggle();
+                        },
+                        destroy: function(m) {
+                            b.menu = null;
+                        }
+                    }
+                });
+
+                b.menu.show();
+            }
 		});
 
 		centerRegion = Ext.create('Ext.panel.Panel', {
@@ -5696,7 +5722,7 @@
 										text: NS.i18n.go_to_charts + '&nbsp;&nbsp;', //i18n
 										cls: 'ns-menu-item-noicon',
 										handler: function() {
-											window.location.href = ns.core.init.contextPath + '/dhis-web-visualizer/index.html';
+											window.location.href = ns.core.init.contextPath + '/dhis-web-visualizer';
 										}
 									},
 									'-',
@@ -5752,7 +5778,7 @@
 										text: NS.i18n.go_to_maps + '&nbsp;&nbsp;', //i18n
 										cls: 'ns-menu-item-noicon',
 										handler: function() {
-											window.location.href = ns.core.init.contextPath + '/dhis-web-mapping/index.html';
+											window.location.href = ns.core.init.contextPath + '/dhis-web-mapping';
 										}
 									},
 									'-',

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-visualizer/i18n/i18n_app.properties'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-visualizer/i18n/i18n_app.properties	2014-11-16 10:31:19 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-visualizer/i18n/i18n_app.properties	2014-11-17 15:42:17 +0000
@@ -91,7 +91,7 @@
 group_sets=Group sets
 none=None
 et_no_data=No data returned from server
-em_no_data=Please ensure that there is data stored in the database and that data mart has been run properly. 
+em_no_data=Please ensure that there is data stored in the database and that data mart has been run properly.
 et_invalid_dimension_setup=Invalid dimension setup
 em_invalid_dimension_setup=Please select series/category/filter dimensions.
 et_no_indicators_dataelements_datasets=No data units selected
@@ -120,7 +120,7 @@
 wm_multiple_filter_orgunit=Multiple organisation units selected as filter.
 wm_multiple_filter_groups=Multiple organisation unit groups selected as filter.
 wm_first_filter_used=The first one is being used.
-available_attribute=Available attribute 
+available_attribute=Available attribute
 selected_attribute=Selected attribute
 show_data=Show series data
 share=Share
@@ -246,3 +246,4 @@
 last_6_months=Last 6 months
 created_by=Created by
 initializing=Initializing
+clear_chart=Clear chart

=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-visualizer/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-visualizer/scripts/app.js	2014-11-14 13:00:32 +0000
+++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-visualizer/scripts/app.js	2014-11-17 15:42:17 +0000
@@ -5642,11 +5642,37 @@
 			iconCls: 'ns-button-icon-chart',
 			toggleGroup: 'module',
 			pressed: true,
-			handler: function() {
-				if (!this.pressed) {
-					this.toggle();
-				}
-			}
+            menu: {},
+            handler: function(b) {
+                b.menu = Ext.create('Ext.menu.Menu', {
+                    closeAction: 'destroy',
+                    shadow: false,
+                    showSeparator: false,
+                    items: [
+                        {
+                            text: NS.i18n.clear_chart + '&nbsp;&nbsp;', //i18n
+                            cls: 'ns-menu-item-noicon',
+                            handler: function() {
+                                window.location.href = ns.core.init.contextPath + '/dhis-web-visualizer';
+                            }
+                        }
+                    ],
+                    listeners: {
+                        show: function() {
+                            ns.core.web.window.setAnchorPosition(b.menu, b);
+                        },
+                        hide: function() {
+                            b.menu.destroy();
+                            defaultButton.toggle();
+                        },
+                        destroy: function(m) {
+                            b.menu = null;
+                        }
+                    }
+                });
+
+                b.menu.show();
+            }
 		});
 
 		centerRegion = Ext.create('Ext.panel.Panel', {
@@ -5700,7 +5726,7 @@
 										text: NS.i18n.go_to_pivot_tables + '&nbsp;&nbsp;', //i18n
 										cls: 'ns-menu-item-noicon',
 										handler: function() {
-											window.location.href = ns.core.init.contextPath + '/dhis-web-pivot/index.html';
+											window.location.href = ns.core.init.contextPath + '/dhis-web-pivot';
 										}
 									},
 									'-',
@@ -5757,7 +5783,7 @@
 										text: NS.i18n.go_to_maps + '&nbsp;&nbsp;', //i18n
 										cls: 'ns-menu-item-noicon',
 										handler: function() {
-											window.location.href = ns.core.init.contextPath + '/dhis-web-mapping/index.html';
+											window.location.href = ns.core.init.contextPath + '/dhis-web-mapping';
 										}
 									},
 									'-',