Browse Source

异常处理

research/10.0
yaoh.wu 6 years ago
parent
commit
76b881ea2f
  1. 14
      designer-base/src/main/java/com/fr/design/actions/file/export/AbstractExportAction.java

14
designer-base/src/main/java/com/fr/design/actions/file/export/AbstractExportAction.java

@ -6,6 +6,7 @@ import com.fr.design.gui.iprogressbar.FRProgressBar;
import com.fr.design.i18n.Toolkit; import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.DesignerContext; import com.fr.design.mainframe.DesignerContext;
import com.fr.design.mainframe.JTemplate; import com.fr.design.mainframe.JTemplate;
import com.fr.exception.RemoteDesignPermissionDeniedException;
import com.fr.file.FILE; import com.fr.file.FILE;
import com.fr.file.FILEChooserPane; import com.fr.file.FILEChooserPane;
import com.fr.file.filter.ChooseFileFilter; import com.fr.file.filter.ChooseFileFilter;
@ -170,6 +171,19 @@ public abstract class AbstractExportAction<E extends JTemplate<?, ?>> extends JT
JOptionPane.showMessageDialog( JOptionPane.showMessageDialog(
DesignerContext.getDesignerFrame(), DesignerContext.getDesignerFrame(),
Toolkit.i18nText("Fine-Design_Report_Exported_Successfully") + "\n" + name); Toolkit.i18nText("Fine-Design_Report_Exported_Successfully") + "\n" + name);
} catch (RemoteDesignPermissionDeniedException exp) {
this.setProgress(100);
target.closeTemplate();
FineLoggerFactory.getLogger().error(exp.getMessage(), exp);
JOptionPane.showMessageDialog(
DesignerContext.getDesignerFrame(),
Toolkit.i18nText("Fine-Engine_Remote_Design_Permission_Denied"),
null,
JOptionPane.ERROR_MESSAGE,
UIManager.getIcon("OptionPane.errorIcon")
);
} catch (Exception exp) { } catch (Exception exp) {
this.setProgress(100); this.setProgress(100);
target.closeTemplate(); target.closeTemplate();

Loading…
Cancel
Save