Price modifier per Payment option

  • Dycon
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
12 years 4 months ago #36207 by Dycon
Price modifier per Payment option was created by Dycon
Hello everyone....
Hi Tuan...

I need to achieve the following:
Each event has a price, users can chose what payment method to use to make a payment for the event...

I need to add a % amount to each payment method...

Event 1 , Cost $10.00
Payment Method
PayPal 1: + 2% TAX(2 payments 1 week)
PayPal 2: + 5% TAX(4 payments 2 weeks)
... and so on as per Payment method ....

no need to worry about the "2 payments in 1 week or the 4 payments in 2 weeks, since this settings are controlled by PayPal website and not event booking so no need to worry about this...

the thing is that I need to duplicate the os_paypal plugin that way I can have as many plugins as I need for paypal...
You may wonder why?
well, I need it so that I can use different email's per paypal plugin, this email's are needed by PayPal's configuration in order for me to manages the recurring payments...

Plugin PayPal 1 : paypal_email1@dom.com
Plugin PayPal 2 : paypal_email2@dom.com
... and so on...

So I need 2 things
1.- Duplicate the PayPal Plugin
2.- add a new parameter to each PayPal Plugin, this parameter will be the % to be added to the total amount to be paid...

if the user buy Event 1 which cost 10usd and event 2 which cost 15usd then the total will be 25usd, when the user is ready to make the payment it will show the paypal payments and depending on which one he chooses the % will be added to the total amount...


I was able to duplicate the PayPal plugin, it did showed in the back-end, I was able to add the configurations but, in the front-end at the moment of checkout I'm getting a blank page... no error, no nothing, just a blank page...

so I was wondering if you or someone can help me add this 2 items to event booking...

Thank you!

Please Log in or Create an account to join the conversation.

  • Dycon
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
12 years 4 months ago #36209 by Dycon
Replied by Dycon on topic Re: Price modifier per Payment option
if the above is not possible then, what about custom fields? ....

I see that I can add a feed to the total amount, but what if I need to add a percentage not a fix rate...
right now I can use:
+10
+15
+20 ...

what about

+10%
+15%
+20%

is that possible?

if not then can you point me in the right direction to make this modifications please....

but I'd love to use multiple PayPal plugins with a percentage fee...

Thank you...

Please Log in or Create an account to join the conversation.

  • Dycon
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
12 years 4 months ago #36220 by Dycon
Replied by Dycon on topic Re: Price modifier per Payment option
Hello Tuan, I got the plugins working... now I need to know where to do the algorithm 2 + 2 ....

is it in the cart.php ?
if so...

this formula isnot woring...

$percents = $totalAmount * ($feeAmount / 100);
$totalAmount += $percents ;


so I wonder why? ...

Thank you.

Please Log in or Create an account to join the conversation.

  • Dycon
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
12 years 4 months ago - 12 years 4 months ago #36222 by Dycon
Replied by Dycon on topic Re: Price modifier per Payment option
I think I got it working... sort of...

there still 1 thing that I can't figure it out...


why is that the total amount to be pay is not display in the checkout page?
I think is controlled by cart.php ? ...

but... the total to be pay after the % is showing at the "PayPal" Page...

Item Cost $880.00
Payment method "PayPal"
Monthly Payments +4.5%

Total $880.00 (here is where it need to display $919.6 but is not)

then the user click on "Proceed to pay" the user leave the page and is redirected to "PayPal" ...

once the user is on PayPal page the total amount change to the actual amount to be paid... which is $919.6
so in PayPal page it shows the correct amount but not in EB checkout ...

I wonder why? ...

Thank you.
Last edit: 12 years 4 months ago by Dycon. Reason: typo

Please Log in or Create an account to join the conversation.

  • Dycon
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
12 years 4 months ago #36338 by Dycon
Replied by Dycon on topic Re: Price modifier per Payment option
hello?

Please Log in or Create an account to join the conversation.

  • Dycon
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
12 years 4 months ago #36346 by Dycon
Replied by Dycon on topic Re: Price modifier per Payment option
Hello Tuan...

How can I make a list of the events the user are getting?...

once the user is ready to pay at the PayPal page, it only shows 1 item when the user has more than that...

how to make the list of all item in the cart? ...

Please Log in or Create an account to join the conversation.

More
12 years 4 months ago #36362 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: Price modifier per Payment option

Dycon wrote: I think I got it working... sort of...

there still 1 thing that I can't figure it out...


why is that the total amount to be pay is not display in the checkout page?
I think is controlled by cart.php ? ...

but... the total to be pay after the % is showing at the "PayPal" Page...

Item Cost $880.00
Payment method "PayPal"
Monthly Payments +4.5%

Total $880.00 (here is where it need to display $919.6 but is not)

then the user click on "Proceed to pay" the user leave the page and is redirected to "PayPal" ...

once the user is on PayPal page the total amount change to the actual amount to be paid... which is $919.6
so in PayPal page it shows the correct amount but not in EB checkout ...

I wonder why? ...

Thank you.


I believe the price is displayed on checkout confirmation page already. Don't you see it ?

Please Log in or Create an account to join the conversation.

More
12 years 4 months ago #36363 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: Price modifier per Payment option

Dycon wrote: Hello Tuan...

How can I make a list of the events the user are getting?...

once the user is ready to pay at the PayPal page, it only shows 1 item when the user has more than that...

how to make the list of all item in the cart? ...


At the moment, the system will only counted all of them at an item. The reason is because the price not only contains events but also custom fee fields. So I am not sure what will be the best way to handle this in this case.

At the moment, I think I will leave it works as how it is. Will find a better implement in the future.

Regards,

Tuan

Please Log in or Create an account to join the conversation.

Moderators: Tuan Pham Ngoc