Allow admin payments via order administration

Created on 13 May 2021, about 3 years ago
Updated 1 April 2023, about 1 year ago

Problem/Motivation

Right now when you try to create a manual payments via the Payments tab on the order you get the following error:

"PHP message: Uncaught PHP Exception Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException: "The "purchase_order_gateway" plugin did not specify a "add-payment" form class" at /var/www/html/docroot/core/lib/Drupal/Core/Plugin/PluginFormFactory.php line 41"

That's is because the PurchaseOrderGateway extends the PaymentGatewayBase instead of OnsitePaymentGatewayBase which is where the add-payment form is added.

Steps to reproduce

  1. Create an order
  2. Go to the Payments tab in order admin and click "Add payment" and chose "New purchase order" and click "Continue"
  3. An error will be displayed and you'll be unable to continue creating the payment

Proposed resolution

Make PurchaseOrderGateway extends OnsitePaymentGatewayBase instead of PaymentGatewayBase.

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡§πŸ‡·Brazil recidive

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024