Post by alexmitev » Thu Feb 17, 2011 8:48 pm

Hello,
I want to update the data['shipping_methods'] and data['shipping_method'] after each product add, remove, user logon, user address change, etc. The reason I want this is, because the shipping depends on cart sub-total, as well as on user zone, and I want to display the shipping cost in the cart according to current user zone-id, and update the cost accordingly to cart sub-total.
So, my question is WHERE to put the code? I guess the Cart class is not the best place, as I have to use some code from model, which no class in System does. Still, I want the code to be just in one place, so maybe the controller is not the best place for this?
Anyone can give an advice for the right place in the architecture?

Alex

New member

Posts

Joined
Wed Jan 19, 2011 10:38 pm
Who is online

Users browsing this forum: Bing [Bot] and 41 guests