WA4.1 Language selection and translation tables

 

openIMIS components: Web Application v1.3.0 and later.
Implementation roles required: Implementer, Database manager

Video tutorial

openIMIS Database - Language Translation Tables

 

In language translation section, we have added another language to the Web Application as a resource file. However, you cannot use the new language unless you add this language as an option in the database. In addition to this, you will need to customise and translate the dropdown lists to have a completely translated version of openIMIS.

To facilitate the customisation and the translation of the dropdown list in openIMIS database, we suggest installing SQL Server Management Studio (SSMS). The following procedure is based on SSMS, but you can use the standard SQL Server prompt to proceed with the setup.

Customisation and translation of the dropdown list

Before configuring the available languages in openIMIS, lets first add the translation for the different dropdown list. openIMIS is using dropdown lists in both Web Application and mobile applications to allow users to modify entities attributes.

The following tables contain dropdown translations: 

Table name

Entity attribute

Default values

Description

tblConfirmationTypes

Family.ConfirmationType

  • Local council

  • Municipality

  • State

  • Other

The type of confirmation of the social status of the family.

tblEducations

Insuree.Education

  • Nursery

  • Primary school

  • Secondary school

  • University

  • Postgraduate studies

  • PHD

  • Other

The level of education of the insuree.

tblFamilyTypes

Family.Type

  • Council

  • Organization

  • Household

  • Other

  • Priests

  • Students

  • Teachers

The type of family. 

tblGender

Insuree.Gender

  • Female

  • Male

  • Other

The gender of the insuree.

tblHFSublevel

HealthFacility.SubLevel

  • Integrated

  • No Sublevel

  • Reference

The sub-level of a health facility. Level are:

  • Dispensary

  • Health Center

  • Hospital

tblIdentificationTypes

Insuree.IdentificationType

  • Driver's License

  • National ID

  • Passport

  • Voter Card

The type of identification document the insuree provided during the enrolment process.

tblLegalForms

HealthFacility.LegalForm

  • Charity

  • District organization

  • Government

  • Private organization

The legal form of the health facility. 

tblPayerType

Payer.Type

  • Co-operative

  • Donor

  • Government

  • Local Authority

  • Other

  • Private Organization

The type of payer. A payer can pay the contribution for a family or group.

tblProfessions

Insuree.Profession

  • Housewife

  • Employee

  • Self Employee

  • Others

The profession of the insuree. 

tblRelations

Insuree.Relationship 

  • Brother/Sister

  • Father/Mother

  • Uncle/Aunt

  • Son/Daughter

  • Grand parents

  • Employee

  • Others

  • Spouse

The relationship of the insuree to the head of the insured family. 

For example, the Education dropdown list from the Web Application's Add Family form allows to chose the family head's level of education. 

There are two advantages of having the dropdown list options in the database:

it is easier to translate without publishing again the applications 

it is easier to add or remove options based on the scheme/implementation/country requirements

The downside of this is the limit to the number of languages that can be supported. All dropdown translation tables have the following structure: 

Column Name

Data Type

Description

Id

smallint

The identifier of the dropdown option

FirstLanguageTerm

nvarchar(50)

The dropdown option term in the first language (English by default)

SortOrder 

int

Position of the option in the dropdown 

AltLanguage

nvarchar(50)

The dropdown option term in the alternative/second language (French by default)

This structure allows only two languages to be used in openIMIS. For example, in Tanzania, the two languages are English and Swahili. 

Because the available dropdown options depend on the scheme/implementation/country requirements, the customisation of the dropdown lists is part of the scheme configuration. 

Language selection configuration 

The available languages that can be selected in the Web Application and mobile applications are configured in the tblLanguages table in the openIMIS database. As we have seen in the previous section, the dropdown translation tables are limiting the number of available languages to two. 

In case you added another language in the Web Application source code, you will need to replace here one language with the new one (usually second language).

The following structure is presented in the languages table:

Column Name

Data Type

Description

LanguageCode

nvarchar(5)

The identifier of the language. 

LanguageName

nvarchar(50)

The language name that will be displayed in Web and Mobile Applications

SortOrder 

int

Position of the option in the language selection dropdown 

Please pay attention to the LanguageCode. It represents language code used for the Web Application resource files (e.g. Resource.fr.resx). If you use Lokalise, the code is represented by the %LANG_ISO% code of the translation language (fr_CM for the Cameroon example). The length of the LanguageCode has been updated in October 2019 release to allow ISO 639 and ISO 3166 coding (e.g. fr_FR).





Did you encounter a problem or do you have a suggestion?

Please contact our Service Desk



This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License. https://creativecommons.org/licenses/by-sa/4.0/