summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--modules/enterprise/gui/installer-war/src/main/java/org/rhq/enterprise/installer/ConfigurationBean.java7
-rw-r--r--modules/enterprise/gui/installer-war/src/main/webapp/start.jsp5
2 files changed, 10 insertions, 2 deletions
diff --git a/modules/enterprise/gui/installer-war/src/main/java/org/rhq/enterprise/installer/ConfigurationBean.java b/modules/enterprise/gui/installer-war/src/main/java/org/rhq/enterprise/installer/ConfigurationBean.java
index 2af8f15..e06dbe8 100644
--- a/modules/enterprise/gui/installer-war/src/main/java/org/rhq/enterprise/installer/ConfigurationBean.java
+++ b/modules/enterprise/gui/installer-war/src/main/java/org/rhq/enterprise/installer/ConfigurationBean.java
@@ -895,6 +895,12 @@ public class ConfigurationBean {
return ((null != registeredServerNames) && !registeredServerNames.isEmpty());
}
+ public boolean isInstallationSettingsConfigurable() {
+ String selectedServer = getSelectedRegisteredServerName();
+ return selectedServer == null || selectedServer.isEmpty()
+ || selectedServer.equals(I18Nmsg.getMsg(InstallerI18NResourceKeys.NEW_SERVER_SELECT_ITEM));
+ }
+
public List<SelectItem> getRegisteredServerNames() {
List<SelectItem> result = new ArrayList<SelectItem>(0);
@@ -925,6 +931,7 @@ public class ConfigurationBean {
// should not call getServerConfiguration.setValue()
public void setSelectedRegisteredServerName(String selectedRegisteredServerName) {
this.selectedRegisteredServerName = selectedRegisteredServerName;
+ setHaServerName(selectedRegisteredServerName);
}
public String getHaServerName() {
diff --git a/modules/enterprise/gui/installer-war/src/main/webapp/start.jsp b/modules/enterprise/gui/installer-war/src/main/webapp/start.jsp
index ad0219e..7bbb55c 100644
--- a/modules/enterprise/gui/installer-war/src/main/webapp/start.jsp
+++ b/modules/enterprise/gui/installer-war/src/main/webapp/start.jsp
@@ -210,7 +210,8 @@
document.getElementById('propForm:haendpointport').value = '';
document.getElementById('propForm:haendpointsecureport').value = '';
if (document.getElementById('propForm:haaffinitygroup') != null) {
- document.getElementById('propForm:haaffinitygroup').value = ''; }
+ document.getElementById('propForm:haaffinitygroup').value = '';
+ }
submit(); }" >
<f:selectItems value="#{configurationBean.registeredServerNames}" />
</h:selectOneMenu>
@@ -233,7 +234,7 @@
<h:outputText value="#{bundle.propertyHighAvailabilityName}" />
</h:outputLink>
<h:inputText id="haservername" size="#{configurationBean.propHaServerName.itemDefinition.fieldSize}"
- value="#{configurationBean.haServerName}" >
+ value="#{configurationBean.haServerName}" readonly="#{not configurationBean.installationSettingsConfigurable}">
</h:inputText>
<h:outputText value="#{bundle.yesString}" rendered="#{configurationBean.propHaServerName.itemDefinition.requiresRestart}" />
<h:outputText value="#{bundle.noString}" rendered="#{!configurationBean.propHaServerName.itemDefinition.requiresRestart}" />