?
Referenced as Related to: # 5246
avatar javigomez
javigomez
28 Nov 2014

I was working on a plane on my Localhost without wifi and I noticed the following issue:

  • turn off your Wifi
  • go to Extensions Manager
  • The "Install from the Web" will start the spinner to show you that is trying to reach the server.
  • But since you already know that there is no internet connection you go to "Upload package file"
  • There you see the problem, the Spinner will not allow you to select a extension until it finishes trying to connect the server:

screen shot 2014-11-28 at 10 11 21

Actually the spinner should remain under the "Install from the Web" and not ve visible at "Upload package file".

VIDEO: I have made a video to show the issue: https://www.youtube.com/watch?v=sjKAyTk97IA

Also when you get back internet the only way to get the "install from the web" is to go via menu again to "extensions manager" to reload the page. I suggest we can add something like:

screen shot 2014-11-28 at 10 18 05

Thoughts?

Anyone interested in coding the fix?

Thanks

avatar javigomez javigomez - open - 28 Nov 2014
avatar jissues-bot jissues-bot - change - 28 Nov 2014
Labels Added: ?
avatar javigomez javigomez - change - 28 Nov 2014
Category Administration
avatar brianteeman
brianteeman - comment - 28 Nov 2014

Based on the video I am marking this as confirmed


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5233.

avatar brianteeman brianteeman - change - 28 Nov 2014
Status New Confirmed
avatar dgt41
dgt41 - comment - 28 Nov 2014

Inserting these lines line 134 of /plugins/installer/webinstaller/webinstaller.php should do it

        jQuery('a[data-toggle="tab"]').on('shown', function (e) {
            var target = jQuery(e.target).attr("href");
            if ((target != '#web')) {
                jQuery('#appsloading').hide();
            }
        });

So the last part of the script in this file to be like:

    if (!apps_is_hathor)
    {
        if(typeof jQuery('#myTabTabs a[href="'+localStorage.getItem('tab-href')+'"]').prop('tagName') == 'undefined' ||
            localStorage.getItem('tab-href') == null ||
            localStorage.getItem('tab-href') == 'undefined' ||
            !localStorage.getItem('tab-href')) {
            window.localStorage.setItem('tab-href', jQuery('#myTabTabs a').get(0));
        }

        if (apps_installfrom_url == '' && localStorage.getItem('tab-href') == '#web')
        {
            jQuery('.nav-tabs #myTabTabs ').each(function(index, value){
                value.removeClass('active');
            });
            jQuery(eventpoint).addClass('active');
            window.localStorage.setItem('tab-href', jQuery(eventpoint).children('a').attr('href'));
            if (jQuery(eventpoint).children('a').attr('href') == '#web')
            {
                jQuery(eventpoint).click();
            }
        }

        jQuery('a[data-toggle="tab"]').on('shown', function (e) {
            var target = jQuery(e.target).attr("href");
            if ((target != '#web')) {
                jQuery('#appsloading').hide();
            }
        });
    }
});
avatar Bakual
Bakual - comment - 28 Nov 2014

Can you open a PR on the webinstaller repo then please and close this one?

avatar dgt41
dgt41 - comment - 28 Nov 2014

But the part with the retry link is not yet solved. My snippet covers the first half of @javigomez issue...
Anyway if nobody comes with a pr for both then I will, but tomorrow!

avatar dgt41
dgt41 - comment - 29 Nov 2014

I’ll post a PR on webinstaller repo soon, just a heads up:
There is a change in language file com_installer.ini

COM_INSTALLER_WEBINSTALLER_INSTALL_WEB_LOADING_ERROR="Cannot connect to the Joomla! server. Please try again later. <a class="_QQ_"btn btn-danger"_QQ_" onclick="_QQ_"location.reload();"_QQ_">Retry</a>”
avatar dgt41
dgt41 - comment - 29 Nov 2014

This can be closed as we have PRs

avatar brianteeman brianteeman - change - 29 Nov 2014
Status Confirmed Closed
avatar brianteeman brianteeman - close - 29 Nov 2014
avatar brianteeman brianteeman - change - 29 Nov 2014
Closed_Date 0000-00-00 00:00:00 2014-11-29 12:40:54

Add a Comment

Login with GitHub to post a comment