From 3914f587677adeb40395611b48d28c64ac589681 Mon Sep 17 00:00:00 2001 From: Mark Rogers Date: Thu, 4 Jun 2009 20:57:18 +0000 Subject: [PATCH] Merge WCM_WDR_MER TO HEAD MOB-399 Implementation of Deploymemnt Engine MOB-669 MOB-630 Revisions 14181 - 14539 merged,, git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@14543 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261 --- config/alfresco/messages/webclient.properties | 14 +++++++------- .../ui/wcm/component/UIDeploymentServers.java | 13 ++++++++++++- source/web/scripts/ajax/deployment.js | 18 ++++++++++++------ 3 files changed, 31 insertions(+), 14 deletions(-) diff --git a/config/alfresco/messages/webclient.properties b/config/alfresco/messages/webclient.properties index 3868c829a8..9fa486beef 100644 --- a/config/alfresco/messages/webclient.properties +++ b/config/alfresco/messages/webclient.properties @@ -1102,9 +1102,9 @@ form_template_templates=Configure Templates form_template_templates_desc=Setup the Templates you want to use for the Web Form {0} in Web Project {1}. form_template_workflow=Configure Workflow form_template_workflow_desc=Configure the workflow defaults for this Web Project -create_website_step3_title=Step Three - Configure Deployment Servers -create_website_step3_desc=Configure deployment servers for the web project. -website_deployment=Configure Deployment Servers +create_website_step3_title=Step Three - Configure Deployment Receivers +create_website_step3_desc=Configure deployment receivers for the web project. +website_deployment=Configure Deployment Receivers create_website_step4_title=Step Four - Configure Web Content Forms create_website_step4_desc=Select and configure web forms for generating site content. website_select_form=Select Web Forms @@ -1335,8 +1335,8 @@ deploy_status_in_progress=IN PROGRESS deploy_status_live=LIVE deploy_status_failed=FAILED deploy_status_partial=PARTIAL FAILURE -deploy_add_alf_receiver=Add Alfresco Server Receiver (ASR) -deploy_add_file_receiver=Add File System Receiver (FSR) +deploy_add_alf_receiver=Add ASR (Deprecated) +deploy_add_file_receiver=Add Deployment Receiver deploy_server_type_live=Live Server deploy_server_type_test=Test Server deploy_server=Server @@ -1367,9 +1367,9 @@ edit_deploy_server=Edit Deployment Server Details delete_deploy_server=Delete Deployment Server no_deploy_servers=No deployment servers have been configured. add_alf_deploy_server_info=Provide details of the Alfresco Server Receiver to add -add_file_deploy_server_info=Provide details of the File System Receiver to add +add_file_deploy_server_info=Provide details of the Deployment Receiver to add edit_alf_deploy_server_info=Edit details of the Alfresco Server Receiver -edit_file_deploy_server_info=Edit details of the File System Receiver +edit_file_deploy_server_info=Edit details of the Deployment Receiver reason=Reason snapshot=Snapshot current_working_version=current working version diff --git a/source/java/org/alfresco/web/ui/wcm/component/UIDeploymentServers.java b/source/java/org/alfresco/web/ui/wcm/component/UIDeploymentServers.java index 51df3a5101..d2b39ef341 100644 --- a/source/java/org/alfresco/web/ui/wcm/component/UIDeploymentServers.java +++ b/source/java/org/alfresco/web/ui/wcm/component/UIDeploymentServers.java @@ -732,11 +732,13 @@ public class UIDeploymentServers extends UIInput UIComponent host = context.getApplication().createComponent( UIInput.COMPONENT_TYPE); FacesHelper.setupComponentId(context, host, "deployServerHost"); + host.getAttributes().put("styleClass", "inputField"); host.getAttributes().put("onkeyup", "javascript:Alfresco.checkDeployConfigButtonState();"); host.getAttributes().put("onchange", "javascript:Alfresco.checkDeployConfigButtonState();"); + ValueBinding vbHost = context.getApplication().createValueBinding( "#{WizardManager.bean.editedDeployServerProperties." + DeploymentServerConfig.PROP_HOST + "}"); @@ -757,13 +759,22 @@ public class UIDeploymentServers extends UIInput UIInput.COMPONENT_TYPE); FacesHelper.setupComponentId(context, port, "deployServerPort"); port.getAttributes().put("styleClass", "inputField"); + port.getAttributes().put("onkeyup", + "javascript:Alfresco.checkDeployConfigButtonState();"); + port.getAttributes().put("onchange", + "javascript:Alfresco.checkDeployConfigButtonState();"); + ValueBinding vbPort = context.getApplication().createValueBinding( "#{WizardManager.bean.editedDeployServerProperties." + DeploymentServerConfig.PROP_PORT + "}"); port.setValueBinding("value", vbPort); this.getChildren().add(port); Utils.encodeRecursive(context, port); - out.write(""); + out.write(""); // create the server url field out.write(""); diff --git a/source/web/scripts/ajax/deployment.js b/source/web/scripts/ajax/deployment.js index bf432ce92a..d8091ffe4a 100644 --- a/source/web/scripts/ajax/deployment.js +++ b/source/web/scripts/ajax/deployment.js @@ -117,18 +117,24 @@ Alfresco.checkDeployConfigPage = function() Alfresco.checkDeployConfigButtonState = function() { var host = document.getElementById('wizard:wizard-body:deployServerHost'); + var port = document.getElementById('wizard:wizard-body:deployServerPort'); var button = document.getElementById('wizard:wizard-body:deployActionButton'); + console.log(button); + if (button != null) { - if (host != null && host.value.length == 0) + var buttonState = false; + + if (port != null && port.value.length == 0) + { + buttonState = true; + } + if (host != null && host.value.length == 0) { - button.disabled = true; - } - else - { - button.disabled = false; + buttonState = true; } + button.disabled = buttonState; } }