Fixed Error Management

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-unionwizard-widget@101908 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Giancarlo Panichi 2014-12-04 17:06:40 +00:00 committed by Giancarlo Panichi
parent 23eaf4805a
commit 69f8d6ddc4
1 changed files with 9 additions and 9 deletions

View File

@ -24,6 +24,7 @@ import com.sencha.gxt.core.client.util.Margins;
import com.sencha.gxt.widget.core.client.FramedPanel; import com.sencha.gxt.widget.core.client.FramedPanel;
import com.sencha.gxt.widget.core.client.container.BoxLayoutContainer.BoxLayoutData; import com.sencha.gxt.widget.core.client.container.BoxLayoutContainer.BoxLayoutData;
import com.sencha.gxt.widget.core.client.container.HtmlLayoutContainer; import com.sencha.gxt.widget.core.client.container.HtmlLayoutContainer;
import com.sencha.gxt.widget.core.client.container.MarginData;
import com.sencha.gxt.widget.core.client.container.VBoxLayoutContainer; import com.sencha.gxt.widget.core.client.container.VBoxLayoutContainer;
import com.sencha.gxt.widget.core.client.container.VBoxLayoutContainer.VBoxLayoutAlign; import com.sencha.gxt.widget.core.client.container.VBoxLayoutContainer.VBoxLayoutAlign;
@ -81,7 +82,7 @@ public class UnionOperationInProgressCard extends WizardCard implements
operationInProgressPanel.add(resultField, new BoxLayoutData( operationInProgressPanel.add(resultField, new BoxLayoutData(
new Margins(10, 5, 10, 5))); new Margins(10, 5, 10, 5)));
setContent(operationInProgressPanel); setCenterWidget(operationInProgressPanel, new MarginData(0));
resultField.setVisible(false); resultField.setVisible(false);
} }
@ -108,18 +109,18 @@ public class UnionOperationInProgressCard extends WizardCard implements
if (caught instanceof TDGWTIsLockedException) { if (caught instanceof TDGWTIsLockedException) {
Log.error(caught.getLocalizedMessage()); Log.error(caught.getLocalizedMessage());
showErrorAndHide("Error Locked", showErrorAndHide("Error Locked",
caught.getLocalizedMessage(), caught); caught.getLocalizedMessage(), "",
caught);
} else { } else {
if (caught instanceof TDGWTIsFinalException) { if (caught instanceof TDGWTIsFinalException) {
Log.error(caught.getLocalizedMessage()); Log.error(caught.getLocalizedMessage());
showErrorAndHide("Error Final", showErrorAndHide("Error Final",
caught.getLocalizedMessage(), caught.getLocalizedMessage(), "",
caught); caught);
} else { } else {
showErrorAndHide( showErrorAndHide("Error in Union",
"Error in Union", "An error occured in union.",
"An error occured in union: " caught.getLocalizedMessage(),
+ caught.getLocalizedMessage(),
caught); caught);
} }
} }
@ -133,7 +134,6 @@ public class UnionOperationInProgressCard extends WizardCard implements
public void setup() { public void setup() {
getWizardWindow().setEnableBackButton(false); getWizardWindow().setEnableBackButton(false);
setBackButtonVisible(false); setBackButtonVisible(false);
setNextButtonVisible(false);
getWizardWindow().setEnableNextButton(false); getWizardWindow().setEnableNextButton(false);
getWizardWindow().setNextButtonToFinish(); getWizardWindow().setNextButtonToFinish();
startUnion(); startUnion();
@ -189,7 +189,7 @@ public class UnionOperationInProgressCard extends WizardCard implements
new SessionExpiredEvent( new SessionExpiredEvent(
SessionExpiredType.EXPIREDONSERVER)); SessionExpiredType.EXPIREDONSERVER));
} else { } else {
showErrorAndHide("Error in Union", reason, caught); showErrorAndHide("Error in Union", reason, details, caught);
} }
forceLayout(); forceLayout();