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

fix: user role description translations in en/de #1287

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Usmanfee
Copy link
Contributor

@Usmanfee Usmanfee commented Oct 31, 2024

Description

Updated the CSV file parsing journey in order to extract the German language translations for User role's description in process of App creation.

Changelog entry:

- **App Access Management**
  - Added support to fetch German language translation from CSV file template for app User role [#1288](https://github.com/eclipse-tractusx/portal-frontend/issues/1288)

Why

we weren't handling the User Role's description in German language from CSV file template.

Issue

#1288

Checklist

  • I have performed a self-review of my own code
  • I have successfully tested my changes locally

Copy link

sonarcloud bot commented Oct 31, 2024

Copy link
Contributor

@ss-nikunj ss-nikunj left a comment

Choose a reason for hiding this comment

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

lgtm

@Usmanfee Usmanfee marked this pull request as ready for review November 4, 2024 11:56
@evegufy evegufy changed the base branch from main to release/v2.3.0-RC3 November 7, 2024 10:59
@evegufy evegufy added this to the Release 2.3.0 (24.12) milestone Nov 7, 2024
@evegufy
Copy link
Contributor

evegufy commented Nov 7, 2024

@kunalgaurav-bmw @lavanya-bmw @manojava-gk please review

@evegufy evegufy changed the base branch from release/v2.3.0-RC3 to release/v2.3.0-RC4 November 12, 2024 17:11
@evegufy evegufy changed the base branch from release/v2.3.0-RC4 to main November 13, 2024 13:39
Copy link
Contributor

@oyo oyo left a comment

Choose a reason for hiding this comment

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

The original implementation ignored i18n. We should refactor the code so the descriptions are not hard coded in the template csv but instead are taken from the i18n files. This way all i18n translations are in one place and not scattered over the repo.

CSVCells[0] === 'roles;description\r' ||
CSVCells[0] === 'roles;description'
CSVCells[0] === 'roles;description_en;description_de\r' ||
CSVCells[0] === 'roles;description_en;description_de'
Copy link
Contributor

Choose a reason for hiding this comment

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

The implemented solution wouldn't work with more than two languages in case we provide descriptions for additional languages in the future.

Commercial Manager;Commercial Specialist can do the final approval of commercial request and trigger the payout;Der Handelsspezialist kann die endgültige Genehmigung des Handelsantrags vornehmen und die Auszahlung veranlassen.
Recycler;Recycler can buy recycled material;Recycler können recyceltes Material kaufen
Manager;This is only a test text in EN;Das is in Deutsch
Copy link
Contributor

Choose a reason for hiding this comment

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

the translations should not appear in this template. Instead we should have them together with the other translations in src/assets/locales.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: IN PROGRESS
Development

Successfully merging this pull request may close these issues.

7 participants