-
-
Notifications
You must be signed in to change notification settings - Fork 824
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
dev/core#1331 Don't freeze fields for auto-renew memberships #16609
Conversation
(Standard links)
|
@wmortada I tested this on a 5.21 site and could not submit the "Edit membership" form without clicking "Override organization and type". I did not need to change the actual selections. But without clicking I got an error that they were required. |
Thanks @mattwire. I'll take a look. |
@mattwire try this now |
If you think it looks okay, I can create a new PR to tidy up the commits. |
I have r-run this and believe it is now ok to merge - @wmortada please squash the commits and I'll merge in a few days if no-one objects! |
…an auto-renew membership
@wmortada thanks for persevering with this! |
Hurray! Thanks @mattwire. It only took 8 months! |
Overview
If a membership is set to auto-renew some of the fields are frozen, which means that a user is unable to edit them when they visit the edit membership screen.
This PR changes this behaviour so that these fields are NOT frozen. The membership organisation/type field is initially disabled but with the option to enable this field and edit it. The membership status field has the option to override as per non auto-renew memberships.
Warning messages have been added to alert the user to the consequence of changing these membership details.
See https://lab.civicrm.org/dev/core/issues/1331 for more details and discussion.
Before
If the membership is set to auto-renew, the following fields are frozen:
If the payment processor supports cancelling automatic renewal there is a text alert with the option to cancel:
(If the payment processor doesn't support cancelling automatic renewal this alert doesn't show.)
After
If the membership is set to auto-renew the fields are not frozen and the user has the ability to override them if required. Help text with an appropriate warning is displayed.
If the payment processor supports cancelling automatic renewal there is an option to do so (within the alert):
Technical Details
None.
Comments
This replaces a previous PR #16322
I have created an extension that restores the current functionality for sites that need it: https://lab.civicrm.org/extensions/freeze-membership-fields
The end date field was unfrozen in #15540. See https://lab.civicrm.org/dev/core/issues/1126 for details.