wise SVN: r568 - in webgui/trunk/src/main: java/org/jboss/wise/gui/treeElement and 1 other directories.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-02 10:31:07 -0400 (Tue, 02 Jul 2013)
New Revision: 568
Added:
webgui/trunk/src/main/webapp/step1.xhtml
webgui/trunk/src/main/webapp/step2.xhtml
webgui/trunk/src/main/webapp/step3.xhtml
webgui/trunk/src/main/webapp/step4.xhtml
Modified:
webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java
webgui/trunk/src/main/java/org/jboss/wise/gui/ClientHelper.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ComplexWiseTreeElement.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/GroupWiseTreeElement.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ParameterizedWiseTreeElement.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/WiseTreeElement.java
webgui/trunk/src/main/webapp/index.xhtml
Log:
[WISE-203] Move to wizard style panel + auto-expand trees
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java 2013-07-02 14:30:01 UTC (rev 567)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java 2013-07-02 14:31:07 UTC (rev 568)
@@ -65,6 +65,7 @@
private String invocationPwd;
private List<Service> services;
private String currentOperation;
+ private String currentOperationFullName;
private TreeNodeImpl inputTree;
private TreeNodeImpl outputTree;
private String error;
@@ -105,6 +106,7 @@
if (client != null) {
try {
services = ClientHelper.convertServicesToGui(client.processServices());
+ currentOperation = ClientHelper.getFirstGuiOperation(services);
} catch (Exception e) {
error = "Could not parse WSDL from specified URL. Please check logs for further information.";
logException(e);
@@ -113,7 +115,6 @@
}
public void parseOperationParameters() {
- if (currentOperation == null) return;
outputTree = null;
responseMessage = null;
error = null;
@@ -196,6 +197,26 @@
el.setNotNil(true);
}
+ public void changePanel(ItemChangeEvent event) {
+ String oldName = event.getOldItemName();
+ String newName = event.getNewItemName();
+ if (oldName != null && newName != null) {
+ if (oldName.endsWith("step1")) {
+ if (newName.endsWith("step2")) {
+ readWsdl();
+ }
+ } else if (oldName.endsWith("step2")) {
+ if (newName.endsWith("step3")) {
+ parseOperationParameters();
+ }
+ } else if (oldName.endsWith("step3")) {
+ if (newName.endsWith("step4")) {
+ performInvocation();
+ }
+ }
+ }
+ }
+
public void updateCurrentOperation(ItemChangeEvent event) {
String ev = event.getNewItemName();
//skip empty/null operation values as those comes from expansion/collapse of the menu panel
@@ -216,6 +237,7 @@
}
services = null;
currentOperation = null;
+ currentOperationFullName = null;
inputTree = null;
outputTree = null;
if (inTree != null) {
@@ -306,9 +328,14 @@
public String getCurrentOperation() {
return currentOperation;
}
+
+ public String getCurrentOperationFullName() {
+ return currentOperationFullName;
+ }
public void setCurrentOperation(String currentOperation) {
this.currentOperation = currentOperation;
+ this.currentOperationFullName = ClientHelper.getOperationFullName(currentOperation, services);
}
public UITree getInTree() {
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/ClientHelper.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/ClientHelper.java 2013-07-02 14:30:01 UTC (rev 567)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/ClientHelper.java 2013-07-02 14:31:07 UTC (rev 568)
@@ -136,6 +136,54 @@
return services;
}
+ public static String getFirstGuiOperation(List<Service> services) {
+ if (services == null || services.isEmpty()) {
+ return null;
+ }
+ Service s = services.iterator().next();
+ List<Port> ports = s.getPorts();
+ if (ports == null || ports.isEmpty()) {
+ return null;
+ }
+ Port p = ports.iterator().next();
+ List<Operation> operations = p.getOperations();
+ if (operations == null || operations.isEmpty()) {
+ return null;
+ }
+ Operation o = operations.iterator().next();
+ StringBuilder sb = new StringBuilder();
+ sb.append(s.getName());
+ sb.append(";");
+ sb.append(p.getName());
+ sb.append(";");
+ sb.append(o.getName());
+ return sb.toString();
+ }
+
+ public static String getOperationFullName(String currentGuiOperation, List<Service> services) {
+ if (currentGuiOperation == null) {
+ return null;
+ }
+ StringTokenizer st = new StringTokenizer(currentGuiOperation, ";");
+ String serviceName = st.nextToken();
+ String portName = st.nextToken();
+ String operationName = st.nextToken();
+ for (Service s : services) {
+ if (serviceName.equals(s.getName())) {
+ for (Port p : s.getPorts()) {
+ if (portName.equals(p.getName())) {
+ for (Operation o : p.getOperations()) {
+ if (operationName.equals(o.getName())) {
+ return o.getFullName();
+ }
+ }
+ }
+ }
+ }
+ }
+ return null;
+ }
+
public static Map<String, Object> processGUIParameters(TreeNodeImpl inputTree) {
Map<String, Object> params = new HashMap<String, Object>();
for (Iterator<Object> it = inputTree.getChildrenKeysIterator(); it.hasNext();) {
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ComplexWiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ComplexWiseTreeElement.java 2013-07-02 14:30:01 UTC (rev 567)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ComplexWiseTreeElement.java 2013-07-02 14:31:07 UTC (rev 568)
@@ -43,15 +43,14 @@
private ComplexWiseTreeElement() {
this.kind = COMPLEX;
this.id = IDGenerator.nextVal();
+ this.expanded = true;
}
public ComplexWiseTreeElement(Type classType, String name) {
- this.id = IDGenerator.nextVal();
- this.kind = COMPLEX;
+ this();
this.classType = classType;
this.nil = false;
this.name = name;
-
}
public WiseTreeElement clone() {
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/GroupWiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/GroupWiseTreeElement.java 2013-07-02 14:30:01 UTC (rev 567)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/GroupWiseTreeElement.java 2013-07-02 14:31:07 UTC (rev 568)
@@ -37,11 +37,11 @@
private GroupWiseTreeElement() {
this.kind = GROUP;
this.id = IDGenerator.nextVal();
+ this.expanded = true;
}
public GroupWiseTreeElement(Type classType, String name, WiseTreeElement prototype) {
- this.kind = GROUP;
- this.id = IDGenerator.nextVal();
+ this();
this.classType = classType;
this.nil = false;
this.name = name;
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ParameterizedWiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ParameterizedWiseTreeElement.java 2013-07-02 14:30:01 UTC (rev 567)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ParameterizedWiseTreeElement.java 2013-07-02 14:31:07 UTC (rev 568)
@@ -49,11 +49,11 @@
public ParameterizedWiseTreeElement() {
this.kind = PARAMETERIZED;
this.id = IDGenerator.nextVal();
+ this.expanded = true;
}
public ParameterizedWiseTreeElement(ParameterizedType classType, Class<?> parameterizedClass, String name, WSDynamicClient client, Class<?> scope, String namespace) {
- this.kind = PARAMETERIZED;
- this.id = IDGenerator.nextVal();
+ this();
this.classType = classType;
this.nil = false;
this.name = name;
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/WiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/WiseTreeElement.java 2013-07-02 14:30:01 UTC (rev 567)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/WiseTreeElement.java 2013-07-02 14:31:07 UTC (rev 568)
@@ -48,6 +48,7 @@
protected Object id;
protected String name;
protected String kind; // simple, complex, array, date, etc
+ protected boolean expanded = false;
protected boolean nil; //whether this elements has the attribute xsi:nil set to "true"
protected boolean nillable = true; //for primitives and explicitly not nillable elements
@@ -133,6 +134,14 @@
this.setNil(!notNil);
}
+ public boolean isExpanded() {
+ return expanded;
+ }
+
+ public void setExpanded(boolean expanded) {
+ this.expanded = expanded;
+ }
+
public String getType() {
if (this.classType instanceof ParameterizedType) {
return ((Class<?>) ((ParameterizedType) this.classType).getRawType()).getSimpleName();
Modified: webgui/trunk/src/main/webapp/index.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/index.xhtml 2013-07-02 14:30:01 UTC (rev 567)
+++ webgui/trunk/src/main/webapp/index.xhtml 2013-07-02 14:31:07 UTC (rev 568)
@@ -12,292 +12,40 @@
<ui:composition template="/templates/template.xhtml">
<ui:define name="title">JBoss Wise GUI</ui:define>
-
<ui:define name="body">
<fieldset style="width:640px">
<div>
- <img src="images/wise-banner-640px.png" border="0" />
+ <a href="." style="border:0px">
+ <img src="images/wise-banner-640px.png" border="0" />
+ </a>
<br />
</div>
- <rich:panel header="WSDL selection">
- <h:form id="wsdlSelection">
- <h:outputLabel value="URL:" for="wsdlUrlInput"/>
- <h:inputText id="wsdlUrlInput" value="#{clientConversationBean.wsdlUrl}" onclick="document.getElementById('wsdlSelection:okButton').disabled=false" />
- <h:outputLabel value="User:" for="wsdlUser"/>
- <h:inputText id="wsdlUser" value="#{clientConversationBean.wsdlUser}" onclick="document.getElementById('wsdlSelection:okButton').disabled=false" />
- <h:outputLabel value="Password:" for="wsdlPwd"/>
- <h:inputSecret id="wsdlPwd" value="#{clientConversationBean.wsdlPwd}" onclick="document.getElementById('wsdlSelection:okButton').disabled=false" />
- <a4j:commandButton id="okButton" value="OK" render="epSelection" action="#{clientConversationBean.readWsdl}" onclick="this.disabled=true" status="wsdlParseStatus" />
- </h:form>
- </rich:panel>
- <br />
- <a4j:outputPanel id="opSelectionPanel">
- <rich:panel header="Operation selection">
- <h:form id="epSelection">
- <rich:panelMenu itemMode="ajax" groupMode="ajax" groupExpandedLeftIcon="triangleUp" rendered="#{not empty clientConversationBean.services}"
- groupCollapsedLeftIcon="triangleDown" topGroupExpandedRightIcon="chevronUp"
- topGroupCollapsedRightIcon="chevronDown" itemLeftIcon="disc" itemChangeListener="#{clientConversationBean.updateCurrentOperation}">
- <c:forEach var="service" items="#{clientConversationBean.services}" >
- <rich:panelMenuGroup label="#{service.name}" expanded="true">
- <c:forEach var="port" items="#{service.ports}" >
- <rich:panelMenuGroup label="#{port.name}" expanded="true">
- <c:forEach var="operation" items="#{port.operations}" >
- <rich:panelMenuItem label="#{operation.fullName}" name="#{service.name};#{port.name};#{operation.name}"
- action="#{clientConversationBean.parseOperationParameters}" render="parInputPanel parInput"/>
- </c:forEach>
- </rich:panelMenuGroup>
- </c:forEach>
- </rich:panelMenuGroup>
- </c:forEach>
- </rich:panelMenu>
- </h:form>
- </rich:panel>
- <br />
- <a4j:outputPanel id="parInputPanel" ajaxRendered="true">
- <rich:panel header="Request" rendered="#{not empty clientConversationBean.inputTree}">
- <h:form id="parInput">
- <rich:tabPanel switchType="ajax" activeItem="#{clientConversationBean.requestActiveTab}">
- <rich:tab header="Parameters ">
- <rich:tree id="richTree" var="node" value="#{clientConversationBean.inputTree}" nodeType="#{node.kind}"
- switchType="ajax" binding="#{clientConversationBean.inTree}">
- <rich:treeNode type="simple">
- <h:outputText value="#{node.type} : #{node.name} " />
- <h:selectBooleanCheckbox id="foo-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
- <f:ajax />
- </h:selectBooleanCheckbox>
- <h:inputText value="#{node.value}" id="foo" label="" rendered="#{node.type!='boolean' and node.type!='Boolean'}" columns="10" >
- <f:ajax event="valueChange" render="foo-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
- </h:inputText>
- <h:selectOneMenu value="#{node.value}" rendered="#{node.type=='boolean' or node.type=='Boolean'}">
- <f:selectItem itemValue="true" itemLabel="true" />
- <f:selectItem itemValue="false" itemLabel="false" />
- </h:selectOneMenu>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- <rich:treeNode type="group">
- <h:outputText value="[#{node.type}]" styleClass="tipoCampo" />
- <h:selectBooleanCheckbox value="#{node.notNil}" disabled="true" />
- <h:outputText value=" " />
- <a4j:commandLink name="Add" action="#{clientConversationBean.addChild(node)}" reRender="richTree">
- Add
- </a4j:commandLink>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- <rich:treeNode type="lazy">
- <h:outputText value="#{node.type} ..." />
- <h:outputText value=" " />
- <a4j:commandLink name="Load" action="#{clientConversationBean.lazyLoadChild(node)}" reRender="richTree" rendered="#{not node.resolved}">
- Load
- </a4j:commandLink>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- <rich:treeNode type="complex">
- <h:outputText value="#{node.type} : #{node.name} " />
- <h:selectBooleanCheckbox value="#{node.notNil}" disabled="#{node.notNillable}" >
- <f:ajax />
- </h:selectBooleanCheckbox>
- <h:outputText value=" " />
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- <rich:treeNode type="Parameterized">
- <h:outputText value="{#{node.namespace}} " />
- <h:selectBooleanCheckbox value="#{node.notNil}" disabled="true" />
- </rich:treeNode>
- <rich:treeNode type="XMLGregorianCalendar">
- <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
- <h:selectBooleanCheckbox id="foo2-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
- <f:ajax />
- </h:selectBooleanCheckbox>
- <rich:calendar id="foo2" value="#{node.valueDate}" popup="true" showInput="true" enableManualInput="false" >
- <f:ajax event="change" render="foo2-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
- </rich:calendar>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- <rich:treeNode type="Duration">
- <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
- <h:selectBooleanCheckbox id="foo3-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
- <f:ajax />
- </h:selectBooleanCheckbox>
- <h:inputText id="foo3" value="#{node.value}">
- <f:ajax event="valueChange" render="foo3-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
- </h:inputText>
- <h:outputText value="(MilliSeconds)" target="_blank" />
- <h:outputText value=" " />
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- <rich:treeNode type="qname">
- <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
- <h:selectBooleanCheckbox id="foo4-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
- <f:ajax />
- </h:selectBooleanCheckbox>
- <h:inputText id="foo4" value="#{node.nameSpace}">
- <f:ajax event="valueChange" render="foo4-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
- </h:inputText>
- <h:outputText value=" : " />
- <h:inputText value="#{node.localPart}" />
- <h:outputText value=" " />
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- <rich:treeNode type="Enumeration">
- <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
- <h:selectBooleanCheckbox id="foo5-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
- <f:ajax />
- </h:selectBooleanCheckbox>
- <h:selectOneMenu id="foo5" value="#{node.value}" onfocus="document.getElementById(this.id + '-chk').checked=true">
- <f:selectItems value="#{node.validValue}" />
- </h:selectOneMenu>
- <h:outputText value=" " />
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- <rich:treeNode type="byteArray">
- <h:outputText value="#{node.type} : #{node.name} " />
- <h:selectBooleanCheckbox id="foo6-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
- <f:ajax />
- </h:selectBooleanCheckbox>
- <h:inputText value="#{node.value}" id="foo6" >
- <f:ajax event="valueChange" render="foo6-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
- </h:inputText>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
- </rich:treeNode>
- </rich:tree>
- </rich:tab>
- <rich:tab header="Options">
- <h:outputLabel value="Override target address:" for="invUrlInput"/>
- <h:inputText id="invUrlInput" value="#{clientConversationBean.invocationUrl}" /><br/><br/>
- <h:outputLabel value="User:" for="invUser"/>
- <h:inputText id="invUser" value="#{clientConversationBean.invocationUser}" />
- <h:outputLabel value="Password:" for="invPwd"/>
- <h:inputSecret id="invPwd" value="#{clientConversationBean.invocationPwd}" redisplay="true" />
- </rich:tab>
- </rich:tabPanel>
-
- <a4j:commandButton value="Perform invocation" render="opSelectionPanel" rerender="opSelectionPanel"
- action="#{clientConversationBean.performInvocation}" status="perfInvStatus" />
- <h:outputText value=" " />
-
- <a4j:commandButton value="Preview message" render="popupPreview" action="#{clientConversationBean.generateRequestPreview}"
- id="previewButton" oncomplete="#{rich:component('popupPreview')}.show();">
- </a4j:commandButton>
-
- <rich:popupPanel id="popupPreview" modal="true" resizeable="true" onmaskclick="#{rich:component('popupPreview')}.hide()" minWidth="550" minHeight="450">
- <f:facet name="header">
- <h:outputText value="SOAP request message preview" />
- </f:facet>
- <f:facet name="controls">
- <h:outputLink value="#" onclick="#{rich:component('popupPreview')}.hide(); return false;">X</h:outputLink>
- </f:facet>
- <p>Below is a preview of the SOAP message that will be generated upon invocation. The actual message going on the wire might be different
- depending on the selected service policy (security, addressing, reliable-messaging, etc.), if any.</p>
- <div align="center"><h:inputTextarea value="#{clientConversationBean.requestPreview}" cols="80" rows="20" readonly="true" styleClass="preformatted"/></div>
- </rich:popupPanel>
-
+ <rich:panel styleClass="wizard">
+ <h:form>
+ <rich:togglePanel switchType="ajax" itemChangeListener="#{clientConversationBean.changePanel}" status="waitStatus">
+ <rich:togglePanelItem id="step1">
+ <ui:include src="step1.xhtml" />
+ </rich:togglePanelItem>
+ <rich:togglePanelItem id="step2">
+ <ui:include src="step2.xhtml" />
+ </rich:togglePanelItem>
+ <rich:togglePanelItem id="step3">
+ <ui:include src="step3.xhtml" />
+ </rich:togglePanelItem>
+ <rich:togglePanelItem id="step4">
+ <ui:include src="step4.xhtml" />
+ </rich:togglePanelItem>
+ </rich:togglePanel>
</h:form>
</rich:panel>
- <br />
- <a4j:outputPanel id="resultPanel" ajaxRendered="true">
-
- <rich:panel header="Response" rendered="#{clientConversationBean.responseAvailable}">
- <h:form id="resForm">
- <rich:tree id="richResTree" var="node" value="#{clientConversationBean.outputTree}" nodeType="#{node.kind}" switchType="ajax">
- <rich:treeNode type="simple">
- <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
- rendered="#{node.notNil}" />
- <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
- </rich:treeNode>
- <rich:treeNode type="qname">
- <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
- rendered="#{node.notNil}" />
- <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
- </rich:treeNode>
- <rich:treeNode type="Duration">
- <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
- rendered="#{node.notNil}" />
- <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
- </rich:treeNode>
- <rich:treeNode type="XMLGregorianCalendar">
- <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
- rendered="#{node.notNil}" />
- <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
- </rich:treeNode>
- <rich:treeNode type="Enumeration">
- <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
- rendered="#{node.notNil}" />
- <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
- </rich:treeNode>
- <rich:treeNode type="Parameterized">
- <h:outputText value="{#{node.namespace}}" />
- </rich:treeNode>
- <rich:treeNode type="group">
- <h:outputText value="#{node.type}[#{node.size}]" />
- </rich:treeNode>
- <rich:treeNode type="complex">
- <h:outputText value="#{node.type} : #{node.name}" />
- </rich:treeNode>
- <rich:treeNode type="byteArray">
- <h:outputText value="#{node.type} : #{node.name} = #{node.value}"
- rendered="#{node.notNil}" />
- <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
- </rich:treeNode>
- </rich:tree>
- <br/>
- <a4j:commandButton value="View message" render="popupView"
- id="viewMessageButton" oncomplete="#{rich:component('popupView')}.show();">
- </a4j:commandButton>
- <rich:popupPanel id="popupView" modal="true" resizeable="true" onmaskclick="#{rich:component('popupView')}.hide()" minWidth="550" minHeight="450">
- <f:facet name="header">
- <h:outputText value="SOAP response message" />
- </f:facet>
- <f:facet name="controls">
- <h:outputLink value="#" onclick="#{rich:component('popupView')}.hide(); return false;">X</h:outputLink>
- </f:facet>
- <p>Below is the captured SOAP response message:</p>
- <div align="center"><h:inputTextarea value="#{clientConversationBean.responseMessage}" cols="80" rows="20" readonly="true" styleClass="preformatted"/></div>
- </rich:popupPanel>
- </h:form>
- </rich:panel>
- <rich:panel header="Error" rendered="#{not empty clientConversationBean.error}">
- <h:outputText value="#{clientConversationBean.error}" />
- </rich:panel>
- </a4j:outputPanel>
-
- </a4j:outputPanel>
-
- </a4j:outputPanel>
-
-
-
- <rich:popupPanel id="mpPerfInv" style="text-align:center" autosized="true" modal="true">
- <h:outputText value="Invoking target endpoint and parsing results, please wait..." />
+ <rich:popupPanel id="mpWait" style="text-align:center" autosized="true" modal="true">
+ <h:outputText value="Please wait..." />
</rich:popupPanel>
- <rich:popupPanel id="mpParseWsdl" style="text-align:center" autosized="true" modal="true">
- <h:outputText value="Fetching and parsing wsdl, please wait..." />
- </rich:popupPanel>
- <a4j:status name="perfInvStatus" onstart="#{rich:component('mpPerfInv')}.show()" onstop="#{rich:component('mpPerfInv')}.hide()" />
- <a4j:status name="wsdlParseStatus" onstart="#{rich:component('mpParseWsdl')}.show()" onstop="#{rich:component('mpParseWsdl')}.hide()" />
+ <a4j:status name="waitStatus" onstart="#{rich:component('mpWait')}.show()" onstop="#{rich:component('mpWait')}.hide()" />
-
</fieldset>
-
</ui:define>
</ui:composition>
</body>
Added: webgui/trunk/src/main/webapp/step1.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step1.xhtml (rev 0)
+++ webgui/trunk/src/main/webapp/step1.xhtml 2013-07-02 14:31:07 UTC (rev 568)
@@ -0,0 +1,27 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:a4j="http://richfaces.org/a4j"
+ xmlns:c="http://java.sun.com/jsp/jstl/core"
+ xmlns:rich="http://richfaces.org/rich">
+
+ <rich:panel header="WSDL selection">
+ <h:panelGrid columns="2">
+ <h:outputLabel value="URL:" for="wsdlUrlInput"/>
+ <h:inputText id="wsdlUrlInput" value="#{clientConversationBean.wsdlUrl}"/>
+ <h:outputLabel value="User:" for="wsdlUser"/>
+ <h:inputText id="wsdlUser" value="#{clientConversationBean.wsdlUser}"/>
+ <h:outputLabel value="Password:" for="wsdlPwd"/>
+ <h:inputSecret id="wsdlPwd" value="#{clientConversationBean.wsdlPwd}"/>
+ </h:panelGrid>
+ </rich:panel>
+ <div class="navPanel" style="width: 100%;">
+ <a4j:commandButton value="Read WSDL >>" style="float:right">
+ <rich:toggleControl targetItem="@next" event="click" />
+ </a4j:commandButton>
+ </div>
+
+</ui:composition>
Added: webgui/trunk/src/main/webapp/step2.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step2.xhtml (rev 0)
+++ webgui/trunk/src/main/webapp/step2.xhtml 2013-07-02 14:31:07 UTC (rev 568)
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:a4j="http://richfaces.org/a4j"
+ xmlns:c="http://java.sun.com/jsp/jstl/core"
+ xmlns:rich="http://richfaces.org/rich">
+
+ <rich:panel header="Operation selection">
+ <rich:panelMenu itemMode="ajax" groupMode="ajax" groupExpandedLeftIcon="triangleUp" rendered="#{not empty clientConversationBean.services}"
+ groupCollapsedLeftIcon="triangleDown" topGroupExpandedRightIcon="chevronUp" activeItem="#{clientConversationBean.currentOperation}"
+ topGroupCollapsedRightIcon="chevronDown" itemLeftIcon="disc" itemChangeListener="#{clientConversationBean.updateCurrentOperation}">
+ <c:forEach var="service" items="#{clientConversationBean.services}" >
+ <rich:panelMenuGroup label="#{service.name}" expanded="true">
+ <c:forEach var="port" items="#{service.ports}" >
+ <rich:panelMenuGroup label="#{port.name}" expanded="true">
+ <c:forEach var="operation" items="#{port.operations}" >
+ <rich:panelMenuItem label="#{operation.fullName}" name="#{service.name};#{port.name};#{operation.name}"/>
+ </c:forEach>
+ </rich:panelMenuGroup>
+ </c:forEach>
+ </rich:panelMenuGroup>
+ </c:forEach>
+ </rich:panelMenu>
+ </rich:panel>
+ <div class="navPanel" style="width: 100%;">
+ <a4j:commandButton value="<< Back" style="float:left">
+ <rich:toggleControl targetItem="@prev" event="click" />
+ </a4j:commandButton>
+ <a4j:commandButton value="Select >>" style="float:right" rendered="#{not empty clientConversationBean.currentOperation}">
+ <rich:toggleControl targetItem="@next" event="click" />
+ </a4j:commandButton>
+ </div>
+
+</ui:composition>
Added: webgui/trunk/src/main/webapp/step3.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step3.xhtml (rev 0)
+++ webgui/trunk/src/main/webapp/step3.xhtml 2013-07-02 14:31:07 UTC (rev 568)
@@ -0,0 +1,175 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:a4j="http://richfaces.org/a4j"
+ xmlns:c="http://java.sun.com/jsp/jstl/core"
+ xmlns:rich="http://richfaces.org/rich">
+
+ <rich:panel header="Request">
+ <a4j:outputPanel id="parInputPanel" ajaxRendered="true"> <!-- The tree must live within a ajaxRendered outputPanel in order for properly refreshing! -->
+ <div>
+ <i>#{clientConversationBean.currentOperationFullName}</i>
+ </div>
+ <rich:tree id="richTree" var="node" value="#{clientConversationBean.inputTree}" nodeType="#{node.kind}"
+ switchType="ajax" binding="#{clientConversationBean.inTree}">
+ <rich:treeNode type="simple">
+ <h:outputText value="#{node.type} : #{node.name} " />
+ <h:selectBooleanCheckbox id="foo-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <f:ajax />
+ </h:selectBooleanCheckbox>
+ <h:inputText value="#{node.value}" id="foo" label="" rendered="#{node.type!='boolean' and node.type!='Boolean'}" columns="10" >
+ <f:ajax event="valueChange" render="foo-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ </h:inputText>
+ <h:selectOneMenu value="#{node.value}" rendered="#{node.type=='boolean' or node.type=='Boolean'}">
+ <f:selectItem itemValue="true" itemLabel="true" />
+ <f:selectItem itemValue="false" itemLabel="false" />
+ </h:selectOneMenu>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ <rich:treeNode type="group" expanded="#{node.expanded}">
+ <h:outputText value="[#{node.type}]" styleClass="tipoCampo" />
+ <h:selectBooleanCheckbox value="#{node.notNil}" disabled="true" />
+ <h:outputText value=" " />
+ <a4j:commandLink name="Add" action="#{clientConversationBean.addChild(node)}" reRender="richTree">
+ Add
+ </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ <rich:treeNode type="lazy">
+ <h:outputText value="#{node.type} ..." />
+ <h:outputText value=" " />
+ <a4j:commandLink name="Load" action="#{clientConversationBean.lazyLoadChild(node)}" reRender="richTree" rendered="#{not node.resolved}">
+ Load
+ </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ <rich:treeNode type="complex" expanded="#{node.expanded}">
+ <h:outputText value="#{node.type} : #{node.name} " />
+ <h:selectBooleanCheckbox value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <f:ajax />
+ </h:selectBooleanCheckbox>
+ <h:outputText value=" " />
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ <rich:treeNode type="Parameterized" expanded="#{node.expanded}">
+ <h:outputText value="{#{node.namespace}} " />
+ <h:selectBooleanCheckbox value="#{node.notNil}" disabled="true" />
+ </rich:treeNode>
+ <rich:treeNode type="XMLGregorianCalendar">
+ <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
+ <h:selectBooleanCheckbox id="foo2-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <f:ajax />
+ </h:selectBooleanCheckbox>
+ <rich:calendar id="foo2" value="#{node.valueDate}" popup="true" showInput="true" enableManualInput="false" >
+ <f:ajax event="change" render="foo2-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ </rich:calendar>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ <rich:treeNode type="Duration">
+ <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
+ <h:selectBooleanCheckbox id="foo3-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <f:ajax />
+ </h:selectBooleanCheckbox>
+ <h:inputText id="foo3" value="#{node.value}">
+ <f:ajax event="valueChange" render="foo3-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ </h:inputText>
+ <h:outputText value="(MilliSeconds)" target="_blank" />
+ <h:outputText value=" " />
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ <rich:treeNode type="qname">
+ <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
+ <h:selectBooleanCheckbox id="foo4-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <f:ajax />
+ </h:selectBooleanCheckbox>
+ <h:inputText id="foo4" value="#{node.nameSpace}">
+ <f:ajax event="valueChange" render="foo4-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ </h:inputText>
+ <h:outputText value=" : " />
+ <h:inputText value="#{node.localPart}" />
+ <h:outputText value=" " />
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ <rich:treeNode type="Enumeration">
+ <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
+ <h:selectBooleanCheckbox id="foo5-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <f:ajax />
+ </h:selectBooleanCheckbox>
+ <h:selectOneMenu id="foo5" value="#{node.value}" onfocus="document.getElementById(this.id + '-chk').checked=true">
+ <f:selectItems value="#{node.validValue}" />
+ </h:selectOneMenu>
+ <h:outputText value=" " />
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ <rich:treeNode type="byteArray">
+ <h:outputText value="#{node.type} : #{node.name} " />
+ <h:selectBooleanCheckbox id="foo6-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <f:ajax />
+ </h:selectBooleanCheckbox>
+ <h:inputText value="#{node.value}" id="foo6" >
+ <f:ajax event="valueChange" render="foo6-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ </h:inputText>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
+ Remove
+ </a4j:commandLink>
+ </rich:treeNode>
+ </rich:tree>
+ <br />
+ <rich:panel>
+ <h:panelGrid columns="2">
+ <h:outputLabel value="Override target address:" for="invUrlInput"/>
+ <h:inputText id="invUrlInput" value="#{clientConversationBean.invocationUrl}" />
+ <h:outputLabel value="User:" for="invUser"/>
+ <h:inputText id="invUser" value="#{clientConversationBean.invocationUser}" />
+ <h:outputLabel value="Password:" for="invPwd"/>
+ <h:inputSecret id="invPwd" value="#{clientConversationBean.invocationPwd}" redisplay="true" />
+ </h:panelGrid>
+ </rich:panel>
+
+ <rich:popupPanel id="popupPreview" modal="true" resizeable="true" onmaskclick="#{rich:component('popupPreview')}.hide()" minWidth="550" minHeight="450">
+ <f:facet name="header">
+ <h:outputText value="SOAP request message preview" />
+ </f:facet>
+ <f:facet name="controls">
+ <h:outputLink value="#" onclick="#{rich:component('popupPreview')}.hide(); return false;">X</h:outputLink>
+ </f:facet>
+ <p>Below is a preview of the SOAP message that will be generated upon invocation. The actual message going on the wire might be different
+ depending on the selected service policy (security, addressing, reliable-messaging, etc.), if any.</p>
+ <div align="center"><h:inputTextarea value="#{clientConversationBean.requestPreview}" cols="80" rows="20" readonly="true" styleClass="preformatted"/></div>
+ </rich:popupPanel>
+
+ </a4j:outputPanel>
+
+ </rich:panel>
+ <div class="navPanel" style="width: 100%;">
+ <a4j:commandButton value="<< Back" style="float:left">
+ <rich:toggleControl targetItem="@prev" event="click" />
+ </a4j:commandButton>
+ <a4j:commandButton value="Invoke >>" style="float:right">
+ <rich:toggleControl targetItem="@next" event="click" />
+ </a4j:commandButton>
+ <a4j:commandButton value="Preview message" render="popupPreview" action="#{clientConversationBean.generateRequestPreview}" style="float:right"
+ id="previewButton" oncomplete="#{rich:component('popupPreview')}.show();">
+ </a4j:commandButton>
+ </div>
+
+</ui:composition>
Added: webgui/trunk/src/main/webapp/step4.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step4.xhtml (rev 0)
+++ webgui/trunk/src/main/webapp/step4.xhtml 2013-07-02 14:31:07 UTC (rev 568)
@@ -0,0 +1,82 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:a4j="http://richfaces.org/a4j"
+ xmlns:c="http://java.sun.com/jsp/jstl/core"
+ xmlns:rich="http://richfaces.org/rich">
+
+ <rich:panel header="Response" rendered="#{clientConversationBean.responseAvailable}">
+ <a4j:outputPanel id="parOutputPanel" ajaxRendered="true"> <!-- The tree must live within a ajaxRendered outputPanel in order for properly refreshing! -->
+ <div>
+ <i>#{clientConversationBean.currentOperationFullName}</i>
+ </div>
+ <rich:tree id="richResTree" var="node" value="#{clientConversationBean.outputTree}" nodeType="#{node.kind}" switchType="ajax">
+ <rich:treeNode type="simple">
+ <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
+ rendered="#{node.notNil}" />
+ <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
+ </rich:treeNode>
+ <rich:treeNode type="qname">
+ <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
+ rendered="#{node.notNil}" />
+ <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
+ </rich:treeNode>
+ <rich:treeNode type="Duration">
+ <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
+ rendered="#{node.notNil}" />
+ <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
+ </rich:treeNode>
+ <rich:treeNode type="XMLGregorianCalendar">
+ <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
+ rendered="#{node.notNil}" />
+ <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
+ </rich:treeNode>
+ <rich:treeNode type="Enumeration">
+ <h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
+ rendered="#{node.notNil}" />
+ <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
+ </rich:treeNode>
+ <rich:treeNode type="Parameterized" expanded="#{node.expanded}">
+ <h:outputText value="{#{node.namespace}}" />
+ </rich:treeNode>
+ <rich:treeNode type="group" expanded="#{node.expanded}">
+ <h:outputText value="#{node.type}[#{node.size}]" />
+ </rich:treeNode>
+ <rich:treeNode type="complex" expanded="#{node.expanded}">
+ <h:outputText value="#{node.type} : #{node.name}" />
+ </rich:treeNode>
+ <rich:treeNode type="byteArray">
+ <h:outputText value="#{node.type} : #{node.name} = #{node.value}"
+ rendered="#{node.notNil}" />
+ <h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
+ </rich:treeNode>
+ </rich:tree>
+ <rich:popupPanel id="popupView" modal="true" resizeable="true" onmaskclick="#{rich:component('popupView')}.hide()" minWidth="550" minHeight="450">
+ <f:facet name="header">
+ <h:outputText value="SOAP response message" />
+ </f:facet>
+ <f:facet name="controls">
+ <h:outputLink value="#" onclick="#{rich:component('popupView')}.hide(); return false;">X</h:outputLink>
+ </f:facet>
+ <p>Below is the captured SOAP response message:</p>
+ <div align="center"><h:inputTextarea value="#{clientConversationBean.responseMessage}" cols="80" rows="20" readonly="true" styleClass="preformatted"/></div>
+ </rich:popupPanel>
+ </a4j:outputPanel>
+ </rich:panel>
+ <rich:panel header="Error" rendered="#{not empty clientConversationBean.error}">
+ <h:outputText value="#{clientConversationBean.error}" />
+ </rich:panel>
+
+ <div class="navPanel" style="width: 100%;">
+ <a4j:commandButton value="<< Back" style="float:left">
+ <rich:toggleControl targetItem="@prev" event="click" />
+ </a4j:commandButton>
+ <a4j:commandButton value="View message" render="popupView" style="float:right" rendered="#{clientConversationBean.responseAvailable}"
+ id="viewMessageButton" oncomplete="#{rich:component('popupView')}.show();">
+ </a4j:commandButton>
+ </div>
+
+</ui:composition>
11 years, 6 months
wise SVN: r567 - webgui/trunk.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-02 10:30:01 -0400 (Tue, 02 Jul 2013)
New Revision: 567
Modified:
webgui/trunk/pom.xml
Log:
[WISE-204] Upgrade to RF 4.3.2.Final
Modified: webgui/trunk/pom.xml
===================================================================
--- webgui/trunk/pom.xml 2013-06-21 00:51:01 UTC (rev 566)
+++ webgui/trunk/pom.xml 2013-07-02 14:30:01 UTC (rev 567)
@@ -51,7 +51,7 @@
<version.org.jboss.as.plugins.maven.plugin>7.3.Final</version.org.jboss.as.plugins.maven.plugin>
<version.org.jboss.spec.jboss.javaee.6.0>3.0.0.Final</version.org.jboss.spec.jboss.javaee.6.0>
- <version.org.richfaces>4.3.0.Final</version.org.richfaces>
+ <version.org.richfaces>4.3.2.Final</version.org.richfaces>
<version.wise.core>2.1.0-SNAPSHOT</version.wise.core>
<!-- other plugin versions -->
11 years, 6 months