strangerstudios / pmpro-donations

Allow customers to set an additional donation amount at checkout with Paid Memberships Pro.
https://www.paidmembershipspro.com/add-ons/donations-add-on/
8 stars 17 forks source link

Change invoice_id to order_id #76

Open becleung opened 3 months ago

becleung commented 3 months ago

All Submissions:

Changes proposed in this Pull Request:

All instances of invoice_id changed to order_id to match the change in PMPro 3.1

Without this change, !!donation!! variable in checkout emails show !!donation!! instead of the donation amount.

How to test the changes in this Pull Request:

  1. Put !!donation!! in checkout email template.
  2. Upgrade to PMPro 3.1
  3. Checkout emails show !!donation!!
  4. Apply change
  5. Checkout emails show donation amount.

Other information:

Changelog entry

Enter a summary of all changes on this Pull Request. This will appear in the changelog if accepted.

[BUG FIX] Resolves issue with !!donation!! variable not working with email templates in PMPro 3.1. WARNING: not backwards compatible with PMPRO 3.0.6 and earlier. Upgrade to PMPro 3.1 first.