I think the issue is because mOrder is not connected to the hibernate
session.

It looks like you are only saving the entity when the user clicks "accept".
I'm guessing that at some stage before you are submitting a form and
storing mOrder on the HttpSession?

If I were you, I'd try to remove HttpSession usage completely. Is it
possible to do 2 saves to the database with different states (perhaps
"saved" then "accepted")

If you still really want to use the HttpSession, you'll need to attach
mOrder to the current hibernate session before saving. This can be done via
session.merge(mOrder);

Reply via email to