IFRCGo / go-web-app

GO Web application! GO is a Red Cross Red Crescent platform to connect information on emergency needs with the right response.
https://go.ifrc.org
MIT License
6 stars 0 forks source link

Translation of title also changes the country #1032

Open toffehoff opened 2 months ago

toffehoff commented 2 months ago

Issue

The automated translation also changes the country in the title in certain cases. The title starts normally with a 3-letter code for a country where the emergency is happening. If you create a Fieldreport in French for an emergency in France, the title would start with "FRA: rest of the title". However, after the automated translation to English, it becomes "ENG: ..."; or to Spanish it becomes "ESP: ...". The translation confused the 3-letter code to be "language" and not "country".

Steps to reproduce

See https://go.ifrc.org/emergencies/7000/details. See also attached document. Translation in GO also changes country.docx

Expected behaviour

The country-code at the start of the title should not change with a translation.

Impact

Not quite sure for how many country-codes this is the case. But it is visible to everyone.

Severity

Medium: not a blocking issue, but also not just a cosmetic one.

Is there a workaround?

Manually update the title?

tovari commented 2 months ago

This is due to the title translation method as the whole string is translated by the translation api. Only the user entered component should be translated by the api.