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

Add support for currency with pronamic_pay_currency field name or option. #21

Merged
merged 3 commits into from
Sep 25, 2024

Conversation

rvdsteege
Copy link
Member

Fix #20.

@rvdsteege rvdsteege linked an issue Sep 23, 2024 that may be closed by this pull request
Copy link
Member

@remcotolsma remcotolsma left a comment

Choose a reason for hiding this comment

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

Perhaps combine $total = new Money(); on line 71 and $total = new Money( 0, \strtoupper( $currency ) ); on line 77, so it is also easier to track what the default currency is?

At first glance I found it a bit difficult to follow, because a new $total is created.

Currently, only payments in EUR are supported — the default currency of the https://github.com/pronamic/wp-money library.

And maybe document something in https://github.com/pronamic/wp-pronamic-pay-contact-form-7/blob/main/README.md? How does the tag or option work? Add examples? It should be an ISO 4217 currency code?

@rvdsteege rvdsteege merged commit f3af225 into main Sep 25, 2024
8 checks passed
@rvdsteege rvdsteege deleted the 20-add-support-for-currencies branch September 25, 2024 21:31
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.

Add support for currencies
2 participants