[seam-commits] Seam SVN: r14460 - in branches/community/Seam_2_3/examples-ee6: seampay and 36 other directories.

seam-commits at lists.jboss.org seam-commits at lists.jboss.org
Mon Apr 2 06:17:19 EDT 2012


Author: maschmid
Date: 2012-04-02 06:17:17 -0400 (Mon, 02 Apr 2012)
New Revision: 14460

Added:
   branches/community/Seam_2_3/examples-ee6/seampay/
   branches/community/Seam_2_3/examples-ee6/seampay/pom.xml
   branches/community/Seam_2_3/examples-ee6/seampay/readme.txt
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/pom.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/src/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/src/main/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/src/main/application/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/src/main/application/META-INF/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/src/main/application/META-INF/jboss-deployment-structure.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/pom.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/Account.java
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/Payment.java
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/PaymentHome.java
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/PaymentProcessor.java
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/package-info.java
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/ejb-jar.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/persistence.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/import.sql
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/seam.properties
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/pom.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/AccountTest.java
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/PaymentProcessorTest.java
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-ftest/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-ftest/testng.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-integration/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-integration/testng.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/WEB-INF/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/WEB-INF/components.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seam.properties
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seampay.properties
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/pom.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/components.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/faces-config.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/pages.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/web.xml
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/date.css
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/cal-next.png
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/cal-prev.png
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/dtpick.gif
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/index.html
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/screen.css
   branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/search.xhtml
Log:
add seampay example to the ee6 examples


Added: branches/community/Seam_2_3/examples-ee6/seampay/pom.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/pom.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/pom.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.jboss.seam.examples-ee6</groupId>
+    <artifactId>seampay</artifactId>
+    <parent>
+        <groupId>org.jboss.seam</groupId>
+        <artifactId>examples-ee6</artifactId>
+        <version>2.3.0.Beta2-SNAPSHOT</version>
+    </parent>
+    <packaging>pom</packaging>
+    <name>Seampay Example (EE6)</name>
+    
+    <properties>
+        <example.name>seampay</example.name>
+    </properties>
+    
+    <modules>
+        <module>seampay-ear</module>
+        <module>seampay-ejb</module>
+        <module>seampay-web</module>
+        <module>seampay-tests</module>
+    </modules>
+    
+    <dependencyManagement>
+        <dependencies>
+            <dependency>
+                <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                <artifactId>seampay-ejb</artifactId>
+                <version>${project.version}</version>
+                <type>ejb</type>
+            </dependency>
+            <dependency>
+                <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                <artifactId>seampay-web</artifactId>
+                <version>${project.version}</version>
+                <type>war</type>
+            </dependency>
+            <dependency>
+                <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                <artifactId>seampay-ear</artifactId>
+                <version>${project.version}</version>
+            </dependency>
+        </dependencies>
+    </dependencyManagement>
+</project>

