Browse Source

REPORT-10263 启动时连接远程服务器失败后弹窗选环境报错

final/10.0
yaoh.wu 6 years ago
parent
commit
5580aef0bb
  1. 16
      designer-base/src/main/java/com/fr/env/RemoteEnvPane.java
  2. 12
      designer-base/src/main/java/com/fr/env/RemoteWorkspaceURL.java

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

@ -395,8 +395,20 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> {
* 设置 app servlet 默认值
*/
private void setDefaultAppAndServlet() {
webAppNameInput.setText(FRContext.getCommonOperator().getAppName());
servletNameInput.setText(ServerConfig.getInstance().getServletName());
String appName;
String servletName;
try {
appName = FRContext.getCommonOperator().getAppName();
} catch (Exception ignored) {
appName = RemoteWorkspaceURL.DEFAULT_WEB_APP_NAME;
}
try {
servletName = ServerConfig.getInstance().getServletName();
} catch (Exception ignored) {
servletName = RemoteWorkspaceURL.DEFAULT_SERVLET_NAME;
}
webAppNameInput.setText(appName);
servletNameInput.setText(servletName);
}

12
designer-base/src/main/java/com/fr/env/RemoteWorkspaceURL.java vendored

@ -10,18 +10,18 @@ import java.util.Objects;
*/
public class RemoteWorkspaceURL implements FCloneable {
/**
* 默认 hostname
*/
private static final String DEFAULT_HOST_NAME = "${IP}";
/**
* 默认 web app name
*/
private static final String DEFAULT_WEB_APP_NAME = "webroot";
static final String DEFAULT_WEB_APP_NAME = "webroot";
/**
* 默认 servlet name
*/
private static final String DEFAULT_SERVLET_NAME = "decision";
static final String DEFAULT_SERVLET_NAME = "decision";
/**
* 默认 hostname
*/
private static final String DEFAULT_HOST_NAME = "${IP}";
/**
* 默认端口
*/

Loading…
Cancel
Save