-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Improved MVC events #37978
Improved MVC events #37978
Conversation
Is this backwards compatible? |
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.
Looks good so far; I don't immediately see any b/c breaks. However, this PR should be targeted at 4.2, as it introduces a new feature.
administrator/components/com_installer/src/Model/InstallerModel.php
Outdated
Show resolved
Hide resolved
@brianteeman Yes, it only adds the new functionality. I can add the same code in Joomla 3 but won't be accepted :) |
@Denitz New functionality should go into 4.2, if backwards compatible. So this PR should be rebased to the 4.2-dev branch. Let us know if you need help with that. After rebase, the PR might show unrelated changes on GitHub, but that will go away after the next update of the 4.2-dev branch with the latest changes on the 4.1-dev branch (so-called "upmerge") and after that an update of your branch for this PR to the latest 4.2-dev here. |
* Make sure a value is passed to base64_decode Signed-off-by: Roland Dalmulder <contact@rolandd.com> * Also check if we have a redirect URL before checking it is internal Signed-off-by: Roland Dalmulder <contact@rolandd.com>
* Make sure a value is passed to base64_decode Signed-off-by: Roland Dalmulder <contact@rolandd.com> * Also check if we have a redirect URL before checking it is internal Signed-off-by: Roland Dalmulder <contact@rolandd.com>
Co-authored-by: Richard Fath <richard67@users.noreply.github.com>
Co-authored-by: Richard Fath <richard67@users.noreply.github.com>
Co-authored-by: heelc29 <66922325+heelc29@users.noreply.github.com>
Co-authored-by: heelc29 <66922325+heelc29@users.noreply.github.com>
Co-authored-by: heelc29 <66922325+heelc29@users.noreply.github.com>
Co-authored-by: heelc29 <66922325+heelc29@users.noreply.github.com>
Co-authored-by: heelc29 <66922325+heelc29@users.noreply.github.com>
Co-authored-by: heelc29 <66922325+heelc29@users.noreply.github.com>
There is a reason why we don't have a listquery event because it creates more then it solves. This has discussed several times. Also the modification of the result is questionable. Because we easily generate more problems then expected. |
administrator/components/com_installer/src/Model/UpdateModel.php
Outdated
Show resolved
Hide resolved
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.
Please remove the new Events for query manipulation, this has been discussed several times for more information look at #26179
Sorry and thanks for your time. The query manipulation was the main feature of this PR. |
Would you mind to open a new pr which removes the hard codec class paths? |
I removed onContentListQuery event, though I totally disagree. |
This pull requests has been automatically converted to the PSR-12 coding standard. |
Summary of Changes
events_map
property moved fromFormModel
toBaseDatabaseModel
because the property is shared by multiple inheritors.eventClass
params ofAbstractEvent::create()
calls are shortened to useClassname::class
notation instead of using string event classname (easier to find all event class usages vide IDE in 2022).onAfterDisplay
event can modify the output now.ListQueryEvent
class andonContentListQuery
event to modify the list query before executing.AfterGetListEvent
class andonContentAfterGetList
event to modify the list of items after load from database.Testing Instructions
Actual result BEFORE applying this Pull Request
Core Joomla is barely extendable.
Expected result AFTER applying this Pull Request
Core Joomla is extendable.
Documentation Changes Required
No.