Added: branches/community/Seam_2_3/examples-ee6/seampay/readme.txt
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/readme.txt	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/readme.txt	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,29 @@
+Seam Seampay Example
+====================
+
+This example shows Seam's EJB3 timer support. It runs on JBoss AS as an EAR
+and Tomcat with Embedded JBoss as a WAR.
+
+To deploy the example to JBoss AS, follow these steps:
+
+* In the example root directory, run:
+
+    mvn clean package
+
+* Set JBOSS_HOME environment property.
+
+* In the seampay-ear directory, run:
+
+    mvn jboss:hard-deploy
+
+* Open this URL in a web browser: http://localhost:8080/seam-seampay
+
+To deploy the example to Tomcat with Embedded JBoss, follow these steps:
+
+* In the example root directory, run:
+
+    mvn clean package -Ptomcat
+
+* Deploy the resulting war from seampay-web/target directory to Tomcat manually.
+
+* Open this URL in a web browser: http://localhost:8080/jboss-seam-seampay

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/pom.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/pom.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/pom.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,131 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <artifactId>seampay</artifactId>
+        <groupId>org.jboss.seam.examples-ee6</groupId>
+        <version>2.3.0.Beta2-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+    
+    <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+    <artifactId>seampay-ear</artifactId>
+    <packaging>ear</packaging>
+    <name>Seampay EAR Module (EE6)</name>
+    
+    <dependencies>
+        <dependency>
+            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+            <artifactId>seampay-web</artifactId>
+            <type>war</type>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+            <artifactId>seampay-ejb</artifactId>
+            <type>ejb</type>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.seam</groupId>
+            <artifactId>jboss-seam</artifactId>
+            <type>ejb</type>
+            <scope>compile</scope>
+            <exclusions>
+                <exclusion>
+                    <groupId>com.thoughtworks.xstream</groupId>
+                    <artifactId>xstream</artifactId>
+                </exclusion>
+                <exclusion>
+                    <groupId>xpp3</groupId>
+                    <artifactId>xpp3_min</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+        <dependency>
+            <groupId>commons-digester</groupId>
+            <artifactId>commons-digester</artifactId>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <finalName>seam-seampay</finalName>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-ear-plugin</artifactId>
+                <configuration>
+                    <version>6</version>
+                    <defaultLibBundleDir>lib</defaultLibBundleDir>
+                    <!-- Exclude eclipse generated application.xml and manually modified jboss-app.xml during mvn build  -->
+                    <earSourceExcludes>**/application.xml, **/jboss-app.xml</earSourceExcludes>
+                    <!-- use maven generated application.xml instead -->
+                    <generateApplicationXml>true</generateApplicationXml>
+                    <filtering>true</filtering>
+                    <modules>
+                        <webModule>
+                            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                            <artifactId>seampay-web</artifactId>
+                            <contextRoot>/seam-seampay</contextRoot>
+                            <bundleFileName>seampay-web.war</bundleFileName>
+                        </webModule>
+                        <ejbModule>
+                            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                            <artifactId>seampay-ejb</artifactId>
+                            <bundleFileName>seampay-ejb.jar</bundleFileName>
+                        </ejbModule>
+                    </modules>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+    <profiles>
+        <profile>
+            <id>exploded</id>
+            <properties>
+                <example.name>seampay</example.name>
+            </properties>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-dependency-plugin</artifactId>
+                        <executions>
+                            <execution>
+                                <id>unpack</id>
+                                <phase>package</phase>
+                                <goals>
+                                    <goal>unpack</goal>
+                                </goals>
+                                <configuration>
+                                    <artifactItems>
+                                        <artifactItem>
+                                            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                                            <artifactId>seampay-ear</artifactId>
+                                            <type>ear</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>${project.build.directory}/${project.build.finalName}-exploded/${project.build.finalName}.ear</outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                                            <artifactId>seampay-web</artifactId>
+                                            <type>war</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>${project.build.directory}/${project.build.finalName}-exploded/${project.build.finalName}.ear/${example.name}-web.war</outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                                            <artifactId>seampay-ejb</artifactId>
+                                            <type>jar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>${project.build.directory}/${project.build.finalName}-exploded/${project.build.finalName}.ear/${example.name}-ejb.jar</outputDirectory>
+                                        </artifactItem>
+                                    </artifactItems>
+                                </configuration>
+                            </execution>
+                        </executions>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
+    </profiles>
+</project>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/src/main/application/META-INF/jboss-deployment-structure.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/src/main/application/META-INF/jboss-deployment-structure.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ear/src/main/application/META-INF/jboss-deployment-structure.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,9 @@
+<jboss-deployment-structure xmlns="urn:jboss:deployment-structure:1.0">
+    <deployment>
+        <dependencies>
+            <module name="org.dom4j" export="true"/>
+            <module name="javax.faces.api" export="true"/>
+            <module name="com.sun.jsf-impl" export="true"/>
+        </dependencies>
+    </deployment>  
+</jboss-deployment-structure> 

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/pom.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/pom.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/pom.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <artifactId>seampay</artifactId>
+        <groupId>org.jboss.seam.examples-ee6</groupId>
+        <version>2.3.0.Beta2-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+    
+    <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+    <artifactId>seampay-ejb</artifactId>
+    <packaging>ejb</packaging>
+    <name>Seampay EJB Module (EE6)</name>
+    
+    <dependencies>
+        <dependency>
+            <groupId>org.jboss.seam</groupId>
+            <artifactId>jboss-seam</artifactId>
+            <type>ejb</type>
+        </dependency>
+        <dependency>
+            <groupId>javax.persistence</groupId>
+            <artifactId>persistence-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.hibernate</groupId>
+            <artifactId>hibernate-validator</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.hibernate</groupId>
+            <artifactId>hibernate-entitymanager</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>servlet-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>javax.ejb</groupId>
+            <artifactId>ejb-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>com.sun.faces</groupId>
+            <artifactId>jsf-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+    </dependencies>
+   
+</project>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/Account.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/Account.java	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/Account.java	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,79 @@
+package org.jboss.seam.example.seampay;
+
+import java.io.Serializable;
+import java.math.BigDecimal;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.persistence.CascadeType;
+import javax.persistence.Entity;
+import javax.persistence.GeneratedValue;
+import javax.persistence.Id;
+import javax.persistence.OneToMany;
+
+import javax.validation.constraints.NotNull;
+
+ at Entity
+public class Account
+    implements Serializable
+{
+    private static final long serialVersionUID = -2246235767373372214L;
+
+    @Id @GeneratedValue 
+    private Long id;
+
+    @NotNull
+    BigDecimal balance = BigDecimal.ZERO;
+
+    @NotNull
+    String accountNumber;
+    //String login;
+    //String password;
+       
+    @OneToMany(mappedBy="account", cascade=CascadeType.REMOVE)
+    //@OrderBy("paymentDate")
+    private List<Payment> payments;
+   
+    public Long getId()
+    {
+        return id;
+    }
+    public void setId(Long id)
+    {
+        this.id = id;
+    }
+
+    public String getAccountNumber()
+    {
+        return accountNumber;
+    }
+    public void setAccountNumber(String accountNumber)
+    {
+        this.accountNumber = accountNumber;
+    }
+
+
+    public BigDecimal getBalance()
+    {
+        return balance;
+    }
+
+    public BigDecimal adjustBalance(BigDecimal amount) {
+        balance = balance.add(amount);
+        return balance;
+    }
+
+    public List<Payment> getPayments() 
+    {   
+        return payments;
+    }
+
+    public void addPayment(Payment payment) {
+        if (payments == null) {
+            payments = new ArrayList<Payment>();
+        }
+        
+        payments.add(payment);
+    }
+    
+}

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/Payment.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/Payment.java	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/Payment.java	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,140 @@
+package org.jboss.seam.example.seampay;
+
+import java.io.Serializable;
+import java.math.BigDecimal;
+import java.util.Date;
+
+import javax.ejb.TimerHandle;
+import javax.persistence.Entity;
+import javax.persistence.GeneratedValue;
+import javax.persistence.Id;
+import javax.persistence.Lob;
+import javax.persistence.ManyToOne;
+
+import javax.validation.constraints.Size;
+import javax.validation.constraints.NotNull;
+import javax.validation.constraints.Digits;
+
+ at Entity
+public class Payment
+    implements Serializable
+{
+    private static final long serialVersionUID = 3467815268074102080L;
+
+    @Id @GeneratedValue 
+    private Long id;
+
+    @NotNull
+    @Digits(integer=8, fraction=2)
+    private BigDecimal amount;
+
+    @NotNull @Size(min=1)
+    private String payee;
+
+    @NotNull @ManyToOne
+    private Account account;
+   
+    @NotNull
+    private Date paymentDate;
+    @NotNull
+    private Date createdDate;
+    private Date lastPaid;
+
+    private boolean active = true;
+
+    private Frequency paymentFrequency = Frequency.DAILY;
+    
+    @Lob
+    private TimerHandle timerHandle;
+
+    public Long getId() {
+        return id;
+    }
+    
+    public BigDecimal getAmount() {
+        return amount;
+    }
+    public void setAmount(BigDecimal amount) {
+        this.amount = amount;
+    }
+
+    public String getPayee()
+    {
+        return payee;
+    }
+
+    public void setPayee(String payee) {
+        this.payee = payee;
+    }
+
+    public Account getAccount() {
+        return account;
+    }
+    
+    public void setAccount(Account account) {
+        this.account = account;
+        account.addPayment(this);
+    }
+
+    public Date getPaymentDate() {
+        return paymentDate;
+    }
+    public void setPaymentDate(Date paymentDate) {
+        this.paymentDate = paymentDate;
+    }  
+
+    public Date getCreatedDate() {
+        return createdDate;
+    }    
+    public void setCreatedDate(Date createdDate) {
+        this.createdDate = createdDate;
+    }  
+
+
+    public Date getLastPaid() {
+        return lastPaid;
+    }    
+    public void setLastPaid(Date lastPaid) {
+        this.lastPaid = lastPaid;
+    }  
+        
+    public boolean getActive() {
+        return active;
+    }
+    public void setActive(boolean active) {
+        this.active = active;
+    }
+   
+    public Frequency getPaymentFrequency() { 
+        return paymentFrequency; 
+    }
+    public void setPaymentFrequency(Frequency paymentFrequency) {
+        this.paymentFrequency = paymentFrequency;
+    }
+
+    public TimerHandle getTimerHandle() {
+        return timerHandle;
+    }
+    public void setTimerHandle(TimerHandle timerHandle) {
+        this.timerHandle = timerHandle;
+    }
+
+
+    public enum Frequency {
+        ONCE(null), 
+        EVERY_MINUTE(60*1000l),
+        HOURLY(60*60*1000l), 
+        DAILY(24*60*60*1000l), 
+        WEEKLY(7*24*60*60*1000l);
+
+        Long interval; 
+
+        Frequency(Long interval) {
+            this.interval = interval;
+        }
+        
+        public Long getInterval() {
+            return interval;
+        }
+    }
+}

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/PaymentHome.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/PaymentHome.java	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/PaymentHome.java	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,65 @@
+package org.jboss.seam.example.seampay;
+
+import javax.ejb.NoSuchObjectLocalException;
+import javax.ejb.Timer;
+import javax.ejb.TimerHandle;
+
+import org.jboss.seam.annotations.In;
+import org.jboss.seam.annotations.Logger;
+import org.jboss.seam.annotations.Name;
+import org.jboss.seam.annotations.web.RequestParameter;
+import org.jboss.seam.annotations.Transactional;
+import org.jboss.seam.faces.FacesMessages;
+import org.jboss.seam.framework.EntityHome;
+import org.jboss.seam.log.Log;
+
+ at Name("paymentHome")
+public class PaymentHome
+    extends EntityHome<Payment>
+{
+    private static final long serialVersionUID = -1994187524284737182L;
+    
+    @RequestParameter Long paymentId;
+    @In PaymentProcessor processor;
+    
+    @Logger Log log;
+
+    public String saveAndSchedule()
+    {
+        String result = persist();
+        
+        Payment payment = getInstance();
+        log.info("scheduling instance #0", payment);
+
+        Timer timer = processor.schedulePayment(payment.getPaymentDate(), 
+                                                payment.getPaymentFrequency().getInterval(), 
+                                                payment);
+        if (timer != null) {
+            payment.setTimerHandle(timer.getHandle());
+        }
+        return result;
+    }
+
+    @Override
+    public Object getId() {
+        return paymentId;
+    }
+
+    @Transactional
+    public void cancel() {
+        Payment payment = getInstance();
+        
+        TimerHandle handle = payment.getTimerHandle();
+        payment.setTimerHandle(null);
+        payment.setActive(false);
+        
+        if (handle != null) {
+            try {
+                handle.getTimer().cancel();
+            } catch (NoSuchObjectLocalException e) {
+                FacesMessages.instance().add("Payment already processed");
+            }
+        }
+    }
+    
+}

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/PaymentProcessor.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/PaymentProcessor.java	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/PaymentProcessor.java	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,53 @@
+package org.jboss.seam.example.seampay;
+
+import java.util.Date;
+
+import javax.ejb.Timer;
+import javax.persistence.EntityManager;
+
+import org.jboss.seam.annotations.async.Asynchronous;
+import org.jboss.seam.annotations.AutoCreate;
+import org.jboss.seam.annotations.In;
+import org.jboss.seam.annotations.Logger;
+import org.jboss.seam.annotations.Name;
+import org.jboss.seam.annotations.Transactional;
+import org.jboss.seam.annotations.async.Expiration;
+import org.jboss.seam.annotations.async.IntervalDuration;
+import org.jboss.seam.example.seampay.Payment;
+import org.jboss.seam.log.Log;
+
+ at Name("processor")
+ at AutoCreate
+public class PaymentProcessor {
+    
+    @In 
+    EntityManager entityManager;
+
+    @Logger Log log;
+
+    @Asynchronous
+    @Transactional
+    public Timer schedulePayment(@Expiration Date when, 
+                                 @IntervalDuration Long interval, 
+                                 Payment payment) 
+    { 
+        payment = entityManager.merge(payment);
+
+        log.info("[#0] Processing payment #1", System.currentTimeMillis(), payment.getId());
+        processPayment(payment);
+
+        return null;
+    }
+
+    public void processPayment(Payment payment) {
+        if (payment.getActive()) {
+            payment.getAccount().adjustBalance(payment.getAmount().negate());
+            
+            payment.setLastPaid(new Date());
+            
+            if (payment.getPaymentFrequency().equals(Payment.Frequency.ONCE)) {
+                payment.setActive(false);
+            }
+        }
+    }
+}

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/package-info.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/package-info.java	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/java/org/jboss/seam/example/seampay/package-info.java	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,4 @@
+ at Namespace(value="http://jboss.com/products/seam/examples/seampay")
+package org.jboss.seam.example.seampay;
+
+import org.jboss.seam.annotations.*;

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/ejb-jar.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/ejb-jar.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/ejb-jar.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" 
+         version="3.0">
+
+   <interceptors>
+     <interceptor>
+       <interceptor-class>org.jboss.seam.ejb.SeamInterceptor</interceptor-class>
+     </interceptor>
+   </interceptors>
+   
+   <assembly-descriptor>
+      <interceptor-binding>
+         <ejb-name>*</ejb-name>
+         <interceptor-class>org.jboss.seam.ejb.SeamInterceptor</interceptor-class>
+      </interceptor-binding>
+   </assembly-descriptor>
+
+</ejb-jar>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/persistence.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/persistence.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/META-INF/persistence.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<persistence xmlns="http://java.sun.com/xml/ns/persistence"
+             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
+             version="1.0">
+    <persistence-unit name="userDatabase">
+        <provider>org.hibernate.ejb.HibernatePersistence</provider>
+        <jta-data-source>java:jboss/datasources/ExampleDS</jta-data-source>
+        <properties>
+            <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
+            <property name="hibernate.show_sql" value="true"/>
+            <property name="jboss.entity.manager.factory.jndi.name" 
+                      value="java:/seampayEntityManagerFactory"/>
+        </properties>
+    </persistence-unit>
+</persistence>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/import.sql
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/import.sql	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/import.sql	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,6 @@
+insert into Account(id, accountNumber, balance) values (1, '23001', 1001.46) 
+insert into Account(id, accountNumber, balance) values (2, '23002', 1002.46) 
+insert into Account(id, accountNumber, balance) values (3, '23003', 1003.46) 
+insert into Account(id, accountNumber, balance) values (4, '23004', 1004.46) 
+insert into Account(id, accountNumber, balance) values (5, '23005', 1005.46) 
+

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-ejb/src/main/resources/seam.properties
===================================================================
Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/pom.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/pom.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/pom.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,136 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <artifactId>seampay</artifactId>
+        <groupId>org.jboss.seam.examples-ee6</groupId>
+        <version>2.3.0.Beta2-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+    
+    <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+    <artifactId>seampay-tests</artifactId>
+    <name>Seampay Integration Tests Module (EE6)</name>
+    
+    <dependencies>
+        <dependency>
+            <groupId>org.testng</groupId>
+            <artifactId>testng</artifactId>
+            <classifier>jdk15</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+            <artifactId>seampay-ejb</artifactId>
+            <type>ejb</type>
+            <scope>test</scope>
+        </dependency>        
+        <dependency>
+            <groupId>org.jboss.seam</groupId>
+            <artifactId>jboss-seam</artifactId>
+            <type>ejb</type>
+            <scope>test</scope>
+        </dependency>        
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>com.sun.faces</groupId>
+            <artifactId>jsf-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>javax.persistence</groupId>
+            <artifactId>persistence-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.seleniumhq.selenium.server</groupId>
+            <artifactId>selenium-server</artifactId>
+            <classifier>standalone</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.seleniumhq.selenium.client-drivers</groupId>
+            <artifactId>selenium-java-client-driver</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.seam</groupId>
+            <artifactId>functional-tests</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+    
+    <build>
+        <testResources>
+            <testResource>
+                <directory>src/test/resources</directory>
+                <filtering>true</filtering>
+            </testResource>
+			<testResource> <!-- this takes datasource seampay-ds.xml -->
+				<directory>${basedir}/../seampay-ear/src/main/resources</directory>
+				<filtering>true</filtering>
+			</testResource>
+			<testResource> <!-- this takes themes aka *.properties -->
+			     <directory>${basedir}/../seampay-web/src/main/resources</directory>
+			     <filtering>true</filtering>
+			</testResource>
+        </testResources>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-surefire-plugin</artifactId>
+                <configuration>
+                    <skip>true</skip>
+                </configuration>
+            </plugin>
+        </plugins>     
+    </build>    
+
+    <profiles>
+        <profile>
+            <id>ftest-jbossas</id>
+            <properties>
+                <example.context.path>seam-seampay</example.context.path>
+            </properties>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.codehaus.mojo</groupId>
+                        <artifactId>selenium-maven-plugin</artifactId>
+                    </plugin>
+                    <plugin>
+                        <groupId>org.codehaus.mojo</groupId>
+                        <artifactId>failsafe-maven-plugin</artifactId>
+                    </plugin>
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-antrun-plugin</artifactId>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
+        <profile>
+            <id>ftest-tomcat</id>
+            <properties>
+                <example.context.path>jboss-seam-seampay</example.context.path>
+            </properties>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.codehaus.mojo</groupId>
+                        <artifactId>selenium-maven-plugin</artifactId>
+                    </plugin>
+                    <plugin>
+                        <groupId>org.codehaus.mojo</groupId>
+                        <artifactId>failsafe-maven-plugin</artifactId>
+                    </plugin>
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-antrun-plugin</artifactId>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
+    </profiles>
+    
+</project>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/AccountTest.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/AccountTest.java	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/AccountTest.java	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,120 @@
+package org.jboss.seam.example.seampay.test;
+
+import java.math.BigDecimal;
+import java.util.List;
+
+import org.jboss.seam.example.seampay.Account;
+import org.jboss.seam.example.seampay.Payment;
+import org.jboss.seam.example.seampay.Payment.Frequency;
+import org.jboss.seam.mock.SeamTest;
+import org.testng.annotations.Test;
+
+/**
+ *  embedded ejb3 doesn't support timer service, so we are fairly limited on what we can test.
+ */
+public class AccountTest 
+    extends SeamTest 
+{
+    @Test
+    public void listAccounts() throws Exception {
+        String id = new FacesRequest("/search.xhtml") {
+            
+            @Override
+            @SuppressWarnings("unchecked")
+            protected void renderResponse() throws Exception {
+                List<Account> accounts = (List<Account>) getValue("#{accounts.resultList}");
+                
+                assert accounts.size() == 5;                
+                // check ASC?
+            }          
+        }.run(); 
+    }
+    
+    @Test
+    public void selectAccount() throws Exception {        
+        String id = new FacesRequest("/search.xhtml") {        
+            @Override
+            @SuppressWarnings("unchecked")
+            protected void renderResponse() throws Exception {           
+                assert !((Boolean)getValue("#{accountHome.idDefined}"));
+            }          
+        }.run();
+        
+        new FacesRequest("/search.xhtml", id) {
+            @Override
+            protected void beforeRequest() {
+                setParameter("accountId", "1");
+            }
+
+            @Override
+            protected void renderResponse() throws Exception {
+                assert ((Boolean)getValue("#{accountHome.idDefined}"));
+                
+                Account account = (Account) getValue("#{selectedAccount}");
+                assert account !=null;
+                assert account.getId() == 1;
+                assert account.getPayments().size() == 0;
+               
+                Payment payment = (Payment) getValue("#{newPayment}");
+                assert payment.getPayee().equals("Somebody");
+                assert payment.getAccount() != null;
+                assert payment.getAccount().getId() == 1;
+                
+            }            
+        }.run();
+        
+        
+        new FacesRequest("/search.xhtml", id) {
+            @Override
+            protected void beforeRequest() {
+                setParameter("accountId", "1");
+            }
+            
+            @Override
+            protected void applyRequestValues() throws Exception {
+                setValue("#{newPayment.payee}", "IRS"); 
+                setValue("#{newPayment.amount}", new BigDecimal("100.00"));
+                setValue("#{newPayment.paymentFrequency}", Frequency.ONCE);
+            }
+
+            @Override
+            protected void invokeApplication() throws Exception {
+                invokeMethod("#{paymentHome.saveAndSchedule}");
+            }
+
+            @Override
+            protected void renderResponse() throws Exception {
+                assert ((Boolean)getValue("#{accountHome.idDefined}"));                
+                Account account = (Account) getValue("#{selectedAccount}");                
+                assert account !=null;
+                assert account.getId() == 1;
+                assert account.getPayments().size() == 1;               
+                
+                Payment payment = (Payment) getValue("#{newPayment}");
+                assert payment.getPayee().equals("IRS");
+                assert payment.getAmount().equals(new BigDecimal("100.00"));
+                assert payment.getAccount() != null;
+                assert payment.getAccount().getId() == 1;
+            }            
+        }.run();
+        
+        
+        // test that the payment is around
+        new FacesRequest("/search.xhtml") {
+            @Override
+            protected void beforeRequest() {
+                setParameter("accountId", "1");
+            }
+            
+            @Override
+            protected void renderResponse() throws Exception {
+                assert ((Boolean)getValue("#{accountHome.idDefined}"));                
+                Account account = (Account) getValue("#{selectedAccount}");                
+                assert account !=null;
+                assert account.getId() == 1;
+                assert account.getPayments().size() == 1;        
+            }            
+        }.run();
+    }
+    
+}

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/PaymentProcessorTest.java
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/PaymentProcessorTest.java	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/java/org/jboss/seam/example/seampay/test/PaymentProcessorTest.java	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,97 @@
+package org.jboss.seam.example.seampay.test;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+import org.jboss.seam.example.seampay.Account;
+import org.jboss.seam.example.seampay.Payment;
+import org.jboss.seam.example.seampay.PaymentProcessor;
+import org.jboss.seam.example.seampay.Payment.Frequency;
+import org.jboss.seam.mock.SeamTest;
+import org.testng.annotations.Test;
+
+public class PaymentProcessorTest 
+    extends SeamTest
+{
+    static final String     ACCOUNT_NUMBER = "X12345";
+    static final BigDecimal INITIAL_BALANCE = new BigDecimal("1000");
+
+    @Test 
+    public void testInactive() {
+        PaymentProcessor processor = new PaymentProcessor();
+        
+        Payment payment = createTestPayment(new BigDecimal("100"), Frequency.ONCE);
+        payment.setActive(false);                
+                
+        assert payment.getAccount().getBalance().equals(INITIAL_BALANCE);        
+               
+        processor.processPayment(payment);
+        
+        assert payment.getAccount().getBalance().equals(INITIAL_BALANCE);
+        assert payment.getLastPaid() == null;
+    }
+    
+    @Test 
+    public void testPayOnce() {
+        PaymentProcessor processor = new PaymentProcessor();
+        
+        Payment payment = createTestPayment(new BigDecimal("100"), Frequency.ONCE);
+
+        assert payment.getAccount().getBalance().equals(INITIAL_BALANCE); 
+
+        processor.processPayment(payment);
+               
+        assert payment.getAccount().getBalance().equals(new BigDecimal("900"));
+        assert !payment.getActive();
+        assert payment.getLastPaid() != null;
+    }
+    
+    @Test 
+    public void testPayMultiple() {
+        PaymentProcessor processor = new PaymentProcessor();
+        
+        Payment payment = createTestPayment(new BigDecimal("100"), Frequency.WEEKLY);
+
+        assert payment.getAccount().getBalance().equals(INITIAL_BALANCE); 
+
+        processor.processPayment(payment);
+               
+        assert payment.getAccount().getBalance().equals(new BigDecimal("900"));
+        assert payment.getActive();
+        assert payment.getLastPaid() != null;
+        
+        Date firstPayment = payment.getLastPaid();
+        
+        pause(); // just need to make sure we are some small time in the future
+        
+        processor.processPayment(payment);
+     
+        assert payment.getAccount().getBalance().equals(new BigDecimal("800"));
+        assert payment.getActive();
+        assert payment.getLastPaid().after(firstPayment);
+    }
+  
+    
+    private void pause() {
+        try {
+            Thread.sleep(1);
+        } catch (InterruptedException e) {
+            
+        }                
+    }
+
+    protected Payment createTestPayment(BigDecimal amount, Frequency frequency) {
+        Account account = new Account();
+        account.setAccountNumber(ACCOUNT_NUMBER);
+        setField(account, "balance", INITIAL_BALANCE);
+        
+        Payment payment = new Payment();
+        payment.setAccount(account);
+        payment.setAmount(amount);
+        payment.setPaymentFrequency(frequency);        
+        
+        return payment;
+    }
+    
+    
+}

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/WEB-INF/components.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/WEB-INF/components.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/WEB-INF/components.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,46 @@
+<components xmlns:pay="http://jboss.com/products/seam/examples/seampay"
+            xmlns:core="http://jboss.com/products/seam/core"
+            xmlns:persistence="http://jboss.com/products/seam/persistence"
+            xmlns:framework="http://jboss.com/products/seam/framework"
+            xmlns:async="http://jboss.com/products/seam/async"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation=
+                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.3.xsd
+                 http://jboss.com/products/seam/persistence http://jboss.com/products/seam/persistence-2.3.xsd
+                 http://jboss.com/products/seam/async http://jboss.com/products/seam/async-2.3.xsd
+                 http://jboss.com/products/seam/framework http://jboss.com/products/seam/framework-2.3.xsd" >
+
+    <pay:payment-home 
+                       new-instance="#{newPayment}" 
+                      created-message="Created a new payment to #{newPayment.payee}" />
+
+
+    <pay:payment name="newPayment" 
+                 payee="Somebody"
+                 account="#{selectedAccount}"
+                 payment-date="#{currentDatetime}"
+                 created-date="#{currentDatetime}" />
+
+    <factory name="selectedAccount" 
+             value="#{accountHome.instance}"/>
+
+    <framework:entity-home name="accountHome" 
+                           entity-class="org.jboss.seam.example.seampay.Account"
+                           entity-manager="#{entityManager}" />
+
+    <framework:entity-query name="accounts" 
+                            ejbql="from Account"
+                            order="accountNumber" 
+                            max-results="20" 
+                            entity-manager="#{entityManager}" />
+
+    <persistence:managed-persistence-context name="entityManager"
+                                             auto-create="true"
+                                             persistence-unit-jndi-name="java:/seampayEntityManagerFactory" />
+
+    <async:timer-service-dispatcher />
+    <component class="org.jboss.seam.async.ThreadPoolDispatcher" precedence="40" /> 
+
+    <core:init debug="true" jndi-pattern="jboss-seam-pay/#{ejbName}/local" />
+
+</components>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seam.properties
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seam.properties	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seam.properties	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,3 @@
+#debug is explicitly disabled in test to avoid JBIDE-3623
+#Thu Dec 31 16:24:37 CET 2009
+org.jboss.seam.core.init.debug=false
\ No newline at end of file

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seampay.properties
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seampay.properties	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seampay.properties	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,32 @@
+ #
+ # JBoss, Home of Professional Open Source
+ # Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ # by the @authors tag. See the copyright.txt in the distribution for a
+ # full listing of individual contributors.
+ #
+ # This is free software; you can redistribute it and/or modify it
+ # under the terms of the GNU Lesser General Public License as
+ # published by the Free Software Foundation; either version 2.1 of
+ # the License, or (at your option) any later version.
+ #
+ # This software is distributed in the hope that it will be useful,
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ # Lesser General Public License for more details.
+ #
+ # You should have received a copy of the GNU Lesser General Public
+ # License along with this software; if not, write to the Free
+ # Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ # 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ # 
+MAIN_PAGE = /search.seam
+MAIN_PAGE_TITLE = Seam Pay
+ACCOUNT_TABLE_LINK = id=accountTable:{0}:link
+ACCOUNT_TABLE_BALANCE = id=accountTable:{0}:balance
+PAYMENT_TO_FIELD = id=accountView:paymentForm:payee
+PAYMENT_AMOUNT_FIELD = id=accountView:paymentForm:amount
+PAYMENT_ONLY_ONCE_RADIO = id=accountView:paymentForm:radioList:0
+PAYMENT_EVERY_MINUTE_RADIO = id=accountView:paymentForm:radioList:1
+PAYMENT_SUBMIT = id=accountView:paymentForm:submit
+PAYMENT_CONFIRMATION_MESSAGE = Created a new payment to {0}
+PAYMENTS_COUNT =//table[@id\='payments']/tbody/tr
\ No newline at end of file


