Skip to content
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

Send order and agreement variables to the view #930

Merged
merged 1 commit into from
Apr 21, 2020

Conversation

jacquesbh
Copy link
Contributor

Especially the $order which is really really good to have there.
It allows to custom the success page without loading the order again.

Especially the `$order` which is really really good to have there.  
It allows to custom the success page without loading the order again.
@tmotyl
Copy link
Contributor

tmotyl commented Apr 21, 2020

Shoul the phtml file be also updated with this PR (to demonstrate the usefullness)?

@jacquesbh
Copy link
Contributor Author

Shoul the phtml file be also updated with this PR (to demonstrate the usefullness)?

I see no need here since the phtml contains everything which is needed right now.
The issue is pure OOP for me, why load an object and not sending it to the view since it may be very useful. It leads to more load over the database, which makes no sens.

It's still possible to add a comment saying these two variables are available in the templates, but I don't see the need here.

@tmotyl
Copy link
Contributor

tmotyl commented Apr 21, 2020

"why load an object "

where is the object loaded again?
If you're saying this patch can improve performance by passing existing variable to the view, then plase change also the view to use the performance benefit.

Copy link
Contributor

@Flyingmana Flyingmana left a comment

Choose a reason for hiding this comment

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

I remember to need to load the Order Object from the success page quite often, so yes, this is a usefull addition.

@tmotyl
Copy link
Contributor

tmotyl commented Apr 21, 2020

So do I get it right, that default templates are not using the order objects (they are not fetching it), but it's a common customization to show some order properties, so its good to have order object available?

@Flyingmana
Copy link
Contributor

yes

@colinmollenhour colinmollenhour merged commit f93651a into OpenMage:1.9.4.x Apr 21, 2020
@jacquesbh jacquesbh deleted the patch-1 branch April 21, 2020 15:00
@sreichel sreichel added this to the Release 19.4.2 milestone Jun 27, 2020
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Aug 20, 2020
…cess template

It allows to customize the success page without loading the order again
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Aug 24, 2020
…cess template

It allows to customize the success page without loading the order again
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.

5 participants