| <!-- |
| |
| Copyright (c) 1997, 2018 Oracle and/or its affiliates. All rights reserved. |
| |
| This program and the accompanying materials are made available under the |
| terms of the Eclipse Public License v. 2.0, which is available at |
| http://www.eclipse.org/legal/epl-2.0. |
| |
| This Source Code may also be made available under the following Secondary |
| Licenses when the conditions for such availability set forth in the |
| Eclipse Public License v. 2.0 are satisfied: GNU General Public License, |
| version 2 with the GNU Classpath Exception, which is available at |
| https://www.gnu.org/software/classpath/license.html. |
| |
| SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 |
| |
| --> |
| |
| <!initPage |
| setResourceBundle(key="i18nc" bundle="org.glassfish.common.admingui.Strings") |
| setResourceBundle(key="help_common" bundle="org.glassfish.common.admingui.Helplinks"); |
| setAttribute(key="index" value="-1"); |
| /> |
| <!composition template="/templates/default.layout" guiTitle="$resource{i18nc.appClientLaunch.PageTitle}" > |
| <!define name="content"> |
| <event> |
| <!beforeCreate |
| getRequestValue(key="appName" value="#{pageSession.appName}"); |
| getRequestValue(key="moduleName" value="#{pageSession.moduleName}"); |
| urlencode(value="#{pageSession.appName}" encoding="UTF-8" result="#{pageSession.encodedAppName}"); |
| urlencode(value="#{pageSession.moduleName}" encoding="UTF-8" result="#{pageSession.encodedModuleName}"); |
| gf.createAttributeMap(keys={"appname", "modulename" }, values={"$pageSession{encodedAppName}" , "$pageSession{encodedModuleName}"}, map="#{requestScope.attrsMap}") |
| gf.restRequest(endpoint="#{sessionScope.REST_URL}/applications/application/#{pageSession.encodedAppName}/_get-relative-jws-uri", attrs="#{requestScope.attrsMap}" method="get", result="#{requestScope.result}"); |
| if ("!(#{requestScope.result.data}=#{null})") { |
| mapGet(Map="#{requestScope.result.data}" Key="properties" Value="#{requestScope.propMap}"); |
| } |
| if ("!(#{requestScope.propMap}=#{null})"){ |
| mapGet(Map="#{requestScope.propMap}" Key="relative-uri" Value="#{pageSession.relativeURI}"); |
| } |
| getTargetURLList(AppID="#{pageSession.appName}",contextRoot="#{pageSession.relativeURI}", URLList="#{requestScope.uList}"); |
| foreach(var="list" list="#{requestScope.uList}"){ |
| listAdd(list="#{pageSession.urlList}" value="#{requestScope.list.url}" result="#{pageSession.urlList}"); |
| } |
| setPageSessionAttribute(key="configOption" value="#{pageSession.urlList[0]}"); |
| setPageSessionAttribute(key="myOption" value="#{pageSession.configOption}"); |
| setAttribute(key="index" value="-1"); |
| /> |
| </event> |
| <sun:form id="form1"> |
| #include "/common/shared/alertMsg_1.inc" |
| <!-- Page Title --> |
| <sun:title id="propertyContentPage" title="$resource{i18nc.appClientLaunch.PageTitle}" helpText="$resource{i18nc.appClientLaunch.PageTitleHelp}"> |
| <!facet pageButtonsTop> |
| <sun:panelGroup id="topButtons"> |
| <sun:button id="launchButton" primary="#{true}" text="$resource{i18n.deployTable.launch}" |
| onClick="var pfix=document.getElementById('form1:option').value; |
| var args = document.getElementById('#{pageSession.argId}').value; |
| if(!(args==null || args=='')){ |
| args='?'+args; |
| } |
| var win=window.open(pfix+args,'appclient','width='+.50*screen.width+',height='+.50*screen.height+',top='+.1*screen.height+',left='+.1*screen.width+',toolbar=yes,status=yes,menubar=yes,scrollbars=yes,location=yes'); |
| win.focus(); |
| return false;" |
| /> |
| <sun:button id="backButton" immediate="#{true}" |
| text="$resource{i18n.button.Back}" primary="#{false}" > |
| <!command |
| gf.redirect(page="#{request.contextPath}/common/applications/applicationEdit.jsf?appName=#{pageSession.encodedAppName}"); |
| /> |
| </sun:button> |
| </sun:panelGroup> |
| </facet> |
| </sun:title> |
| "<br><br> |
| <sun:propertySheet id="propertySheet"> |
| <sun:propertySheetSection id="propertySheetSection"> |
| |
| <sun:property id="appProp" labelAlign="left" noWrap="#{true}" overlapLabel="#{false}" label="$resource{i18nc.appClientLaunch.application}"> |
| <sun:staticText id="app" text="#{pageSession.appName}" /> |
| </sun:property> |
| <sun:property id="module" labelAlign="left" noWrap="#{true}" overlapLabel="#{false}" label="$resource{i18nc.appClientLaunch.module}"> |
| <sun:staticText id="module" text="#{pageSession.moduleName}" /> |
| </sun:property> |
| |
| <sun:property id="configOptionProp" labelAlign="left" noWrap="#{true}" overlapLabel="#{true}" label=" "> |
| "<br><br> |
| <foreach key="oneUrl" list="#{pageSession.urlList}"> |
| <event> |
| <!beforeEncode |
| inc(number="${index}" value="#{requestScope.index}"); |
| /> |
| </event> |
| <sun:radioButton id="A${index}" name="configOptionGrp" label="#{pageSession.urlList[requestScope.index]}" selected="#{configOption}" selectedValue="#{pageSession.urlList[requestScope.index]}" |
| onClick="document.getElementById('form1:option').value='#{pageSession.urlList[requestScope.index]}'; " |
| /> |
| "<br><br> |
| </foreach> |
| </sun:property> |
| |
| <sun:property id="argsProp" labelAlign="left" noWrap="#{true}" overlapLabel="#{false}" label="$resource{i18nc.appClientLaunch.argLabel}"> |
| <sun:textField id="args" text="#{pageSession.args}" columns="$int{50}" maxLength="#{sessionScope.fieldLengths['maxLength.appClientLaunch.args']}" > |
| <!afterCreate |
| getClientId(component="$this{component}" clientId="#{pageSession.argId}"); |
| /> |
| </sun:textField> |
| <sun:helpInline id="argsHelp" type="field" text="$resource{i18nc.appClientLaunch.argHelp}"/> |
| </sun:property> |
| </sun:propertySheetSection> |
| </sun:propertySheet> |
| <sun:hidden id="option" value="#{myOption}" /> |
| <sun:hidden id="helpKey" value="$resource{help_common.appclientLaunch}" /> |
| |
| </sun:form> |
| |
| </define> |
| </composition> |
| |