|
|
@ -16,12 +16,14 @@ import com.fr.general.Inter; |
|
|
|
import com.fr.stable.StringUtils; |
|
|
|
import com.fr.stable.StringUtils; |
|
|
|
import com.fr.third.guava.base.Strings; |
|
|
|
import com.fr.third.guava.base.Strings; |
|
|
|
import com.fr.workspace.WorkContext; |
|
|
|
import com.fr.workspace.WorkContext; |
|
|
|
|
|
|
|
import com.fr.workspace.connect.AuthException; |
|
|
|
import com.fr.workspace.connect.WorkspaceConnection; |
|
|
|
import com.fr.workspace.connect.WorkspaceConnection; |
|
|
|
|
|
|
|
|
|
|
|
import javax.swing.BorderFactory; |
|
|
|
import javax.swing.BorderFactory; |
|
|
|
import javax.swing.BoxLayout; |
|
|
|
import javax.swing.BoxLayout; |
|
|
|
import javax.swing.JDialog; |
|
|
|
import javax.swing.JDialog; |
|
|
|
import javax.swing.JFileChooser; |
|
|
|
import javax.swing.JFileChooser; |
|
|
|
|
|
|
|
import javax.swing.JOptionPane; |
|
|
|
import javax.swing.JPanel; |
|
|
|
import javax.swing.JPanel; |
|
|
|
import javax.swing.JTextPane; |
|
|
|
import javax.swing.JTextPane; |
|
|
|
import javax.swing.SwingConstants; |
|
|
|
import javax.swing.SwingConstants; |
|
|
@ -277,6 +279,10 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> { |
|
|
|
this.certPathInput.setText(certPath); |
|
|
|
this.certPathInput.setText(certPath); |
|
|
|
this.certSecretKeyInput.setText(certSecretKey); |
|
|
|
this.certSecretKeyInput.setText(certSecretKey); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
this.remoteEnvURL = RemoteEnvURL.createDefaultURL(); |
|
|
|
|
|
|
|
this.usernameInput.setText(StringUtils.EMPTY); |
|
|
|
|
|
|
|
this.passwordInput.setText(StringUtils.EMPTY); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
fillRemoteEnvURLField(); |
|
|
|
fillRemoteEnvURLField(); |
|
|
@ -488,8 +494,13 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> { |
|
|
|
WorkspaceConnection connection = remoteEnv.getConnection(); |
|
|
|
WorkspaceConnection connection = remoteEnv.getConnection(); |
|
|
|
DesignerEnvManager.getEnvManager().setCertificatePath(connection.getCertPath()); |
|
|
|
DesignerEnvManager.getEnvManager().setCertificatePath(connection.getCertPath()); |
|
|
|
DesignerEnvManager.getEnvManager().setCertificatePass(connection.getCertSecretKey()); |
|
|
|
DesignerEnvManager.getEnvManager().setCertificatePass(connection.getCertSecretKey()); |
|
|
|
|
|
|
|
try { |
|
|
|
return WorkContext.getConnector().testConnection(connection); |
|
|
|
return WorkContext.getConnector().testConnection(connection); |
|
|
|
|
|
|
|
} catch (AuthException e) { |
|
|
|
|
|
|
|
message.setText(Inter.getLocText("Fine-Designer_Basic_Remote_Connect_Auth_Failed")); |
|
|
|
|
|
|
|
uiLabel.setIcon(UIManager.getIcon("OptionPane.errorIcon")); |
|
|
|
|
|
|
|
return null; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|