This is my first time using Sage Pay Form
as a method of accepting payments. I am currently using a Bedrock
, Sage Theme
and Sage Pay
setup.
However, there is an issue with the payment receipt that we are getting sent out from the Sage Pay
service provider.
I have been in touch and they are adamant that this line is being added in by our current setup.
I have started to check myself, by adding the following to /woocommerce/checkout/review-order.php
<strong>WC()->cart->get_cart_discount_total() (Get the total of all cart discounts).</strong>
<?php var_dump(WC()->cart->get_cart_discount_total()); ?>
<strong>WC()->cart->get_cart_discount_tax_total() (SAB but with tax)</strong>
<?php var_dump(WC()->cart->get_cart_discount_tax_total()); ?>
<strong>WC()->cart->get_total_discount() (Get the total discount amount)</strong>
<?php var_dump(WC()->cart->get_total_discount()); ?>
<strong>WC()->cart->has_discount() (Returns whether or not a discount has been applied)</strong>
<?php var_dump(WC()->cart->has_discount()); ?>
<strong>WC()->cart->get_applied_coupons() (Any coupons in the cart?)</strong>
<?php var_dump(WC()->cart->get_applied_coupons()); ?>
And I was given the following results:
WC()->cart->get_cart_discount_total() (Get the total of all cart discounts).
float(0)
WC()->cart->get_cart_discount_tax_total() (SAB but with tax)
float(0)
WC()->cart->get_total_discount() (Get the total discount amount)
bool(false)
WC()->cart->has_discount() (Returns whether or not a discount has been applied)
bool(false)
WC()->cart->get_applied_coupons() (Any coupons in the cart?)
array(0) {
}
I'm wondering if there's an area that I need to start looking deeper in the code? Or could it be a Sagepay Plugin
issue (because there was a discount fix early last year) and Woocommerce
does update a lot. http://ift.tt/25UqrZX.
Screenshot of the discount line
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire