Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Offline donations gateway v3 compatibility #6919

Merged
merged 14 commits into from
Sep 8, 2023

Conversation

JasonTheAdams
Copy link
Contributor

@JasonTheAdams JasonTheAdams commented Sep 6, 2023

Description

This PR is a rebuild of the Offline gateway to make use of the Gateway API and be v2 + v3 compatible. It cleans up a bunch of the old code and should port everything over nicely. The ID and everything should be preserved such that it's full backwards-compatible.

Note, since there's now a Billing Address block, the billing address settings don't do anything anymore on v3 forms. It should still work on v2 forms, though.

Affects

The offline donations gateway

Visuals

In the donation form

image

Settings in form builder

image

Testing Instructions

Make sure the Offline gateway works with v2 and v3 forms. Make sure to test out the various settings and emails related to offline.

Pre-review Checklist

  • Relevant @unreleased tags included in DocBlocks
  • Includes unit tests
  • Reviewed by the designer (if follows a design)
  • Self Review of code and UX completed

@JasonTheAdams JasonTheAdams changed the title feature: clean up old code and finish v2 compatibility Feature: Offline donations gateway v3 compatibility Sep 6, 2023
@JasonTheAdams
Copy link
Contributor Author

@jonwaldstein This is ready for review! Happy to hop on a call to review together if you feel that would speed things up.

@jonwaldstein
Copy link
Contributor

@JasonTheAdams i'm getting a bunch of errors when running npm run dev. If you added a typescript package to support an existing package - the versions need to match up or else the types are coming from a different version.

Screenshot 2023-09-07 at 4 17 49 PM

@JasonTheAdams
Copy link
Contributor Author

@jonwaldstein Are you able to help with that? How do I know which version to use?

@jonwaldstein
Copy link
Contributor

@jonwaldstein Are you able to help with that? How do I know which version to use?

The version of the @types/{package} and the actual {package} need to be as close as possible - since the @types/{package} is basically supplying types for that version of the package.

Yes I can help

@jonwaldstein
Copy link
Contributor

@JasonTheAdams fyi there's some discrepencies between the latest @types/wordpress__block-editor version and @wordpress/block-editor - they're not in sync at the moment so removing for now. we can solve this another time.

Copy link
Contributor

@jonwaldstein jonwaldstein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good, left a few comments. You will also want to add a migration for the form settings to block attributes.

@JasonTheAdams
Copy link
Contributor Author

@jonwaldstein Your appreciated feedback has been addressed and (thanks to your guard suggestion) all tests are passing. This is ready for another review!

@jonwaldstein
Copy link
Contributor

@JasonTheAdams are you going to update this PR with the migration as well?

@JasonTheAdams
Copy link
Contributor Author

@JasonTheAdams are you going to update this PR with the migration as well?

Ah yes, good point! I'll do that now!

@JasonTheAdams
Copy link
Contributor Author

@jonwaldstein I added the migration code: 22fff11

Copy link
Contributor

@jonwaldstein jonwaldstein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice job! ready for QA 💸

Copy link
Member

@rickalday rickalday left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Passed manual QA tests.

@JasonTheAdams JasonTheAdams merged commit 8a6915f into epic/givewp-3.0 Sep 8, 2023
21 checks passed
@JasonTheAdams JasonTheAdams deleted the feature/offline-gateway-compatibility branch September 8, 2023 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants