1
Answers
Vote up!
0
Vote down!

Single price for n products

I need to set a single price (not a price per item) for any number of a given product.
That is to say, the first one is $1 and any more are free.
1 product = $1
2 products = $1
10 products = $1

Commerce Price Table isn't helping - it will set the price of all items to the same value based on quantity, but what I want is for the first to cost $1 and all subsequent ones to be free (two separate prices, in effect).

Any ideas appreciated.

Asked by: Sam Moore
on May 6, 2013

1 Answer

Vote up!
0
Vote down!

What I would probably do is build a new rule with an event of "Before saving a commerce line item". You can then add in whatever conditions you want to restrict it down to products of a certain type or with a certain field. For the action you would "Divide the unit price by some amount" and instead of using a fixed amount point the data selector to the quantity on the line item.

Answer by: DaveP
Posted: May 13, 2013