I have written some register user stuff similarto how it was done in the registration example.
No I have two questions:
When I revisit my register.xhtml page AFTER Ihave registered a user all fields are populatedwith the previous registration values.
1. I guess because User.java uses @Scope(SESSION)?
So when I press the submit button again I get the
org.hibernate.PersistentObjectException: detached entity passed to persist
2. Is that because the same user entity is attempt to be persisted again?
Any suggestions how to solve this problem nicely?Can I invalidate or reset the user enity somehowwhen the register.xhtml page is revisited?
Or should I change the @Scope to page context?
Please let me know what a good design would be.
Retrieving data ...