Files
mayan-edms/mayan/apps/documents/runtime.py
Roberto Rosario 2ee73e12b4 Replace the DOCUMENTS_LANGUAGE_CHOICES setting option. Replaced with the new DOCUMENTS_LANGUAGE_CODES.
Reduce default language code choice from 7800 to the top 100 spoken languages and related (https://en.wikipedia.org/wiki/List_of_languages_by_number_of_native_speakers).

Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
2018-06-03 02:53:45 -04:00

17 lines
356 B
Python

from __future__ import unicode_literals
#import os
import pycountry
#from django.conf import settings
from django.utils.translation import ugettext_lazy as _
from .settings import setting_language_codes
language_choices = [
(
iso639_3, _(pycountry.languages.get(alpha_3=iso639_3).name)
) for iso639_3 in setting_language_codes.value
]