[BUGFIX] The requested URL typo3/undefined was not found on this server
authorKay Strobach <typo3@kay-strobach.de>
Sat, 30 Jul 2011 16:56:55 +0000 (18:56 +0200)
committerSusanne Moog <typo3@susannemoog.de>
Sun, 31 Jul 2011 17:52:05 +0000 (19:52 +0200)
Wrong handling of module url changes in modulemenu causes false
loadings.

This change changes the loading logic a bit, so that it works again.

Resolves: #28594
Releases: 4.6, 4.5

Change-Id: I1692040e38645d68002ae494e9261fd0ccb4d42d
Reviewed-on: http://review.typo3.org/3909
Reviewed-by: Philipp Gampe
Tested-by: Philipp Gampe
Reviewed-by: Susanne Moog
Tested-by: Susanne Moog
typo3/js/modulemenu.js

index 9cbeec5..6d7d845 100644 (file)
@@ -225,6 +225,7 @@ TYPO3.ModuleMenu.App = {
        loadModuleComponents: function(record, params) {
                var url;
                var mod = record.name;
+               var relatedCard;
                if (record.navigationComponentId) {
                                this.loadNavigationComponent(record.navigationComponentId);
                                TYPO3.Backend.NavigationDummy.hide();
@@ -239,15 +240,15 @@ TYPO3.ModuleMenu.App = {
                                TYPO3.Backend.NavigationContainer.hide();
                                TYPO3.Backend.NavigationDummy.show();
                        }
-                       if (Ext.getCmp('typo3-card-' + record.name)) {
+                       relatedCard = Ext.getCmp('typo3-card-' + record.name);
+                       if (relatedCard) {
                                        // Check wether the panel is an iframe or not - if it is try to set the uri
-                               if (Ext.getCmp('typo3-card-' + record.name).getXType() == 'iframePanel') {
+                               if (relatedCard.getXType() == 'iframePanel') {
                                                // Handle click on already opened module and evt. force reload
-                                       if (Ext.getCmp('typo3-contentContainerWrapper').layout.activeItem.id == 'typo3-card-' + record.name) {
-                                               Ext.getCmp('typo3-card-'+record.name).setUrl(url + (params ? (url.indexOf('?') !== -1 ? '&' : '?') + params : ''));
-                                       } else {
+                                       if ((Ext.getCmp('typo3-contentContainerWrapper').layout.activeItem.id == 'typo3-card-' + record.name)
+                                               || (relatedCard.getUrl() == 'about:blank')) {
                                                url = record.originalLink;
-                                               Ext.getCmp('typo3-card-'+record.name).setUrlIfChanged(url + (params ? (url.indexOf('?') !== -1 ? '&' : '?') + params : ''));
+                                               Ext.getCmp('typo3-card-'+record.name).setUrl(url + (params ? (url.indexOf('?') !== -1 ? '&' : '?') + params : ''));
                                        }
                                }
                                        // Independed of the xtype activate the module