Skip to main content

Process of updating of treatment translations

Why​

Sometimes we have requests from product support to update the treatment translations (like this).

Update Process​

Usually, we have a link to a google sheet like this with the list of all the new necessary translations that should be applied for a treatment. To update them we need to:

  • understand that treatment use Uala::ModelProps::Translatable concern that gives the model ability to have translations in the separate data table (treatment_translations in this case) and association translations'. So, for each locale we have a separate record in the treatment_translations` table.
  • create the csv file with the list of treatments to update, where each row has all necessary translations. The columns are:
    • id - id of the treatment
    • name_it - name for the italian locale
    • short_name_it - short name for the italian locale
    • description_it - description for the italian locale
    • name_fr - name for the french locale
    • short_name_fr - short name for the french locale
    • description_fr - description for the french locale
    • ... - same for other locales
  • run the Maintenance::UpdateTreatmentTranslations on the https://admin.uala.com/maintenance_tasks/tasks/ page with the csv file from the previous step