Post by sunster » Wed Jul 31, 2013 7:49 am

Hey everyone,

I have a colleague using opencart and he cannot get free checkout to show up. Here's the setup and scenario on 1.5.5.1 with custom theme:

-Free shipping disabled.
-Free checkout enabled (settings of pending, enabled and 5)
-Test coupon setup for 100% discount and free shipping
-product in cart $100 that is setup to require shipping
-go through guest checkout
-step 4 delivery method, pick the 1 method of shipping for $12
-Step 5 "Warning: no payment options available"

Now on step 5 he used to get Paypal and after the coupon was applied the amount would show as $0.00 on step 6 but if you went to Paypal, it would show the amount before coupon was applied.
Didn't make sense having Paypal show up on a $0.00 amount anyways so I had him eliminate that by setting minimum amount on Paypal module to $0.01.

Any help would be greatly appreciated.

New member

Posts

Joined
Thu Sep 27, 2012 3:25 am

Post by sunster » Wed Jul 31, 2013 8:31 am

Ok here's a little update. For whatever reason, disabling Tax Class to None for the product allows the free checkout to show up. Put Tax class back to taxable goods and again "no payment options available".

New member

Posts

Joined
Thu Sep 27, 2012 3:25 am

Post by MarketInSG » Wed Jul 31, 2013 9:50 am

because when products are taxed, I think it ends up with some small amount of fee, and when total > $0, it no longer show up?


User avatar
Guru Member

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by sunster » Wed Jul 31, 2013 12:15 pm

MarketInSG wrote:because when products are taxed, I think it ends up with some small amount of fee, and when total > $0, it no longer show up?
So even thou it shows us the Total as $0.00, you are saying it actually may be something like $0.00001? and if this is the cause, any idea how to fix it?

Thanks

Edit: He checked in the database and the order total shows as $0.0000.

Update: So we got free checkout to show up but we are not sure if it is ok to do this. We changed the if ($total <= 0) line to if ($total <= 0.01) in free_checkout.php.

New member

Posts

Joined
Thu Sep 27, 2012 3:25 am

Post by MarketInSG » Wed Jul 31, 2013 2:08 pm

it might be the issue due to some minor difference. at least you got it to display now :)


User avatar
Guru Member

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by mwd » Thu May 22, 2014 6:32 am

MarketInSG wrote:because when products are taxed, I think it ends up with some small amount of fee, and when total > $0, it no longer show up?
That seems to be the case.
We just ran into this problem for the first time today.
Based on sales tax percentage the actual total ends up a fraction of a cent more or less than a whole number.
When it's a fraction of a cent more than zero, the Free Checkout doesn't show.
sunster wrote:Update: So we got free checkout to show up but we are not sure if it is ok to do this. We changed the if ($total <= 0) line to if ($total <= 0.01) in free_checkout.php.
Thank you for this update.
After finding the correct free_checkout.php in catalog/model/payment, I adjusted your code fix a little to:

Code: Select all

if ($total < 0.01)
instead of <= 0.01

Worked like a charm!

Use it? Like it? Want to support it but don't know how? Send a donation to show your appreciation.
Daniel's PayPal address - donate@opencart.com
Qphoria's Paypal address - qphoria@gmail.com


mwd
Active Member

Posts

Joined
Sat Jan 08, 2011 11:40 pm
Who is online

Users browsing this forum: No registered users and 13 guests