Customers can read your tracking page, estimate approval page, pay page, booking form, estimate emails and printed documents in their own language. You will be able to switch each language on, set the language a customer sees first, and know which words come from Pop Dispatch and which words you type yourself.
Before you start #
You need the owner or manager role to switch languages on. Dispatchers and advisors can set a customer's language on the customer record.
Every language except English starts switched off. The wording for Spanish, Punjabi, Gujarati, Hindi and Arabic needs a review by a native speaker before customers see it. The review list is in docs/i18n-review.md. Switch a language on after someone who speaks it has read the pages and documents.
Switch a language on #
On the Mac, open Settings and find Customer languages. Switch each language on, choose the Default language and choose Save. Each row says whether a native speaker has checked the language, and which languages read right to left. The steps below do the same through the API.
- Ask for the list of languages with
GET /settings/customer-languages. It shows each language, its own name, whether it is on, and whether it reads right to left. - Send
PATCH /settings/customer-languageswithenabled(for example["es", "ar"]) and, if you want one,default. English is always on. - Open a customer link with
?lang=eson the end. The page now shows Spanish, and a row of language links appears at the top of the page.
The default language is what a customer sees when their record has no language and they have not picked one. A default that is switched off falls back to English.
How a language is chosen #
The first match wins:
- The language the customer picked on the page. It is remembered on that phone.
- The language on the customer record (the Language field).
- Your default language.
- English.
A language you have not switched on never shows, even when a link or a saved choice asks for it.
What changes #
- The tracking page: every label, status word and date. It offers only the languages you have on, and keeps the customer's pick for next time.
- The estimate approval page: lines, choices, the signature words and every message about a missing tick or name.
- The pay page: totals, balance, the pay button and the thank-you message.
- The booking form: field names, the button, errors and the confirmation sentence.
- The estimate email: subject, greeting and wording, in the language on the customer record.
- Printed documents: the tow ticket, vehicle release form, lien notice, repair order or estimate, invoice and account statement. Headings, field names, status words, dates and the receipt sentence follow the language. Add
?lang=ar(or another code) to a document address to print a copy in that language.
What stays as typed #
Anything you or your desk typed prints exactly as typed: customer and vehicle names, addresses, line descriptions, notes, and the wording of your own lien notice template. The default wording of the Pennsylvania notices stays in English; write your own version in another language when you need one.
Arabic #
Arabic pages set the page direction to right to left and mirror the layout. Printed Arabic documents mirror too: the header, field labels, tables and signature lines read from the right. Amounts, dates and numbers use the digits 0 to 9.
Printed Punjabi (Gurmukhi), Gujarati, Hindi and Arabic text uses embedded Noto Sans fonts, so the letters show correctly on any screen or printer.
Technical details
- Settings:
customer_languages(the codes that are on, separated by commas) andcustomer_language(the default). The customer record'slanguagefield takes a code such ases. - Pages read
?lang=xxfirst, then thepsd_langcookie. A pick is saved in that cookie for a year. - Catalogues:
i18n/es.json,pa.json,gu.jsonandar.jsonhold only thecust.*keys;en.jsonandhi.jsonhold all keys. The tracking page's own strings are inweb/src/i18n/ui/<language>.jsonundertrack.*. - The booking form answers with
language,languages,dirandlabels; the booking confirmation carriesmessage. - Tracking data carries
language,languages,dirand a translatedstatus_label. - Fonts and licences:
core/fonts/README.md.
On the web console #
- Open Settings, then "Customer languages". English is always on.
- Tick each language to switch it on. A label beside each says whether a native speaker has checked it. Arabic reads right to left.
- Choose the "Default language" from the ones that are on, then choose Save. Switching a language off returns the default to English when it was the default.
If something goes wrong #
- A page still shows English: the language is off, or the link carries a mistyped code. Check
GET /settings/customer-languages. - The server refuses an
enabledlist that names a language Pop Dispatch does not offer: use one ofes,pa,gu,hi,ar. - "Switch the language on before making it the default": add it to
enabledin the same request.