Files
cms/tests
libretech ba110a11d8 fix(checkout): send a payment surcharge to PayPal as handling
The order service adds the price of the order's payment method to the
total, but the PayPal breakdown left it out, so an order with a
surcharge was sent an amount its breakdown did not add up to, which
PayPal rejects (D5). Since the breakdown is now checked against the
total, such an order was answered 400.

A payment price above 0 is now sent as handling, in whole cents, and
item total, tax, shipping and handling add up to the amount to the
cent. A payment method that costs nothing sends no handling.

Every payment method and the pickup cost 0.00 today, and the shop
cannot set a payment method (parseCustomerUpdate rejects the field),
so this is robustness, not a live defect.

The D5 test is a regular test, and a test checks the sum with a
surcharge, also with a pickup without a price, for every whole-cent
subtotal up to 300.00.

Refs libretech/mp#71
Refs libretech/mp#67
2026-10-09 01:50:02 +02:00
..