Jump to content

1.6.1.7 action hooks


arianacri

Recommended Posts

We implemented a new module for prestashop, where you can add products for persons. A user can place an order for 1..n persons. To difference products, we added a person_id column on cart_product table.


The problem appeared when we tried to use price_rules, and specific when we tried to give one gift for each person because the rules are applied only one time per cart, but we want to apply one time per person.


  1. Is there a way to add multiple gifts per cart?
  2. How can I catch the exact moment when a product is added to cart by the user?
Link to comment
Share on other sites

If you mean the same cart has the same product 2 times, one for each person, then you have to edit the CartRule class to treat them as 2 different entities. Pretty hard mod
To catch the add to cart you can check Cart::updateQty

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...