[jboss-user] [JBoss Seam] - Seam and events (really dumb one)
viniciuscarvalho
do-not-reply at jboss.com
Wed Mar 28 18:01:19 EDT 2007
Ok, this might the the dumbest question I've ever asked. But I'm really stuck on this.
I have other seam projects, (none using facelets tough) and they work fine.
So I have this project: I used seam-gen to create the artifacts. I have one simple SLSB
| @Stateless
| @Name("customerManager")
| public class CustomerManagerBean implements CustomerManager {
|
| @In @Out
| private Customer customer
| @PersistenceContext(unitName="CustomerContext")
| private EntityManager em;
|
| public String register() {
| em.persist(customer);
| return null;
| }
| }
|
| @Name("customer")
| @Entity
| public class Customer implements Serializable{
| @NotNull
| private String getName()...
| }
|
| and finally my xhtml page:
|
| <ui:define name="content">
| <h:form>
| <h:messages globalOnly="true"/>
| <s:decorate template="edit.xhtml">
| <ui:define name="label">Name </ui:define> : <h:inputText value="#{customer.name}" size="15" required="true"/><br/>
| </s:decorate>
| <s:decorate template="edit.xhtml">
| <ui:define name="label">Phone </ui:define>: <h:inputText value="#{customer.phone}" size="8"/><br/>
| </s:decorate>
| <h:commandButton type="submit" value="Register" action="#{customerManager.register}"/>
| </h:form>
| </ui:define>
|
As you can see, simpler is impossible. Hitting the Register command button does not trigger the method...
I'm really embarrassed of how could a simple thing like this get me stuck... So I come here to call for help :(
Anyone have a clue of what's missing?
Best regards, and really sorry about the dumb question
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4032562#4032562
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4032562
More information about the jboss-user
mailing list