This content has been marked as final.
Show 1 reply
-
1. Re: Remote Persistence Seam
vladomega May 20, 2009 8:08 PM (in response to vladomega)
Vlad Ionescu wrote on May 20, 2009 20:07:
Hi.
I have a button in a .xhtml file which calls a javascript function which calls a java function remotely (in jboss seam environment). That java function has an entityManager.persist(object). Do you know why this line of code doesn't commit to the DB? It says something that a transaction hasn't started. I supose in a remote context i don't have a transaction began because if i put an action on that button which calls the same java function instead of using javascript intermediar function above, it works fine; entityManager persists the object and i can see it in the DB.
Does anyone has any ideas how could i make to actually persist the object using javascript to call the java function? (i have to use javascript because i need the callback function in order to give the client a message likeThe user has been saved
or something like this).
The entityManager is declared like this: @In EntityManager entityManager.Click HELP for text formatting instructions. Then edit this text and check the preview.