Property changes on: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources/seampay.properties
___________________________________________________________________
Added: svn:executable
   + *

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-ftest/testng.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-ftest/testng.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-ftest/testng.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,30 @@
+<!--
+JBoss, Home of Professional Open Source
+Copyright 2008, Red Hat Middleware LLC, and individual contributors
+by the @authors tag. See the copyright.txt in the distribution for a
+full listing of individual contributors.
+
+This is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as
+published by the Free Software Foundation; either version 2.1 of
+the License, or (at your option) any later version.
+
+This software is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this software; if not, write to the Free
+Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+02110-1301 USA, or see the FSF site: http://www.fsf.org.
+--> 
+<!DOCTYPE suite SYSTEM "http://beust.com/testng/testng-1.0.dtd" >
+<suite name="Seampay example" verbose="2" parallel="false">
+   <test name="seampay_tests">
+      <parameter name="PROPERTY_FILE" value="/seampay.properties" />
+         <classes>
+         <class name="org.jboss.seam.example.common.test.seampay.selenium.PaymentTest" />
+      </classes>
+   </test>
+</suite>


Property changes on: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-ftest/testng.xml
___________________________________________________________________
Added: svn:executable
   + *

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-integration/testng.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-integration/testng.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-tests/src/test/resources-integration/testng.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,12 @@
+<!DOCTYPE suite SYSTEM "http://beust.com/testng/testng-1.0.dtd" >
+
+<suite name="seampay" verbose="2" parallel="false">
+	<test name="seampay">
+		<classes>
+			<class
+				name="org.jboss.seam.example.seampay.test.PaymentProcessorTest" />
+			<class
+				name="org.jboss.seam.example.seampay.test.AccountTest" />
+		</classes>
+	</test>
+</suite>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/pom.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/pom.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/pom.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,154 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <artifactId>seampay</artifactId>
+        <groupId>org.jboss.seam.examples-ee6</groupId>
+        <version>2.3.0.Beta2-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+    
+    <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+    <artifactId>seampay-web</artifactId>
+    <packaging>war</packaging>
+    <name>Seampay Web Module (EE6)</name>
+    
+    <properties>
+        <!-- filtering property for components.xml -->
+        <jndiPattern>java:app/seampay-ejb/#{ejbName}</jndiPattern>
+    </properties>
+    
+    <dependencies>
+        <dependency>
+            <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+            <artifactId>seampay-ejb</artifactId>
+            <type>ejb</type>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.seam</groupId>
+            <artifactId>jboss-seam</artifactId>
+            <type>ejb</type>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.seam</groupId>
+            <artifactId>jboss-seam-ui</artifactId>
+            <exclusions>
+                <exclusion>
+                    <groupId>org.jboss.seam</groupId>
+                    <artifactId>jboss-seam-jul</artifactId>
+                </exclusion>
+                <exclusion>
+                    <groupId>commons-beanutils</groupId>
+                    <artifactId>commons-beanutils</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.seam</groupId>
+            <artifactId>jboss-seam-debug</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.richfaces.ui</groupId>
+            <artifactId>richfaces-components-ui</artifactId>
+        </dependency>  
+        <dependency>
+            <groupId>org.richfaces.core</groupId>
+            <artifactId>richfaces-core-impl</artifactId>
+        </dependency>     
+    
+    </dependencies>
+  
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-war-plugin</artifactId>
+                <configuration>
+                    <webResources>
+                        <resource>
+                            <directory>src/main/webapp</directory>
+                            <filtering>true</filtering>
+                        </resource>
+                    </webResources>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+    
+    <profiles>
+        <profile>
+            <id>tomcat</id>
+            <properties>
+                <!-- filtering property for components.xml -->
+                <jndiPattern>#{ejbName}/local</jndiPattern>
+            </properties>
+            <dependencies>
+                <dependency>
+                    <groupId>org.jboss.seam.examples-ee6.seampay</groupId>
+                    <artifactId>seampay-ejb</artifactId>
+                    <type>ejb</type>
+                    <scope>compile</scope>
+                </dependency>
+                <dependency>
+                    <groupId>org.jboss.seam</groupId>
+                    <artifactId>jboss-seam</artifactId>
+                    <type>ejb</type>
+                    <scope>compile</scope>
+                    <exclusions>
+                        <exclusion>
+                            <groupId>com.thoughtworks.xstream</groupId>
+                            <artifactId>xstream</artifactId>
+                        </exclusion>
+                        <exclusion>
+                            <groupId>xpp3</groupId>
+                            <artifactId>xpp3_min</artifactId>
+                        </exclusion>
+                    </exclusions>
+                </dependency>
+                <dependency>
+                    <groupId>javax.faces</groupId>
+                    <artifactId>jsf-api</artifactId>
+                    <scope>compile</scope>
+                </dependency>
+                <dependency>
+                    <groupId>javax.faces</groupId>
+                    <artifactId>jsf-impl</artifactId>
+                    <scope>compile</scope>
+                </dependency>
+                <dependency>
+                <groupId>commons-digester</groupId>
+                <artifactId>commons-digester</artifactId>
+                    <exclusions>
+                        <exclusion>
+                            <groupId>commons-collections</groupId>
+                            <artifactId>commons-collections</artifactId>
+                        </exclusion>
+                    </exclusions>
+                </dependency>
+                <dependency>
+                    <groupId>org.richfaces.framework</groupId>
+                    <artifactId>richfaces-api</artifactId>
+                    <exclusions>
+                        <exclusion>
+                            <groupId>commons-collections</groupId>
+                            <artifactId>commons-collections</artifactId>
+                        </exclusion>
+                        <exclusion>
+                            <groupId>commons-beanutils</groupId>
+                            <artifactId>commons-beanutils</artifactId>
+                        </exclusion>
+                    </exclusions>
+                </dependency>
+                <dependency>
+                    <groupId>javax.servlet</groupId>
+                    <artifactId>jstl</artifactId>
+                </dependency>
+            </dependencies>
+            <build>
+                <finalName>jboss-seam-seampay</finalName>
+            </build>
+        </profile>
+    </profiles>
+    
+</project>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/components.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/components.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/components.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,46 @@
+<components xmlns:pay="http://jboss.com/products/seam/examples/seampay"
+            xmlns:core="http://jboss.com/products/seam/core"
+            xmlns:persistence="http://jboss.com/products/seam/persistence"
+            xmlns:framework="http://jboss.com/products/seam/framework"
+            xmlns:async="http://jboss.com/products/seam/async"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation=
+                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.3.xsd
+                 http://jboss.com/products/seam/persistence http://jboss.com/products/seam/persistence-2.3.xsd
+                 http://jboss.com/products/seam/async http://jboss.com/products/seam/async-2.3.xsd
+                 http://jboss.com/products/seam/framework http://jboss.com/products/seam/framework-2.3.xsd" >
+
+    <pay:payment-home 
+                       new-instance="#{newPayment}" 
+                      created-message="Created a new payment to #{newPayment.payee}" />
+
+
+    <pay:payment name="newPayment" 
+                 payee="Somebody"
+                 account="#{selectedAccount}"
+                 payment-date="#{currentDatetime}"
+                 created-date="#{currentDatetime}" />
+
+    <factory name="selectedAccount" 
+             value="#{accountHome.instance}"/>
+
+    <framework:entity-home name="accountHome" 
+                           entity-class="org.jboss.seam.example.seampay.Account"
+                           entity-manager="#{entityManager}" />
+
+    <framework:entity-query name="accounts" 
+                            ejbql="from Account"
+                            order="accountNumber" 
+                            max-results="20" 
+                            entity-manager="#{entityManager}" />
+
+    <persistence:managed-persistence-context name="entityManager"
+                                             auto-create="true"
+                                             persistence-unit-jndi-name="java:/seampayEntityManagerFactory" />
+
+    <async:timer-service-dispatcher />
+    <component class="org.jboss.seam.async.ThreadPoolDispatcher" precedence="40" /> 
+
+    <core:init debug="true" jndi-pattern="@jndiPattern@" />
+
+</components>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/faces-config.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/faces-config.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/faces-config.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<faces-config version="2.1"
+              xmlns="http://java.sun.com/xml/ns/javaee"
+              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+              xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_2_1.xsd">
+
+</faces-config>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/pages.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/pages.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/pages.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<pages xmlns="http://jboss.com/products/seam/pages"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://jboss.com/products/seam/pages http://jboss.com/products/seam/pages-2.3.xsd">
+
+   <page view-id="/search.xhtml">
+          <param name="accountId" value="#{accountHome.id}" converterId="javax.faces.Long" />
+          <navigation>
+          	<rule if-outcome="persisted">
+          		<render/>
+          	</rule>
+          </navigation>
+   </page>
+</pages>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/web.xml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/web.xml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/WEB-INF/web.xml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app version="3.0" 
+         xmlns="http://java.sun.com/xml/ns/javaee"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
+    
+    <listener>
+        <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
+    </listener>
+    
+    <filter>
+        <filter-name>Seam Filter</filter-name>
+        <filter-class>org.jboss.seam.servlet.SeamFilter</filter-class>
+    </filter>
+
+    <filter-mapping>
+        <filter-name>Seam Filter</filter-name>
+        <url-pattern>/*</url-pattern>
+    </filter-mapping>
+        
+    <servlet>
+      <servlet-name>Seam Resource Servlet</servlet-name>
+      <servlet-class>org.jboss.seam.servlet.SeamResourceServlet</servlet-class>
+    </servlet>
+    
+    <servlet-mapping>
+      <servlet-name>Seam Resource Servlet</servlet-name>
+      <url-pattern>/seam/resource/*</url-pattern>
+    </servlet-mapping>     
+
+    <context-param>
+        <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
+        <param-value>.xhtml</param-value>
+    </context-param>
+
+    <context-param>
+        <param-name>facelets.DEVELOPMENT</param-name>
+        <param-value>true</param-value>
+    </context-param>
+    
+    <servlet>
+        <servlet-name>Faces Servlet</servlet-name>
+        <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
+        <load-on-startup>1</load-on-startup>
+    </servlet>
+    
+    <servlet-mapping>
+        <servlet-name>Faces Servlet</servlet-name>
+        <url-pattern>*.seam</url-pattern>
+    </servlet-mapping>
+    
+    <session-config>
+        <session-timeout>10</session-timeout> 
+    </session-config>     
+</web-app>

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/date.css
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/date.css	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/date.css	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,184 @@
+div.seam-date 
+{
+  margin-top: 5px;
+  border: 1px solid #AAAAAA;
+  background-color: #FFFFFF;  
+  color: #505050;
+  font-family: Tahoma, Arial, Helvetica, sans-serif;
+  font-size: 12px;
+}
+
+table.seam-date td {
+  font-family: Tahoma, Arial, Helvetica, sans-serif;
+  font-size: 11px; 
+}
+
+.seam-date-monthNames
+{
+  width: 70px;
+  border: 1px solid #dddddd;
+  border-right: 3px solid #444444;
+  border-bottom: 3px solid #444444;
+  background-color: #ffffff; 
+  font-size: 12px;
+  cursor: pointer;	
+  font-family: Tahoma, Arial, Helvetica, sans-serif;
+  font-weight: normal;
+}
+
+a.seam-date-monthNameLink, a.seam-date-monthNameLink:visited
+{
+  text-align: center;
+  display: block;
+  color: #555555;  
+}
+
+a.seam-date-monthNameLink:hover
+{ 
+  background-color: #CCCCCC;
+  color: red;  
+}
+
+.seam-date-years
+{
+  height: 10em;
+  overflow: auto;
+  width: 60px;
+  border: 1px solid #dddddd;
+  border-right: 3px solid #444444;
+  border-bottom: 3px solid #444444;
+  background-color: #ffffff; 
+  font-size: 12px;
+  cursor: pointer;	
+  font-family: Tahoma, Arial, Helvetica, sans-serif;
+  font-weight: normal;
+}
+
+a.seam-date-yearLink, a.seam-date-yearLink:visited
+{
+  text-align: center;
+  display: block;
+  color: #555555;    
+}
+
+a.seam-date-yearLink:hover
+{
+  background-color: #CCCCCC;
+  color: red;    
+}  
+
+tr.seam-date-header
+{
+  padding: 2px 0px 2px 0px;
+}
+  
+td.seam-date-header
+{
+  padding: 0px 8px 0px 8px;
+  text-align: center;
+  color: gray;
+  font-family: Tahoma, Arial, Helvetica, sans-serif;
+  font-weight: bold;
+  font-size: 12px;  
+}
+
+td.seam-date-header-prevMonth
+{
+  background-image: url("./img/cal-prev.png");
+  background-repeat: no-repeat;
+  background-position: center;
+  padding: 0px 2px 0px 2px;
+  width: 17px;
+  height: 16px;
+  margin-left: 2px;
+}
+
+td.seam-date-header-nextMonth
+{
+  background-image: url("./img/cal-next.png");
+  background-repeat: no-repeat;
+  background-position: center;
+  padding: 0px 2px 0px 2px;
+  width: 17px;
+  height: 16px;
+  margin-right: 2px;
+}
+
+tr.seam-date-headerDays
+{
+  color: white;
+  font-weight: normal;
+}
+
+tr.seam-date-headerDays > td
+{
+  background-color: #CCCCCC;
+  border: 1px solid #AAAAAA;
+  color: white;
+  text-align: center;
+  width: 26px;   
+}
+
+tr.seam-date-footer
+{
+  background-color: white; 
+  color: #505050;
+  font-weight: bold;
+}
+
+tr.seam-date-footer > td
+{
+  text-align: center;
+}
+
+td.seam-date-inMonth
+{
+  background-color: white; 
+  color: black;
+  font-weight: normal;
+  cursor: pointer;
+  border: 1px solid #ece9d8;
+}
+
+td.seam-date-outMonth
+{
+  background-color: white; 
+  color: #999999;
+  font-weight: normal;
+  cursor: pointer;
+  border: 1px solid #ece9d8;
+}
+
+td.seam-date-selected
+{
+  background-color: #CCCCCC;        
+  border: 1px solid #AAAAAA; 
+  color: black;
+  font-weight: normal;
+}
+
+td.seam-date-dayOff-inMonth
+{
+  background-color: #efefef;
+  color: black;
+  font-weight: normal;
+  cursor: pointer;
+  border: 1px solid #ece9d8;
+}
+
+td.seam-date-dayOff-outMonth
+{
+  background-color: #efefef;
+  color: #999999;
+  font-weight: normal;
+  cursor: pointer;
+  border: 1px solid #ece9d8;
+}
+
+td.seam-date-hover 
+{
+  background-color: #CCCCCC;
+  border: 1px solid #AAAAAA;
+  cursor: pointer;
+  color: red;
+}
\ No newline at end of file

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/cal-next.png
===================================================================
(Binary files differ)


Property changes on: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/cal-next.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/cal-prev.png
===================================================================
(Binary files differ)


Property changes on: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/cal-prev.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/dtpick.gif
===================================================================
(Binary files differ)


Property changes on: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/img/dtpick.gif
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/index.html
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/index.html	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/index.html	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,5 @@
+<html>
+<head>
+  <meta http-equiv="Refresh" content="0; URL=search.seam">
+</head>
+</html>
\ No newline at end of file

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/screen.css
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/screen.css	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/screen.css	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,145 @@
+a:active, a:link, a:visited {
+	color: #0D5798;    
+}
+a:hover {
+	color: #8CAFCD;
+}
+
+.menuButtons {
+	background-color: #FF6600; /*#8CAFCD*/
+	padding-top: 10px;
+	padding-bottom: 10px;
+}
+.menuButtons a {
+    font-weight: bold;
+    text-decoration: none;
+	padding-left: 25px;
+	padding-right: 25px;
+}
+.menuButtons a:active, .menuButtons a:link, .menuButtons a:visited {
+	font-family: Arial,sans-serif;
+	background-color: #FF6600; /*#8CAFCD*/
+	color: white;
+	border-right: 1px solid white;
+}
+.menuButtons a:hover {
+	font-family: Arial,sans-serif;
+    background-color: white;
+    color: #FF6600; /*#8CAFCD*/
+}
+
+.actionButtons {
+	width: 100%;
+	text-align: center;
+	padding-top: 10px;
+}
+.tableControl {
+	width: 100%;
+	text-align: right;
+	padding-top: 15px;
+}
+.actionButtons a, .tableControl a {
+	font-family: Arial,sans-serif;
+	font-weight: bold;
+	color: #578BB8;
+	border: 1px solid #578BB8;
+	text-decoration: none;
+	padding: 5px;
+	margin: 5px;
+}
+.actionButtons a:hover, .tableControl a:hover {
+	color: white;
+	background-color: #578BB8;
+	margin: 5px;
+}
+
+h1 {
+	font-family: Arial,sans-serif;
+	color: #578BB8;
+	font-size: 1.6em;
+	margin-top: 0;
+}
+
+body {
+	margin: 0px;
+	font-family: Arial,sans-serif;
+	color: #616161;
+}
+
+.body {
+	padding: 30px;
+}
+
+
+table.results {
+	width: 100%;
+}
+
+table.results th {
+	background-color: #578BB8;
+	color: white;
+	font-family: Arial,sans-serif;
+	padding: 5px;
+	
+}
+
+table.results td {
+	background-color: #F0F0F0;
+	text-align: center;
+}
+
+.narrow {
+	width: 20%;
+}
+.wide {
+	width: 80%;
+}
+
+.first td {
+	background-color: #F0F0F0;
+}
+
+.second td {
+	background-color: white;
+}
+
+.dialog 
+{
+	padding: 15px;
+	background-color: #F0F0F0;
+	margin: 10px;	
+}
+.dialog table
+{
+	width: auto;
+}
+
+.message {
+	border: 1px solid #FFCC00;
+	padding: 5px;
+	margin-top: 5px;
+	margin-bottom: 5px;
+	background-color: #F0F0F0;
+}
+
+.prop {
+	padding: 5px;
+}
+.prop .name {
+	font-weight: bold;
+	text-align: left;
+	width: 115px;
+}
+.prop .value {
+	text-align: left;
+}
+.prop .errors {
+	color: red;
+	text-align: left;
+}
+.value input {
+	width:190px;
+}
+.errors input {
+	border: 1px solid red;
+}

