Author: mvitenkov
Date: 2008-09-29 14:13:36 -0400 (Mon, 29 Sep 2008)
New Revision: 10607
Added:
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTable.xhtml
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableDefault.xhtml
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableProperty.xhtml
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableStraightforward.xhtml
Log:
xhtml for rich:extendedDataTable component
Added:
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTable.xhtml
===================================================================
---
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTable.xhtml
(rev 0)
+++
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTable.xhtml 2008-09-29
18:13:36 UTC (rev 10607)
@@ -0,0 +1,107 @@
+<f:subview
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:a4j="http://richfaces.org/a4j"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:rich="http://richfaces.org/rich"
id="extendedDataTableSubviewID">
+
+ <style type="text/css">
+.leftColumn {
+ width: 50%;
+ height: 100%;
+}
+
+.rightColumn {
+ width: 50%;
+ height: 100%;
+}
+
+.table {
+ cell-padding: 10;
+ cell-spacing: 10;
+}
+
+.mainPanel {
+ width: 100%;
+ height: 100%;
+}
+
+.leftPanel {
+ width: 100%;
+ height: 100%;
+}
+
+.rightPanel {
+ width: 100%;
+ height: 100%;
+}
+</style>
+
+ <rich:extendedDataTable id="demoTable"
+ value="#{extendedDataTableBean.dataModel}" var="patient"
+ style="margin: 0 auto;"
+ rows="#{extendedDataTableControlBean.rowsNumber}"
+ width="#{extendedDataTableControlBean.width}"
+ height="#{extendedDataTableControlBean.height}"
+ selectedClass="dataTableSelectedRow" footerClass="demo-footer"
+ sortMode="#{extendedDataTableControlBean.sortMode}"
+ selectionMode="#{extendedDataTableControlBean.selectionMode}"
+ selection="#{extendedDataTableBean.selection}" rowKeyVar="rkvar"
+ tableState="#{extendedDataTableBean.tableState}"
+ binding="#{extendedDataTableControlBean.extDTable}"
+ onclick="#{event.onclick}" ondblclick="#{event.ondblclick}"
+ onkeydown="#{event.onkeydown}" onkeypress="#{event.onkeypress}"
+ onkeyup="#{event.onkeyup}" onmousedown="#{event.onmousedown}"
+ onmousemove="#{event.onmousemove}"
onmouseout="#{event.onmouseout}"
+ onmouseover="#{event.onmouseover}" onmouseup="#{event.onmouseup}"
+ onRowClick="#{event.onRowClick}"
+ onRowDblClick="#{event.onRowDblClick}"
+ onRowMouseDown="#{event.onRowMouseDown}"
+ onRowMouseMove="#{event.onRowMouseMove}"
+ onRowMouseOut="#{event.onRowMouseOut}"
+ onRowMouseOver="#{event.onRowMouseOver}"
+ onRowMouseUp="#{event.onRowMouseUp}"
+ onselectionchange="#{event.onselectionchange}"
+ border="#{extendedDataTableControlBean.border}"
+ cellpadding="#{extendedDataTableControlBean.cellpadding}"
+ cellspacing="#{extendedDataTableControlBean.cellspacing}"
+ dir="#{extendedDataTableControlBean.dir}"
+ first="#{extendedDataTableControlBean.first}"
+ frame="#{extendedDataTableControlBean.frame}"
+ groupingColumn="#{extendedDataTableControlBean.groupingColumn}"
+ rendered="#{extendedDataTableControlBean.rendered}"
+ sortPriority="#{extendedDataTableControlBean.sortPriority}">
+ <rich:column id="firstName" headerClass="dataTableHeader"
width="25%"
+ label="First name" sortable="true"
sortBy="#{patient.firstName}"
+ filterBy="#{patient.firstName}" filterEvent="onkeyup">
+ <f:facet name="header">
+ <h:outputText value="First name" />
+ </f:facet>
+ <h:outputText id="text" value="#{patient.firstName}">
+ <rich:toolTip value="sasasasasasa" />
+ </h:outputText>
+ </rich:column>
+ <rich:column id="lastName" headerClass="dataTableHeader"
width="25%"
+ label="Last name" sortable="true"
sortBy="#{patient.lastName}"
+ filterBy="#{patient.lastName}" filterEvent="onkeyup">
+ <f:facet name="header">
+ <h:outputText value="Last name" />
+ </f:facet>
+ <h:outputText value="#{patient.lastName}" />
+ </rich:column>
+ <rich:column id="admissionDate" headerClass="dataTableHeader"
+ width="50%" label="Admission name" sortable="true"
+ sortBy="#{patient.admissionDate}">
+ <f:facet name="header">
+ <h:outputText value="Admission name" />
+ </f:facet>
+ <h:outputText value="#{patient.admissionDate}" />
+ </rich:column>
+ <a4j:support event="onselectionchange"
+ action="#{extendedDataTableBean.takeSelection}"
+ reRender="selectedPatients">
+ </a4j:support>
+ </rich:extendedDataTable>
+ <rich:datascroller style="width: #{extendedDataTableControlBean.width}"
+ rendered="#{extendedDataTableControlBean.paginated}"
for="demoTable">
+ </rich:datascroller>
+</f:subview>
\ No newline at end of file
Added:
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableDefault.xhtml
===================================================================
Added:
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableProperty.xhtml
===================================================================
---
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableProperty.xhtml
(rev 0)
+++
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableProperty.xhtml 2008-09-29
18:13:36 UTC (rev 10607)
@@ -0,0 +1,141 @@
+<f:subview
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:a4j="http://richfaces.org/a4j"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:rich="http://richfaces.org/rich"
+ id="extendedDataTablePropertySubviewID">
+
+ <h:panelGrid columns="2">
+ <h:outputLabel value="Width" for="tableWidthInput" />
+ <h:inputText id="tableWidthInput"
+ value="#{extendedDataTableControlBean.width}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:outputLabel value="Height" for="tableHeightInput" />
+ <h:inputText id="tableHeightInput"
+ value="#{extendedDataTableControlBean.height}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:outputLabel value="Number of patients"
+ for="tablePatientsNumberInput" />
+ <h:inputText id="tablePatientsNumberInput"
+ value="#{extendedDataTableBean.patientsNumber}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:outputLabel value="Sort mode" for="tableSortModeSelect"
/>
+ <h:selectOneMenu id="tableSortModeSelect"
+ value="#{extendedDataTableControlBean.sortMode}">
+ <f:selectItems
+ value="#{extendedDataTableControlBean.sortModeSelectItems}" />
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:selectOneMenu>
+
+ <h:outputLabel value="Selection mode"
for="tableSelectionModeSelect" />
+ <h:selectOneMenu id="tableSelectionModeSelect"
+ value="#{extendedDataTableControlBean.selectionMode}">
+ <f:selectItems
+ value="#{extendedDataTableControlBean.selectionModeSelectItems}" />
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:selectOneMenu>
+
+ <h:outputText value="paginated" />
+ <h:selectBooleanCheckbox id="paginatedCheckbox"
+ value="#{extendedDataTableControlBean.paginated}"
onclick="submit()" />
+
+ <h:outputLabel value="Number of rows" for="tableRowsNumberInput"
/>
+ <h:inputText id="tableRowsNumberInput"
+ value="#{extendedDataTableControlBean.rowsNumber}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:commandButton value="binding"
+ actionListener="#{extendedDataTableControlBean.checkBinding}" />
+ <h:outputText value="#{extendedDataTableControlBean.bindLabel}"
+ id="bindLabel" />
+
+ <h:outputText value="border" />
+ <h:inputText value="#{extendedDataTableControlBean.border}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:outputText value="cellpadding" />
+ <h:inputText value="#{extendedDataTableControlBean.cellpadding}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:outputText value="cellspacing" />
+ <h:inputText value="#{extendedDataTableControlBean.cellspacing}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:outputText value="dir" />
+ <h:selectOneRadio value="#{extendedDataTableControlBean.dir}">
+ <f:selectItem itemLabel="RTL" itemValue="RTL" />
+ <f:selectItem itemLabel="LTR" itemValue="LTR" />
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:selectOneRadio>
+
+ <h:outputText value="first" />
+ <h:inputText value="#{extendedDataTableControlBean.first}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:outputText value="frame" />
+ <h:panelGroup>
+ <h:inputText value="#{extendedDataTableControlBean.frame}"
+ id="inputFrame">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+ <h:outputLabel value="void, above, below, hsides, lhs, rhs, vsides, box and
border" for="inputFrame" />
+ </h:panelGroup>
+
+ <h:outputText value="groupingColumn" />
+ <h:inputText value="#{extendedDataTableControlBean.groupingColumn}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ <h:outputText value="rendered" />
+ <h:selectBooleanCheckbox
+ value="#{extendedDataTableControlBean.rendered}"
onclick="submit()" />
+
+ <h:outputText value="sortPriority" />
+ <h:inputText value="#{extendedDataTableControlBean.sortPriority}">
+ <a4j:support event="onchange"
reRender="demoTable"></a4j:support>
+ </h:inputText>
+
+ </h:panelGrid>
+ <br />
+ <h:commandButton value="add test"
+ action="#{extendedDataTableControlBean.addExtDTable}"></h:commandButton>
+ <a4j:commandButton value="Update values"
reRender="mainPanel">
+ </a4j:commandButton>
+ <br />
+
+ <rich:spacer height="5px" width="100%">
+ </rich:spacer>
+ <rich:dataTable id="selectedPatients"
+ value="#{extendedDataTableBean.selectedItems}"
var="selectedPatient">
+ <f:facet name="header">
+ <h:outputText value="Selected patient" />
+ </f:facet>
+ <rich:column id="selectedFirstName"
headerClass="dataTableHeader"
+ label="First name">
+ <f:facet name="header">
+ <h:outputText value="First name" />
+ </f:facet>
+ <h:outputText value="#{selectedPatient.firstName}" />
+ </rich:column>
+ <rich:column id="selectedLastName"
headerClass="dataTableHeader"
+ label="Last name">
+ <f:facet name="header">
+ <h:outputText value="Last name" />
+ </f:facet>
+ <h:outputText value="#{selectedPatient.lastName}" />
+ </rich:column>
+ </rich:dataTable>
+ <rich:messages>
+ </rich:messages>
+</f:subview>
\ No newline at end of file
Added:
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableStraightforward.xhtml
===================================================================
---
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableStraightforward.xhtml
(rev 0)
+++
trunk/test-applications/facelets/src/main/webapp/ExtendedDataTable/ExtendedDataTableStraightforward.xhtml 2008-09-29
18:13:36 UTC (rev 10607)
@@ -0,0 +1,8 @@
+<f:subview
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:a4j="http://richfaces.org/a4j"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:rich="http://richfaces.org/rich"
+ id="extendedDataTablePropertySubviewID">
+<!-- Insert your custom tests here -->
+</f:subview>
\ No newline at end of file