1
Answers
Vote up!
0
Vote down!

Custom Line Item and Pricing Rules

Custom Line Item and Pricing Rules

I have a project were the client wants to sell tickets to an event. There are three different versions of these tickets at three different price points:

dinner and concert ticket - $75
concert ticket - $15
concert ticket (family pass) - $30

The site is designed to use a fast checkout type of setup with a single form once the add to cart button is selected. Using rules the user goes directly to the checkout form.

Using the editablefields module and the commerce custom product module I was able to create a custom line item where the user can choose the ticket type from a select list. (another related problem is that the editable field doesn't appear to anonymous users)

I created a product pricing rule that looks at the ticket type select value and then updates the unit price.

The problem is it works the first time the product is added to the cart, but if the user changes the custom line item, it doesn't dynamically update the unit price. My gut feeling is that I need to find another trigger event because "Calculating the sell price of a product" does't seem to fire when changing the custom line item list. Is there something else I'm missing? Changing the quantity amount at the line item level doesn't dynamically change the total either. I want to be able to have the user select the ticket type and have the unit price and total change dynamically and have them change the quantity to have the total change dynamically.

Any help would be greatly appreciated.

Thanks in Advance

Asked by: denpub
on September 7, 2012

1 Answer

Vote up!
1
Vote down!

From you description I think you would be better using different multiple products for each event and then adding them all the the event product display, rather than trying to use the custom line item.

This would then react to the changes to re-calculate the prices.

David Kitchen
Answer by: David Kitchen
Posted: Nov 13, 2012