Fixed blocking on error
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-extractcodelist-widget@119276 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
f0721ded2c
commit
09aefb85b9
|
@ -48,6 +48,7 @@ public class ExtractCodelistOperationInProgressCard extends WizardCard
|
|||
private HtmlLayoutContainer resultField;
|
||||
private boolean automaticallyAttached;
|
||||
private TRId collateralTRId;
|
||||
private MonitorDialog monitorDialog;
|
||||
|
||||
public ExtractCodelistOperationInProgressCard(
|
||||
final ExtractCodelistSession extractCodelistSession) {
|
||||
|
@ -89,6 +90,7 @@ public class ExtractCodelistOperationInProgressCard extends WizardCard
|
|||
showErrorAndHide("Error in extract codelist",
|
||||
"An error occured in extract codelist.",
|
||||
caught.getLocalizedMessage(), caught);
|
||||
return;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -96,17 +98,24 @@ public class ExtractCodelistOperationInProgressCard extends WizardCard
|
|||
|
||||
public void setCollateralTRIdFinal(ArrayList<TRId> collateralIds) {
|
||||
if (collateralIds == null || collateralIds.isEmpty()) {
|
||||
monitorDialog.hide();
|
||||
showErrorAndHide("Error in extract codelist",
|
||||
"An error occured setting collateral table final.",
|
||||
"No collateral id retrieved", new Throwable(
|
||||
"No collateral id retrieved"));
|
||||
|
||||
return;
|
||||
|
||||
}
|
||||
collateralTRId = collateralIds.get(0);
|
||||
if (collateralTRId == null) {
|
||||
monitorDialog.hide();
|
||||
showErrorAndHide("Error in extract codelist",
|
||||
"An error occured setting collateral table final.",
|
||||
"Collateral id is null", new Throwable(
|
||||
"Collateral id is null"));
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
TDGWTServiceAsync.INSTANCE.setTabResourceToFinal(collateralTRId,
|
||||
|
@ -268,7 +277,7 @@ public class ExtractCodelistOperationInProgressCard extends WizardCard
|
|||
|
||||
//
|
||||
protected void openMonitorDialog(String taskId) {
|
||||
MonitorDialog monitorDialog = new MonitorDialog(taskId, getEventBus());
|
||||
monitorDialog = new MonitorDialog(taskId, getEventBus());
|
||||
monitorDialog.addProgressDialogListener(this);
|
||||
monitorDialog.setBackgroundBtnEnabled(false);
|
||||
monitorDialog.show();
|
||||
|
|
Loading…
Reference in New Issue