Forums / Addon Payment Modules / Google checkout not working with coupons

Google checkout not working with coupons

Locked

Started by superprg on 13 May 2010, 5:23 AM · Views: 1,020

Results 1 to 2 of 2
This thread is locked. New replies are disabled.
13 May 2010, 5:23 AM
#1
superprg avatar

superprg

Totally Zenned

Join Date:
Feb 2006
Location:
Chicago
Posts:
1,349
Plugin Contributions:
0

Google checkout not working with coupons

Well
I have google checkout installed
Seems to work fine without coupons
When I use coupons
I seem to be getting the message

Sorry, the minimum purchase hasn't been reached to use this coupon

I debugged the problem in the file responsehandler.php and found that the if comparison in the statement

} else if ($coupon->fields['coupon_minimum_order'] > 0 && 
$order->info['total'] < $coupon->fields['coupon_minimum_order']) {

$order->info['total'] is always getting a value of 0

Any clue why its behaving this way??

Tutorials on Zen Cart
http://tutorials.zen-cart.com/index.php

advanced.programmer at gmail dot com
In love with Zen Cart!!

13 May 2010, 6:20 AM
#2
superprg avatar

superprg

Totally Zenned

Join Date:
Feb 2006
Location:
Chicago
Posts:
1,349
Plugin Contributions:
0

Re: Google checkout not working with coupons

I did a print of the variable $order->info and it can be clearly seen that total is coming as zero

//Added the following code in responsehandler.php before the if loop
file_put_contents('sample123.txt', serialize($order->info));

a:16:{s:12:"order_status";s:1:"1";s:8:"currency";s:3:"USD";
s:14:"currency_value";s:10:"1.00000000";s:14:"payment_method";
N;s:19:"payment_module_code";N;s:11:"coupon_code";N;
s:15:"shipping_method";N;s:20:"shipping_module_code";N;
s:13:"shipping_cost";N;s:8:"subtotal";i:0;s:12:"shipping_tax";
i:0;s:3:"tax";i:0;s:5:"total";i:0;s:10:"tax_groups";a:0:{}s:8:"comments";
s:0:"";s:10:"ip_address";s:29:"74.125.64.113 - 74.125.64.113";}

Can someone help

Tutorials on Zen Cart
http://tutorials.zen-cart.com/index.php

advanced.programmer at gmail dot com
In love with Zen Cart!!