Added: branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/search.xhtml
===================================================================
--- branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/search.xhtml	                        (rev 0)
+++ branches/community/Seam_2_3/examples-ee6/seampay/seampay-web/src/main/webapp/search.xhtml	2012-04-02 10:17:17 UTC (rev 14460)
@@ -0,0 +1,158 @@
+<!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:ui="http://java.sun.com/jsf/facelets"
+      xmlns:h="http://java.sun.com/jsf/html"
+      xmlns:f="http://java.sun.com/jsf/core"
+      xmlns:s="http://jboss.com/products/seam/taglib"
+      xmlns:rich="http://richfaces.org/rich"
+      template="template.xhtml">
+<h:head>
+    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
+    <title>Seam Pay</title>
+    <link href="screen.css" rel="stylesheet" type="text/css" />
+    <link href="date.css" rel="stylesheet" type="text/css" />
+</h:head>
+<body>
+      
+    <div class="menuButtons">
+        <s:link view="/search.xhtml" value="Show Accounts"/>
+    </div>
+    
+    <div class="body">        
+        <h1>Account</h1>
+        
+        <h:messages styleClass="message"/>
+
+
+        <!-- search results -->
+        <table class="results">
+            <tr>
+                <th>Id</th>
+                <th>Account Number</th>
+                <th>Balance</th>
+            </tr>
+            <ui:repeat id="accountTable" value="#{accounts.resultList}" var="account">
+                <tr>
+                    <td>
+                        <s:link id="link" view="/search.xhtml" value="#{account.id}">
+                            <f:param name="accountId" value="#{account.id}"/>
+                        </s:link>
+                    </td>
+                    <td>#{account.accountNumber}</td>
+                    <td>
+                        <h:outputText id="balance" value="#{account.balance}">
+                            <f:convertNumber type="currency" currencySymbol="$"/> 
+                        </h:outputText>
+                    </td>
+                </tr>
+          </ui:repeat>
+        </table>
+        <h:outputText value="No accounts found" rendered="#{empty accounts.resultList}" styleClass="message"/>
+        
+
+        <f:subview id="accountView" rendered="#{accountHome.idDefined}">
+            <h2>Payments from Account #{accountHome.instance.accountNumber}</h2>
+            <table id="payments" class="results">
+                <thead>
+                	<tr>
+	                    <th>Status</th>
+	                    <th>Payee</th>
+	                    <th>Payment Amount</th>
+	                    <th>Created Date</th>
+	                    <th>Scheduled Date</th>
+	                    <th>Frequency</th>
+	                    <th>Last Paid On</th>
+	                </tr>
+	            </thead>
+	            <tbody>
+	                <ui:repeat value="#{accountHome.instance.payments}" var="payment">
+	                    <tr>
+	                        <td>
+	                            <s:button action="#{paymentHome.cancel}" value="Cancel" rendered="#{payment.active}">
+	                                <f:param name="paymentId" value="#{payment.id}"/>
+	                            </s:button>
+	                            <h:outputText value="not active" rendered="#{!payment.active}" />
+	                        </td>                            
+	                        <td>#{payment.payee}</td>
+	                        <td>
+	                            <h:outputText value="#{payment.amount}">
+	                                <f:convertNumber type="currency" currencySymbol="$"/> 
+	                            </h:outputText>
+	                        </td>
+	                        <td>
+	                            <h:outputText value="#{payment.createdDate}">
+	                                <f:convertDateTime type="date" dateStyle="medium" />
+	                            </h:outputText>
+	                        </td>
+	                        <td>
+	                            <h:outputText value="#{payment.paymentDate}">
+	                                <f:convertDateTime type="date" dateStyle="medium" />
+	                            </h:outputText>
+	                        </td>
+	                        <td>#{payment.paymentFrequency}</td>
+	                        <td>
+	                            <h:outputText value="#{payment.lastPaid}">
+	                                <f:convertDateTime type="date" dateStyle="medium" />
+	                            </h:outputText>
+	                        </td>
+	                    </tr>
+	                </ui:repeat>
+	        	</tbody>
+            </table>
+
+            <h2>Make a payment from account #{accountHome.instance.accountNumber}:</h2>
+            <h:form id="paymentForm">
+                <s:validateAll>
+                    <table>
+                        <tr>
+                            <td>To:</td>
+                            <td>
+                                <h:inputText id="payee" value="#{newPayment.payee}" required="true"/>
+                            </td>
+                        </tr>
+                        <tr>
+                            <td>Amount:</td>
+                            <td><h:inputText id="amount" value="#{newPayment.amount}" required="true">
+                                <ui:remove>
+                                    <f:convertNumber type="currency" currencySymbol="$"/> 
+                                </ui:remove>
+                            </h:inputText></td>
+                        </tr>
+                        <tr>
+                            <td>Date:</td>
+                            <td>
+                                <rich:calendar id="paymentDate" value="#{newPayment.paymentDate}" required="true" datePattern="MM/dd/yyyy"  />
+                                <h:message for="paymentDate" />
+                            </td>
+                        </tr>
+
+                        <tr>
+                            <td>Frequency:</td>
+                            <td>
+                                <h:selectOneRadio id="radioList" 
+                                                  layout="lineDirection"
+                                                  value="#{newPayment.paymentFrequency}">
+                                    <s:convertEnum />
+                                    <s:enumItem id="once" enumValue="ONCE"         label="Only Once" />
+                                    <s:enumItem id="everyMinute" enumValue="EVERY_MINUTE" label="Every Minute (testing)" />
+                                    <s:enumItem id="hourly" enumValue="HOURLY"       label="Every Hour (testing)" />
+                                    <s:enumItem id="daily" enumValue="DAILY"        label="Every Day" />
+                                    <s:enumItem id="weekly" enumValue="WEEKLY"       label="Every Week" />
+                                    <ui:remove>
+                                        <f:selectItems value="#{newPayment.frequencies}" />
+                                    </ui:remove>
+                                </h:selectOneRadio>
+                            </td>
+                        </tr>
+                    </table>
+                </s:validateAll>
+                
+                <h:commandButton id="submit" value="Schedule" 
+                                 action="#{paymentHome.saveAndSchedule}" />
+            </h:form>
+        </f:subview>
+
+    </div>
+    
+</body>
+</html>



More information about the seam-commits mailing list