added loading box to mercurial package installation

This commit is contained in:
Sebastian Sdorra
2011-04-28 20:54:01 +02:00
parent d4297b6176
commit a60ed8282f

View File

@@ -336,6 +336,17 @@ Sonia.hg.ConfigWizardPanel = Ext.extend(Ext.Panel,{
console.debug( 'install mercurial package ' + pkg );
}
// TODO i18n
var lbox = Ext.MessageBox.show({
title: 'Loading',
msg: 'install mercurial package ' + pkg,
width: 300,
wait: true,
animate: true,
progress: true,
closable: false
});
Ext.Ajax.request({
url: restUrl + 'config/repositories/hg/packages/' + pkg + '.json',
method: 'POST',
@@ -345,12 +356,14 @@ Sonia.hg.ConfigWizardPanel = Ext.extend(Ext.Panel,{
if ( debug ){
console.debug('package successfully installed');
}
lbox.hide();
this.fireEvent('finish');
},
failure: function(){
if ( debug ){
console.debug('package installation failed');
}
lbox.hide();
// TODO i18n
Ext.MessageBox.show({
title: 'Error',