-
-
Notifications
You must be signed in to change notification settings - Fork 817
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
Display Custom Fields on ContributionPage settings #31487
base: master
Are you sure you want to change the base?
Conversation
🤖 Thank you for contributing to CiviCRM! ❤️ We will need to test and review this PR. 👷 Introduction for new contributors...
Quick links for reviewers...
|
da528cb
to
75969c5
Compare
Looks good. Putting merge-ready just because it's not clear if it's intentional/out-of-scope that it doesn't work with subtypes, e.g. a custom group that is only for ContributionPages with financial type Donation. You can define such a custom group, but then it doesn't display here. I think it's ok for this if it's out-of-scope. Test fails are also happening elsewhere. |
Whilst I agree with this work, I think that we may want to think about some kind of upgrade step for people with this extension https://lab.civicrm.org/extensions/contributionpagecustomfield |
Just to clarify the extension I was referring to above currently handles the ability to have custom fields on contribution pages and also displays them. So if we merge this then people upgrading would probably end up possibly with the custom data displaying twice right? So I was thinking we could essentially pull this option value into core https://lab.civicrm.org/extensions/contributionpagecustomfield/-/blob/master/contributionpagecustomfield.php?ref_type=heads#L42 and then effectively deprecate that whole extension at that point and have an upgrade message of like "We see that you had the Contribution Page Custom Field extension enabled, this has now been disabled as it is now incorporated in core or similar" |
@seamuslee001 actually that wheel has already been invented :) |
Overview
This adds the display of Custom Fields on ContributionPages.
Before
Custom Fields on ContributionPages can be configured by API but not displayed.
After
Custom Fields on ContributionPages are displayed at the bottom of the Settings tab.
Technical Details
Comments
The customDataBlock.tpl that pulls in custom fields only loads groups with
style
of'Inline'
.The GDPR extension creates custom fields on ContributionPages with
Inline
style but has its own code to display these as a tab. This PR causes those fields to also be shown on the Settings tab. This can be avoided by changing the style toTab
- I will create a PR for GDPR.