Support

Home Forums Event Espresso Premium Ticket Price Based on Payment Option?

Ticket Price Based on Payment Option?

Posted: November 28, 2015 at 4:22 pm

Viewing 6 reply threads


Dallas REIG

November 28, 2015 at 4:22 pm

Is there a way(action or something) to modify the ticket prices based on the payment method?

I understand that the tickets will show a price initially because tickets are chosen before the payment method is chosen, but I would like to modfy the ticket price if a particular payment option is chosen.

For clarity, I have two payment options, 1) Credit Card and 2)Pay at the Door (Invoice). If the Pay at the Door option is chosen I want to increase the ticket price, is this possible?


Lorenzo Orlando Caum

  • Support Staff

November 29, 2015 at 2:16 pm

Hi Maceo,

You could create different ticket options with different pricing and those will be available through the ticket selector for registration.


Lorenzo


Dallas REIG

November 29, 2015 at 2:49 pm

Thanks for your response Lorenzo but that does not work unless you are saying I can create different tickets that will show up based on the payment method (which i do not see how that could be since payment is last). Creating multiple tickets does no good cause my customer can just choose the cheaper ticket and select pay at the door anyway.

So back to my original question, is there an action or something i can hook into to increase the price if a certain payment method is selected?

Thanks again.


Brent Christensen

  • Support Staff

November 30, 2015 at 12:19 pm

Hi Maceo,

I’m Event Espresso’s lead developer. What you are asking sounds similar to other requests that we have been asked for in the past and have added to our feature backlog. There are currently many other more highly requested features ahead of it on our roadmap, so it won’t be getting work on anytime soon.

If this is something that you absolutely require, then you will need to hire a developer to add this functionality for you.

Here are some recommendations and suggestions to get you pointed in the right direction.

* instead of modifying the ticket prices based on the selected payment method of payment, I would simply add a surcharge to the cart total. This would work best as a % modifier. I would then add a note regarding your % surcharge to the Invoice Description, and possibly to the Extra Info as well on the Event Espresso – Payment Methods admin page for the Invoice payment method.

* in order to apply the % surcharge to your cart total, it would be best for your developer to hook into the AHEE__Single_Page_Checkout__before_payment_options__process_reg_step action to do so. That hook point passes a copy of the payment options registration step object, which includes references to the cart and transaction objects, both of which would need to be modified. I’ve created a code snippet that does this in a very basic way that could be used as a starting point. Please see:

https://github.com/eventespresso/ee-code-snippet-library/blob/master/checkout/bc_add_cart_modifier.php

Hope that helps


Dallas REIG

November 30, 2015 at 2:24 pm

Thanks Brent, that looks like it will do well for my needs. I appreciate it!


Dallas REIG

November 30, 2015 at 2:35 pm

I see the code provided does this by adding a percentage amount. Can you tell me what I need to do to add a dollar amount instead of percentage.

It appears $success = EEH_Line_Item::add_percentage_based_item( needs to be changed. I tried $success = EEH_Line_Item::add_dollar_based_item( but this failed.

Thanks again.


Dallas REIG

November 30, 2015 at 3:09 pm

I didn’t see any dollar based function in the EEH_Line_Item helper file, so I just calculated the percentage needed to reach the dollar amount I wanted to add.

Thanks for your help!

Viewing 6 reply threads

The support post ‘Ticket Price Based on Payment Option?’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso