You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Having an issue whenever there's a negative item (not line item) in the order - namely a discount. For example, refer to the below cart:
The above has a discount set to remove the shipping value from the order, but any discount will do the same thing. Tested with taking a flat $5 off the order.
Trying to pay throws a A negative amount is not allowed..
Drilling into it, it seems mostly an omnipay issue. Refer to Getting the items in the cart, which in turn calls a common method, checking if each item is negative. Give the example above:
Because one value in that is negative, this check ($money->isNegative()) is thrown.
Slightly related to this is thephpleague/omnipay-paypal#198, where the PayPal plugin includes protected $negativeAmountAllowed = true;. I have confirmed adding this the the eway plugin works.
This begs the question though - is this really not an issue for anyone else using this plugin? I would've thought this would've been picked up sooner, so just trying to figure out if I'm doing something wrong. In any case, it would probably require a fork of the omnipay-eway package?
Having an issue whenever there's a negative item (not line item) in the order - namely a discount. For example, refer to the below cart:
The above has a discount set to remove the shipping value from the order, but any discount will do the same thing. Tested with taking a flat $5 off the order.
Trying to pay throws a
A negative amount is not allowed.
.Drilling into it, it seems mostly an omnipay issue. Refer to Getting the items in the cart, which in turn calls a common method, checking if each item is negative. Give the example above:
Because one value in that is negative, this check (
$money->isNegative()
) is thrown.Slightly related to this is thephpleague/omnipay-paypal#198, where the PayPal plugin includes
protected $negativeAmountAllowed = true;
. I have confirmed adding this the the eway plugin works.This begs the question though - is this really not an issue for anyone else using this plugin? I would've thought this would've been picked up sooner, so just trying to figure out if I'm doing something wrong. In any case, it would probably require a fork of the omnipay-eway package?
Any ideas @lukeholder or @nfourtythree ?
The text was updated successfully, but these errors were encountered: