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

6531 update standard report filter dropdown translation keys #6538

Open
wants to merge 11 commits into
base: v2.6.0-RC
Choose a base branch
from

Conversation

noel-yeldos
Copy link
Contributor

@noel-yeldos noel-yeldos commented Feb 18, 2025

Fixes #6531

πŸ‘©πŸ»β€πŸ’» What does this PR do?

Add translation keys for report sort by dropdown options.

Changes needed as all dropdown options were showing in english irrespective of user selected language.

Screenshot 2025-02-18 at 13 12 55

πŸ’Œ Any notes for the reviewer?

Note item usage report styling is a known issue.

πŸ§ͺ Testing

  • Navigate to reports
  • Click on any/all of Item Usage, Stock Detail, Stock Status and Expiring items reports(These are all standard reports)
  • Switch language to one that is not english
  • Observe that dropdown options on the sort by field are translated (where translation is available)

πŸ“ƒ Documentation

  • Part of an epic: documentation will be completed for the feature as a whole
  • No documentation required: no user facing changes or a bug fix which isn't a change in behaviour
  • These areas should be updated or checked:
    1.
    2.

@github-actions github-actions bot added Team Ruru πŸ¦‰ Roxy, Ferg, Noel Severity: High Bugs breaking core functionality or with no/unacceptable workaround. High impact. Next patch release feature: reports labels Feb 18, 2025
@jmbrunskill jmbrunskill changed the base branch from develop to v2.5.2 February 18, 2025 00:38
@jmbrunskill jmbrunskill changed the base branch from v2.5.2 to develop February 18, 2025 00:38
Copy link

github-actions bot commented Feb 18, 2025

Bundle size difference

Comparing this PR to main

Old size New size Diff
5.95 MB 5.95 MB 557 B (0.01%)

@fergie-nz fergie-nz self-assigned this Feb 18, 2025
Copy link
Contributor

@fergie-nz fergie-nz left a comment

Choose a reason for hiding this comment

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

Looks great thank you Noel,

A small change required to ensure version compatibility for 2.3, but otherwise great. Thank you :)

Comment on lines 19 to 26
["item.name", "T#report.item-name"],
["batch", "T#label.batch"],
["item.code", "T#label.code"],
["expiryDate", "T#report.expiry-date"],
["location.code", "T#label.location"],
["item.unitName", "T#label.unit"],
["packSize", "T#label.pack-size"],
["totalNumberOfPacks", "T#label.num-packs-total"]
Copy link
Contributor

Choose a reason for hiding this comment

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

FYI the functionality to translate the json schema with the "T#" identifier was added as part of 2.5 release, so these changes are not compatible with OMS version 2.3.

So in this case, you'll need to make a new version of the stock-detail report as version 2.5 to include these changes.

This is to prevent a site on version 2.3 trying to render this report and showing up the raw translation keys.

Technically speaking a remote site on version 2.3 shouldn't receive this updated report because version 2.3 doesn't yet have syncing from OMS central server added, but it is good practice to ensure that we keep versioning consistent and don't try to render anything incompatible.

Copy link
Contributor Author

@noel-yeldos noel-yeldos Feb 18, 2025

Choose a reason for hiding this comment

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

@fergie-nz thanks for pointing that out! Updated here: 720a52b
Do I need to revert changes to 2.3 version or can I leave as is?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes please you would need to revert changes in the 2.3 commit.

However you could do something like rename this version to 'latest', then copy and paste the 2.3 version from the develop branch (so you don't need to manually revert anything, just copy in the previous version).

The dif in your PR should show that nothing has changed in the 2.3 directory.

@noel-yeldos noel-yeldos changed the base branch from develop to v2.6.0-RC February 19, 2025 21:20
@noel-yeldos noel-yeldos added this to the v2.6.0-RC1 milestone Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature: reports Severity: High Bugs breaking core functionality or with no/unacceptable workaround. High impact. Next patch release Team Ruru πŸ¦‰ Roxy, Ferg, Noel
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Filter dropdowns are not translated in French or any languages
2 participants