Author: ayanul
Date: 2007-12-27 06:23:57 -0500 (Thu, 27 Dec 2007)
New Revision: 5032
Modified:
trunk/test-applications/jsp/src/main/java/columns/Columns.java
trunk/test-applications/jsp/src/main/webapp/Columns/Columns.jsp
trunk/test-applications/jsp/src/main/webapp/Columns/ColumnsProperty.jsp
trunk/test-applications/jsp/src/main/webapp/CustomizePage/CustomizePage.jsp
Log:
fix columns
Modified: trunk/test-applications/jsp/src/main/java/columns/Columns.java
===================================================================
--- trunk/test-applications/jsp/src/main/java/columns/Columns.java 2007-12-27 10:59:34 UTC
(rev 5031)
+++ trunk/test-applications/jsp/src/main/java/columns/Columns.java 2007-12-27 11:23:57 UTC
(rev 5032)
@@ -21,16 +21,6 @@
private boolean breakBefore;
private boolean sortable;
private boolean dataTableRendered;
- private boolean testColumns;
-
- public boolean isTestColumns() {
- return testColumns;
- }
-
- public void setTestColumns(boolean testColumns) {
- this.testColumns = testColumns;
- }
-
public Columns() {
this.columns = "3";
this.begin = "0";
@@ -42,7 +32,6 @@
this.breakBefore = true;
this.sortable = true;
this.dataTableRendered = true;
- this.testColumns = true;
this.length1 = 5;
this.length2 = 5;
this.data1 = new ArrayList<Data>();
Modified: trunk/test-applications/jsp/src/main/webapp/Columns/Columns.jsp
===================================================================
--- trunk/test-applications/jsp/src/main/webapp/Columns/Columns.jsp 2007-12-27 10:59:34
UTC (rev 5031)
+++ trunk/test-applications/jsp/src/main/webapp/Columns/Columns.jsp 2007-12-27 11:23:57
UTC (rev 5032)
@@ -60,9 +60,8 @@
<f:verbatim><br/></f:verbatim>
<h:outputText value="test columns (*) "></h:outputText>
- <h:selectBooleanCheckbox
value="#{columns.testColumns}"></h:selectBooleanCheckbox>
- <rich:dataTable value="#{columns.data1}" var="data"
rendered="#{columns.testColumns}">
+ <rich:dataTable value="#{columns.data1}" var="data" >
<rich:columns columns="#{columns.columns}">
<h:outputText value="#{data.str0}"></h:outputText>
</rich:columns>
Modified: trunk/test-applications/jsp/src/main/webapp/Columns/ColumnsProperty.jsp
===================================================================
--- trunk/test-applications/jsp/src/main/webapp/Columns/ColumnsProperty.jsp 2007-12-27
10:59:34 UTC (rev 5031)
+++ trunk/test-applications/jsp/src/main/webapp/Columns/ColumnsProperty.jsp 2007-12-27
11:23:57 UTC (rev 5032)
@@ -4,7 +4,7 @@
<%@ taglib
uri="http://richfaces.org/rich" prefix="rich"%>
<f:subview id="columnsPropertyID">
- <h:commandButton action="submit();"
value="submit"></h:commandButton>
+ <h:commandButton value="submit"></h:commandButton>
<a4j:commandButton value="submit [a4j]"
reRender="columnsID"></a4j:commandButton>
<h:panelGrid columns="2">
<f:facet name="header">
Modified: trunk/test-applications/jsp/src/main/webapp/CustomizePage/CustomizePage.jsp
===================================================================
--- trunk/test-applications/jsp/src/main/webapp/CustomizePage/CustomizePage.jsp 2007-12-27
10:59:34 UTC (rev 5031)
+++ trunk/test-applications/jsp/src/main/webapp/CustomizePage/CustomizePage.jsp 2007-12-27
11:23:57 UTC (rev 5032)
@@ -1,27 +1,119 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html
xmlns="http://www.w3.org/1999/xhtml"
xmlns:rich="http://richfaces.org/rich"
xmlns:a4j="http://richfaces.org/a4j"
-
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html">
-<head>
-<link rel="stylesheet"
href="#{facesContext.externalContext.requestContextPath}/styles/styles.css"
type="text/css" />
-</head>
+<%@ taglib
uri="http://java.sun.com/jsf/html" prefix="h"%>
+<%@ taglib
uri="http://java.sun.com/jsf/core" prefix="f"%>
+<%@ taglib
uri="http://richfaces.org/a4j" prefix="a4j"%>
+<%@ taglib
uri="http://richfaces.org/rich" prefix="rich"%>
-
+<html>
<f:view>
- <h:form id="test">
-<rich:tabPanel switchType="ajax">
+ <head>
+ <f:loadBundle basename="message" var="msg" />
+ <title></title>
-<rich:tab label="Sample 1">
-<h:outputText value="1"></h:outputText>
-<h:inputText value="#{dDMenu.mode}" required="true" />
-</rich:tab>
+ <script type="text/javascript">
+ function showEvent(elementID, value) {
+ var oldObject = window.document.getElementById(elementID);
+ if(oldObject == null || oldObject.type == "text") return;
+ var newObject = window.document.createElement('input');
+ if(oldObject.type) newObject.type = "text";
+ if(oldObject.size) newObject.size = oldObject.size;
+ if(oldObject.value) newObject.value = value;
+ if(oldObject.id) newObject.id = oldObject.id;
+ oldObject.parentNode.replaceChild(newObject,oldObject);
+ }
+ </script>
+ <link rel="stylesheet"
+ href="<%=request.getContextPath()%>/styles/styles.css"
type="text/css" />
+ </head>
+ <body>
+ <h:form id="test">
+ <rich:dataTable id="richColumnsID" value="#{columns.data1}"
var="d1"
+ rendered="#{columns.dataTableRendered}">
+ <h:column>
+ <h:outputText value="h: #{d1.int0}"></h:outputText>
+ </h:column>
-<rich:tab label="Sample 2">
-<a4j:support event="ontabenter"></a4j:support>
-<h:outputText value="2"></h:outputText>
-<h:inputText value="#{dDMenu.mode}"></h:inputText>
-</rich:tab>
+ <rich:column>
+ <h:outputText value="rich: #{d1.int0}"></h:outputText>
+ </rich:column>
-</rich:tabPanel>
- </h:form>
+ <rich:columns value="#{columns.data2}" var="d2"
+ breakBefore="#{columns.breakBefore}"
colspan="#{columns.colspan}"
+ columns="#{columns.columns}" index="index"
+ rowspan="#{columns.rowspan}" sortable="#{columns.sortable}"
+ title="#{columns.title}" begin="#{columns.begin}"
end="100"
+ width="#{columns.width}">
+ <f:facet name="header">
+ <h:outputText value="header #{d2.int0}"></h:outputText>
+ </f:facet>
+ <h:outputText value="#{index}. "></h:outputText>
+ <h:outputText value="#{d1.str0}, "></h:outputText>
+ <h:outputText value="#{d2.str0}"></h:outputText>
+ <f:facet name="footer">
+ <h:outputText value="footer #{d2.int0}"></h:outputText>
+ </f:facet>
+ </rich:columns>
+ </rich:dataTable>
+ <h:commandButton value="submit"></h:commandButton>
+ <a4j:commandButton value="submit [a4j]"
reRender="columnsID"></a4j:commandButton>
+ <h:panelGrid columns="2">
+ <f:facet name="header">
+ <h:outputText value="columns"></h:outputText>
+ </f:facet>
+ <h:outputText value="Enter quantity of lines [data 1]" />
+ <h:panelGroup>
+ <h:inputText value="#{columns.length1}" />
+ <h:commandButton action="#{columns.addNewItem1}" value="ok"
+ onclick="submit();"></h:commandButton>
+ </h:panelGroup>
+
+ <h:outputText value="Enter quantity of lines [data 2]" />
+ <h:panelGroup>
+ <h:inputText value="#{columns.length2}" />
+ <h:commandButton action="#{columns.addNewItem2}" value="ok"
+ onclick="submit();"></h:commandButton>
+ </h:panelGroup>
+
+ <h:outputText value="title:"></h:outputText>
+ <h:inputText value="#{columns.title}" onchange="submit();">
+ </h:inputText>
+
+ <h:outputText value="columns (*):"></h:outputText>
+ <h:inputText value="#{columns.columns}"
onchange="submit();">
+ </h:inputText>
+
+ <h:outputText value="rowspan:"></h:outputText>
+ <h:inputText value="#{columns.rowspan}"
onchange="submit();">
+ </h:inputText>
+
+ <h:outputText value="colspan:"></h:outputText>
+ <h:inputText value="#{columns.colspan}"
onchange="submit();">
+ </h:inputText>
+
+ <h:outputText value="begin:"></h:outputText>
+ <h:inputText value="#{columns.begin}" onchange="submit();">
+ </h:inputText>
+
+ <h:outputText value="end:"></h:outputText>
+ <h:inputText value="#{columns.end}" onchange="submit();">
+ </h:inputText>
+
+ <h:outputText value="width:"></h:outputText>
+ <h:inputText value="#{columns.width}" onchange="submit();">
+ </h:inputText>
+
+ <h:outputText value="sortable"></h:outputText>
+ <h:selectBooleanCheckbox value="#{columns.sortable}"
+ onchange="submit();">
+ </h:selectBooleanCheckbox>
+
+ <h:outputText value="breakBefore:"></h:outputText>
+ <h:selectBooleanCheckbox value="#{columns.breakBefore}"
+ onchange="submit();">
+ </h:selectBooleanCheckbox>
+ </h:panelGrid>
+ </h:form>
+ </body>
</f:view>
-</html>
\ No newline at end of file
+</html>
+