8000 Support link generator for mockup objects by ctippler · Pull Request #10938 · pimcore/pimcore · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Support link generator for mockup objects #10938

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

Merged
merged 8 commits into from
Dec 17, 2021
Merged

Support link generator for mockup objects #10938

merged 8 commits into from
Dec 17, 2021

Conversation

ctippler
Copy link
Contributor
@ctippler ctippler commented Dec 2, 2021

Currently it is not possible to use link generators for mockup objects.
This leads to the problem, that in some places you can use {{ pimcore_url({'object': product}) }} because you have the orgininal object and in other cases {{ pimcore_url({'object': product}) }} won't work because you have a mockup object....

This PR adds support for Link generators with Mockup objects...

ctippler and others added 3 commits December 2, 2021 12:49
@dvesh3 dvesh3 added this to the 10.2.6 milestone Dec 3, 2021
@dvesh3 dvesh3 added the BC-BREAK label Dec 6, 2021
@dvesh3 dvesh3 removed this from the 10.2.6 milestone Dec 7, 2021
Co-authored-by: Sebastian Blank <sebastian.bl@gmx.de>
@dvesh3 dvesh3 removed the BC-BREAK label Dec 9, 2021
Comment on lines +24 to +25
* If you want to support mockups or arbitrary objects you can change the typehint to
* public function generate(object $object, array $params = []): string
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we really need this comment? That's basic PHP contravariance behavior, so you could basically add this to every method...

Co-authored-by: Jacob Dreesen <jacob@hdreesen.de>
@dvesh3 dvesh3 added this to the 10.2.7 milestone Dec 10, 2021
@dvesh3 dvesh3 merged commit 016dcc2 into pimcore:10.2 Dec 17, 2021
@dvesh3
Copy link
Contributor
dvesh3 commented Dec 17, 2021

@ckogler-elements thanks!

kingjia90 added a commit that referenced this pull request Mar 13, 2023
kingjia90 added a commit that referenced this pull request Mar 14, 2023
kingjia90 added a commit that referenced this pull request Mar 14, 2023
martineiber added a commit that referenced this pull request Mar 22, 2023
* task: move ecommerce events to bundle

* task: follow-up #10938

* task: make event doc url relative

* task: doublecheck object if has getLinkGenerator method

* task: remove not found events

* Update doc/23_Installation_and_Upgrade/09_Upgrade_Notes/README.md

Co-authored-by: Martin Eiber <martin.eiber@pimcore.com>

---------

Co-authored-by: Martin Eiber <martin.eiber@pimcore.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0