Changes between Version 37 and Version 38 of GIS/Data


Ignore:
Timestamp:
05/21/14 22:40:28 (11 years ago)
Author:
Fran Boon
Comment:

Make language handling more robust

Legend:

Unmodified
Added
Removed
Modified
  • GIS/Data

    v37 v38  
    2525
    2626auth.override = True
    27 settings.L10n.languages["prs"] = "Dari"
    28 settings.L10n.languages["ps"] = "Pashto"
     27languages = s3.l10n_languages
     28languages["prs"] = "Dari"
     29languages["ps"] = "Pashto"
    2930stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
    3031resource = s3db.resource("gis_location")
     
    6263
    6364auth.override = True
    64 settings.L10n.languages["hy"] = "Armenian"
    65 settings.L10n.languages["ru"] = "Russian"
     65languages = s3.l10n_languages
     66languages["hy"] = "Armenian"
     67languages["ru"] = "Russian"
    6668resource = s3db.resource("gis_location")
    6769stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    8789
    8890auth.override = True
    89 settings.L10n.languages["az"] = "Azerbaijani"
    90 settings.L10n.languages["ru"] = "Russian"
     91languages = s3.l10n_languages
     92languages["az"] = "Azerbaijani"
     93languages["ru"] = "Russian"
    9194resource = s3db.resource("gis_location")
    9295stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    113116
    114117auth.override = True
    115 settings.L10n.languages["km"] = "Khmer"
     118languages = s3.l10n_languages
     119languages["km"] = "Khmer"
    116120resource = s3db.resource("gis_location")
    117121stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    215219
    216220auth.override = True
    217 settings.L10n.languages["kk"] = "Kazakh"
    218 settings.L10n.languages["ru"] = "Russian"
     221languages = s3.l10n_languages
     222languages["kk"] = "Kazakh"
     223languages["ru"] = "Russian"
    219224resource = s3db.resource("gis_location")
    220225stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    240245
    241246auth.override = True
    242 settings.L10n.languages["ky"] = "Kyrgyz"
    243 settings.L10n.languages["ru"] = "Russian"
     247languages = s3.l10n_languages
     248languages["ky"] = "Kyrgyz"
     249languages["ru"] = "Russian"
    244250resource = s3db.resource("gis_location")
    245251stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    394400
    395401auth.override = True
    396 s3db.gis_location_name.language.requires = IS_IN_SET({"tl":"Tagalog"})
     402languages = s3.l10n_languages
     403languages["tl"] = "Tagalog"
    397404resource = s3db.resource("gis_location")
    398405stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    434441
    435442auth.override = True
    436 settings.L10n.languages["tg"] = "Tajik"
    437 settings.L10n.languages["ru"] = "Russian"
     443languages = s3.l10n_languages
     444languages["tg"] = "Tajik"
     445languages["ru"] = "Russian"
    438446resource = s3db.resource("gis_location")
    439447stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    490498
    491499auth.override = True
    492 settings.L10n.languages["tk"] = "Turkmen"
    493 settings.L10n.languages["ru"] = "Russian"
     500languages = s3.l10n_languages
     501languages["tk"] = "Turkmen"
     502languages["ru"] = "Russian"
    494503resource = s3db.resource("gis_location")
    495504stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    515524
    516525auth.override = True
    517 settings.L10n.languages["uz"] = "Uzbek"
    518 settings.L10n.languages["ru"] = "Russian"
     526languages = s3.l10n_languages
     527languages["uz"] = "Uzbek"
     528languages["ru"] = "Russian"
    519529resource = s3db.resource("gis_location")
    520530stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    585595
    586596auth.override = True
     597languages = s3.l10n_languages
     598languages["vi"] = "Vietnamese"
    587599resource = s3db.resource("gis_location")
    588600stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    621633
    622634auth.override = True
    623 settings.L10n.languages["bs"] = "Bosnian"
    624 settings.L10n.languages["hr"] = "Croatian"
    625 settings.L10n.languages["rs"] = "Serbian"
     635languages = s3.l10n_languages
     636languages["bs"] = "Bosnian"
     637languages["hr"] = "Croatian"
     638languages["sr"] = "Serbian"
    626639stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
    627640resource = s3db.resource("gis_location")
     
    659672
    660673auth.override = True
    661 settings.L10n.languages["ka"] = "Georgian"
    662 settings.L10n.languages["ru"] = "Russian"
     674languages = s3.l10n_languages
     675languages["ka"] = "Georgian"
     676languages["ru"] = "Russian"
    663677resource = s3db.resource("gis_location")
    664678stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    682696
    683697auth.override = True
    684 settings.L10n.languages["el"] = "Greek"
     698languages = s3.l10n_languages
     699languages["el"] = "Greek"
    685700resource = s3db.resource("gis_location")
    686701stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    752767
    753768auth.override = True
    754 settings.L10n.languages["ar"] = "Arabic"
     769languages = s3.l10n_languages
     770languages["ar"] = "Arabic"
    755771resource = s3db.resource("gis_location")
    756772stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    790806
    791807auth.override = True
    792 settings.L10n.languages["ar"] = "Arabic"
     808languages = s3.l10n_languages
     809languages["ar"] = "Arabic"
    793810resource = s3db.resource("gis_location")
    794811stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    828845
    829846auth.override = True
    830 settings.L10n.languages["ar"] = "Arabic"
     847languages = s3.l10n_languages
     848languages["ar"] = "Arabic"
    831849resource = s3db.resource("gis_location")
    832850stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     
    896914
    897915auth.override = True
    898 settings.L10n.languages["tpi"] = "Tok Pisin"
    899 settings.L10n.languages["ho"] = "Hiri Motu"
     916languages = s3.l10n_languages
     917languages["tpi"] = "Tok Pisin"
     918languages["ho"] = "Hiri Motu"
    900919resource = s3db.resource("gis_location")
    901920stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")