-
-
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
CRM-21671 abstract core task #11536
CRM-21671 abstract core task #11536
Conversation
Jenkins test this please |
@mattwire error is
|
I merged the other one so might need a clean up - can you include just one of the child classes in here too ? |
51b5eb0
to
64c47e3
Compare
Jenkins test this please |
e0bc88e
to
7c26e86
Compare
test this please |
@eileenmcnaughton Yay, passes tests :-) |
CRM/Core/Task.php
Outdated
|
||
static $objectType = NULL; | ||
|
||
public static function tasks() { |
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.
This function could use a docblock.
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.
@colemanw Agreed. I've gone through and added more comments/docblocks
ca131bb
to
daa78a8
Compare
I read through this code & tested doing a participant search & choosing various actions. I hit no issues and the code is clearly an improvement. I think we are OK without a unit test as this is very form layer and there is no clear path to add tests here - although it might be nice to think of some |
After a recent upgrade from 4.7.29 to 5.2.1 (Joomla) I experienced the following problem: After doing an Events/Find Participants search and selecting some or all participants, the "Print selected rows" option in no longer appearing in the Actions dropdown. An Advanced Search when displaying results as Event Participants also is missing this option. The option does appear when results are displayed as Contacts. I have verified the same behavior on dmaster.demo (running 5.4.alpha1). Issue filed by Pradeep: https://lab.civicrm.org/dev/core/issues/185 |
Overview
This adds a new CRM_Core_Task class which all the other Task classes can inherit from as it's mostly duplicated code.
Split from CRM-21391 so it can be reviewed more easily.
Before
Lot's of duplicated code
After
Once CRM-21391 is merged, mostly shared code - easier to maintain and less buggy :-)