| Madhuri,
When you add any product it is added to the shopping cart object. This object is exists in the session, when ever we need it we get it from the session. when session expires shopping cart object gets remove from the session, and thats why we can't ger any product in the cart.
comment inline :- On Jul 27, 2008, at 3:08 PM, Madhuri wrote:
Hi All - In my application, I have items that require quantity (1,2,3 etc...) and some of them require weight (0.5Kg, 2.3Kg etc....) as input. I have used the default implementation that ofbiz provides and it works perfectly fine. The only problem I have is when the session expires, the shopping cart losses the amount value and it is defaulted to '1'. So for example, if I enter 0.75 as weight, add the item to the cart and then come back to the cart after the session expires,
When session expires your product is no more available. it is defaulted to 1.
When product is not exists, there fore when you back to the cart after session expires, you can't get the product again, I can't guess how you get value 1.
Why shopping cart object kept in session : The idea is : When user enter in the ecomerce for shopping he get a session. And he need to do shopping within session remains. And if session expire it means that user leave the shopping and exit form the Mall (  ), and no more product is available for the shopping. And if he want to continue the shopping then he need to go the mart again and start the shopping from 0. I could not figure out how to fix the code such that the shopping cart retains the weight on session expiry. Any help is appreciated.
Do you have any memory which remains in existence after session expiration. If you have then you can put the cart object there, and access it from the same place.
Thanks Sumit Pandit |