Fixed Error Management
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-csv-export-widget@101899 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
82d7ea9dbe
commit
9fef37b20a
|
@ -27,6 +27,7 @@ import com.sencha.gxt.core.client.util.Padding;
|
||||||
import com.sencha.gxt.core.client.util.ToggleGroup;
|
import com.sencha.gxt.core.client.util.ToggleGroup;
|
||||||
import com.sencha.gxt.data.shared.StringLabelProvider;
|
import com.sencha.gxt.data.shared.StringLabelProvider;
|
||||||
import com.sencha.gxt.widget.core.client.box.AlertMessageBox;
|
import com.sencha.gxt.widget.core.client.box.AlertMessageBox;
|
||||||
|
import com.sencha.gxt.widget.core.client.container.MarginData;
|
||||||
import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer;
|
import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer;
|
||||||
import com.sencha.gxt.widget.core.client.event.HideEvent;
|
import com.sencha.gxt.widget.core.client.event.HideEvent;
|
||||||
import com.sencha.gxt.widget.core.client.event.HideEvent.HideHandler;
|
import com.sencha.gxt.widget.core.client.event.HideEvent.HideHandler;
|
||||||
|
@ -73,7 +74,7 @@ public class CSVExportConfigCard extends WizardCard {
|
||||||
this.exportSession = exportSession;
|
this.exportSession = exportSession;
|
||||||
|
|
||||||
FormPanel panel = createPanel();
|
FormPanel panel = createPanel();
|
||||||
setContent(panel);
|
setCenterWidget(panel, new MarginData(0));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -130,7 +131,7 @@ public class CSVExportConfigCard extends WizardCard {
|
||||||
|
|
||||||
Log.error("Error loading charset list", caught);
|
Log.error("Error loading charset list", caught);
|
||||||
showErrorAndHide("Error loading charset list",
|
showErrorAndHide("Error loading charset list",
|
||||||
"Error loading charset list", caught);
|
"Error loading charset list:",caught.getLocalizedMessage() , caught);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,6 +23,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;
|
||||||
|
|
||||||
|
@ -79,7 +80,7 @@ public class CSVOperationInProgressCard 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);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -103,12 +104,12 @@ public class CSVOperationInProgressCard 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 {
|
||||||
showErrorAndHide("Error in exportCSV",
|
showErrorAndHide("Error in exportCSV",
|
||||||
"An error occured in exportCSV: "
|
"An error occured in exportCSV: ",
|
||||||
+ caught.getLocalizedMessage(),
|
caught.getLocalizedMessage(),
|
||||||
caught);
|
caught);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -120,7 +121,6 @@ public class CSVOperationInProgressCard 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();
|
||||||
exportCSV();
|
exportCSV();
|
||||||
|
@ -180,7 +180,7 @@ public class CSVOperationInProgressCard extends WizardCard implements
|
||||||
SessionExpiredType.EXPIREDONSERVER));
|
SessionExpiredType.EXPIREDONSERVER));
|
||||||
} else {
|
} else {
|
||||||
showErrorAndHide("Error in CSV Export",
|
showErrorAndHide("Error in CSV Export",
|
||||||
reason,caught);
|
reason,details, caught);
|
||||||
}
|
}
|
||||||
|
|
||||||
forceLayout();
|
forceLayout();
|
||||||
|
|
|
@ -136,7 +136,7 @@ public class ColumnDataGridPanel extends ContentPanel implements
|
||||||
if (caught instanceof TDGWTIsLockedException) {
|
if (caught instanceof TDGWTIsLockedException) {
|
||||||
Log.error(caught.getLocalizedMessage());
|
Log.error(caught.getLocalizedMessage());
|
||||||
parent.showErrorAndHide("Error Locked",
|
parent.showErrorAndHide("Error Locked",
|
||||||
caught.getLocalizedMessage(), caught);
|
caught.getLocalizedMessage(), "", caught);
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
Log.error("No load columns: "
|
Log.error("No load columns: "
|
||||||
|
|
Loading…
Reference in New Issue