Ejemplo n.º 1
0
def available_native_languages():
    """
    :return: jason with language codes for the
    supported native languages. curently only english...
    e.g. ["en", "fr", "de", "it", "no", "ro"]unquote_plus(flask.r
    """
    available_language_codes = list(map((lambda x: x.code), Language.native_languages()))
    return json.dumps(available_language_codes)
Ejemplo n.º 2
0
def system_languages():
    result = dict()
    result["learnable_languages"] = list(
        map((lambda x: dict(name=x.name, code=x.code)),
            Language.available_languages()))
    result["native_languages"] = list(
        map((lambda x: dict(name=x.name, code=x.code)),
            Language.native_languages()))
    return result
Ejemplo n.º 3
0
def available_native_languages():
    """
    :return: jason with language codes for the
    supported native languages. curently only english...
    e.g. ["en", "fr", "de", "it", "no", "ro"]unquote_plus(flask.r
    """
    available_language_codes = list(
        map((lambda x: x.code), Language.native_languages()))
    return json.dumps(available_language_codes)