-
-
Notifications
You must be signed in to change notification settings - Fork 825
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
Ensure that completed status is selected by default on search contrib… #14612
Ensure that completed status is selected by default on search contrib… #14612
Conversation
(Standard links)
|
CRM/Contribute/Form/Search.php
Outdated
if (empty($this->_defaults['contribution_status'])) { | ||
$this->_defaults['contribution_status'][1] = 1; | ||
if (empty($this->_defaults['contribution_status_id'])) { | ||
$this->_defaults['contribution_status_id'][1] = 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hardcoded?
$this->_defaults['contribution_status_id'][1] = CRM_Core_PseudoConstant::getKey(
'CRM_Contribute_BAO_Contribution',
'contribution_status_id',
'Completed'
);
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @pradpnayak good point have changed to the PseudoConstant
2dafc3b
to
cf98098
Compare
Jenkins re test this please |
@seamuslee001 I guess that makes sense but note that - #14624 changes it to not kick in under force |
@eileenmcnaughton i think that is ok but i would appreciate others thoughts re the force side of things |
@seamuslee001 from my testing the force is keeping the old behaviour - ie try going from manage contribution page to the contributions from that page this month in an older version - I think it is not enforcing a status |
…ution form Use PseudoConstant function as label could change (good point thanks pradeep)
cf98098
to
8f8147e
Compare
…ution form
Overview
This fixes a small bug where when loading the contribution form the status field doesn't have a default of completed status.
Before
After
ping @eileenmcnaughton @monishdeb @mattwire