Follow-up to kessai issue 3609963 (merged): kessai now mirrors the provider and never invents an amount, so a free booking that needs a card on file authorizes a real amount (its deposit) rather than a hard-coded verification charge. This aligns orchestra_payment with that model.
- Payable carries two amounts: authorizeAmount (held at the gateway) and captureAmount (taken at settle), validated so the capture never exceeds what was authorized. They are equal for a plain charge and differ when a step authorizes more than it will take (e.g. a free booking that authorizes a deposit but owes nothing).
- The payment step authorizes authorizeAmount. The settle task re-resolves the payable from the order through the same resolver and captures what the order owes now (a zero owed amount releases the authorization), so the outcome comes from the order, not from the amount held at the gateway.
- A shared PayableResolverConfigTrait carries the resolver picker, its settings, and the resolve helper, used by both the payment interaction and the settle task.
Kernel tests updated and green.
Issue fork orchestra-3610001
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #4
mably commented