PayPal Smart Buttons bypass discount logic when the payment method is changed after the fact
If a customer changes the payment method after the order has been placed, existing discount or shopping cart rules may not be applied correctly if the change is made via the PayPal Smart Buttons.
In this specific case, a customer initially selects Payment Method A when placing the order and receives a discount as a result. After completing the order, the customer can then switch to payment method B using the PayPal Smart Buttons. However, the previously granted discount remains in effect, even though it is intended to apply exclusively to payment method A.
This results in a commercially significant error: The customer continues to benefit from the discount even though they subsequently use a payment method for which the discount is not intended.
Expected Behavior:
If an order was originally completed using payment method A and a discount was granted as a result, a subsequent switch to payment method B should not result in the discount remaining in effect.
In this case, Shopware should either:
block the payment method change based on the existing discount/shopping cart rule,
re-evaluate the discount logic correctly when the payment method is changed,
or prevent extensions or PayPal Smart Buttons from bypassing this Shopware core logic.
The reverse process should remain possible: If a payment using payment method B fails or is canceled, the customer should still be able to switch to payment method A.