Joined: Sat Jan 23, 2010 4:38 am Posts: 5
|
Hi Experts,
Click on "Save" button shows the same page without saving the data on database. Please help.
My web page source is as follows (JSF code): <h:form> <h:panelGrid border="1" columns="2"> <h:outputLabel value="Task: "></h:outputLabel> <h:inputText value="#{projectBean.PName}""></h:inputText> <h:outputLabel value="Status: "></h:outputLabel> <h:selectOneMenu binding="#{statusBean.statusList}" value="#{projectBean.PSCode}""></h:selectOneMenu> <h:outputLabel value="Commencement (Date): "></h:outputLabel> <h:inputText value="#{projectBean.PCommDate}""></h:inputText> </h:panelGrid> <h:commandButton value="Save" actionListener="#{projectBean.save}"></h:commandButton> </h:form>
My hibernate save method is as follows:
... session.beginTransaction(); session.saveOrUpdate(projectInstance); session.getTransaction().commit(); ...
|
|