Browse Source

Merge pull request #323 in DESIGN/design from ~YAOH.WU/design:release/10.0 to release/10.0

* commit 'fabe66bd5e3c480a5277c0519e474f30a895d871':
  REPORT-10386 远程权限交互验收问题1
research/10.0
yaoh.wu 6 years ago
parent
commit
07db9a0904
  1. 21
      designer-base/src/main/java/com/fr/env/RemoteEnvPane.java

21
designer-base/src/main/java/com/fr/env/RemoteEnvPane.java vendored

@ -523,9 +523,7 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> {
DesignerEnvManager.getEnvManager().setCertificatePass(connection.getCertSecretKey()); DesignerEnvManager.getEnvManager().setCertificatePass(connection.getCertSecretKey());
try { try {
return WorkContext.getConnector().testConnection(connection); return WorkContext.getConnector().testConnection(connection);
} catch (AuthException e) { } catch (AuthException ignored) {
message.setText(Toolkit.i18nText("Fine-Designer_Basic_Remote_Connect_Auth_Failed"));
uiLabel.setIcon(UIManager.getIcon("OptionPane.errorIcon"));
return null; return null;
} }
} }
@ -534,13 +532,18 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> {
protected void done() { protected void done() {
okButton.setEnabled(true); okButton.setEnabled(true);
try { try {
if (get()) { Boolean result = get();
message.setText(Toolkit.i18nText("Fine-Designer_Basic_Remote_Connect_Successful")); if (result == null) {
uiLabel.setIcon(UIManager.getIcon("OptionPane.informationIcon")); message.setText(Toolkit.i18nText("Fine-Designer_Basic_Remote_Connect_Auth_Failed"));
} else {
message.setText(Toolkit.i18nText("Fine-Designer_Basic_Remote_Connect_Failed"));
uiLabel.setIcon(UIManager.getIcon("OptionPane.errorIcon")); uiLabel.setIcon(UIManager.getIcon("OptionPane.errorIcon"));
} else {
if (result) {
message.setText(Toolkit.i18nText("Fine-Designer_Basic_Remote_Connect_Successful"));
uiLabel.setIcon(UIManager.getIcon("OptionPane.informationIcon"));
} else {
message.setText(Toolkit.i18nText("Fine-Designer_Basic_Remote_Connect_Failed"));
uiLabel.setIcon(UIManager.getIcon("OptionPane.errorIcon"));
}
} }
} catch (InterruptedException | ExecutionException e) { } catch (InterruptedException | ExecutionException e) {
FineLoggerFactory.getLogger().error(e, e.getMessage()); FineLoggerFactory.getLogger().error(e, e.getMessage());

Loading…
Cancel
Save