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

proper usage of translation parameters #1450

Closed
vitek-rostislav opened this issue Oct 4, 2019 · 2 comments
Closed

proper usage of translation parameters #1450

vitek-rostislav opened this issue Oct 4, 2019 · 2 comments
Labels
DX & Refactoring Requests for DX improvements and refactorings Stale This issue have not been touched for some time and if it doesn't change, it will be closed soon.

Comments

@vitek-rostislav
Copy link
Contributor

What is happening

Sometimes (AFAIK in admin controllers very often), we define translation messages with twig parameters (using {{ variableName }}) which makes the messages almost unusable outside the Twig. E.g. if I wanted to access the proper translation in PHP, I would need to use TwigEngine - and this is just not right.

I had to rewrite it e.g. in PaymentController::editAction() when I needed to use the translation in PaymentImageUploadCest::testSuccessfulImageUpload in #1425

Expected result

All translation messages use variables properly (%variableName%)

@stale
Copy link

stale bot commented Feb 1, 2020

This issue has been automatically marked as stale because there was no activity within the last 4 months (and it is quite a long time). It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the Stale This issue have not been touched for some time and if it doesn't change, it will be closed soon. label Feb 1, 2020
@stale
Copy link

stale bot commented Apr 1, 2020

This issue has been automatically closed because there was no acivity within the last half a year.

@stale stale bot closed this as completed Apr 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DX & Refactoring Requests for DX improvements and refactorings Stale This issue have not been touched for some time and if it doesn't change, it will be closed soon.
Projects
None yet
Development

No branches or pull requests

1 participant