Uploaded image for project: 'PhenoTips'
  1. PT-2653

Rewrite untranslatable strings in Push dialog to include dynamic content within them

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: patient-data-sharing
    • Labels:
      None
    • Sprint:

      Description

      Because the order of words in a sentence can be different in different languages, it is a bad practice to define translation keys for pieces of sentences. For example:

      phenotips.PushPatient.patientUploadedDays=days ago
      phenotips.PushPatient.patientUploadedHours=hours ago

      are untranslatable in French: "5 days ago" -> "il y a 5 jours".

      Instead, sentences should be translated as a whole, and dynamic content should be passed as parameters.

      For example , there should be a single translation key for the sentence informing the user that a patient has already been uploaded:
      phenotips.PushPatient.patientAlreadyUploadedDays=This patient has already been uploaded to {0} {1} day(s) ago and was assigned the identifier {2}.
      phenotips.PushPatient.patientAlreadyUploadedHours=This patient has already been uploaded to {0} {1} hour(s) ago and was assigned the identifier {2}.

        Attachments

          Issue links

            Activity

              People

              • Assignee:
                veronikaslc Veronika Koltunova
                Reporter:
                katpccm Kat Pavlova
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: