Changes between Version 131 and Version 132 of GIS/Data


Ignore:
Timestamp:
10/24/17 15:59:13 (5 years ago)
Author:
Fran Boon
Comment:

+GT

Legend:

Unmodified
Added
Removed
Modified
  • GIS/Data

    v131 v132  
    528528db.commit()
    529529filename = "EC_L3.csv"
     530File = open(filename, "r")
     531resource.import_xml(File, format="csv", stylesheet=stylesheet)
     532db.commit()
     533gis.update_location_tree()
     534db.commit()
     535}}}
     536
     537=== Guatemala ===
     538Admin Boundaries:
     539* [http://eden.sahanafoundation.org/downloads/GT_Lx.7z GT_Lx.7z]
     540
     541Source is [http://gadm.org GADM] via [https://data.humdata.org/dataset/guatemala-administrative-level-0-national-1-departments-and-2-municipalities HDX].
     542
     543Use [http://7zip.org 7-Zip] to extract to your web2py folder & then install like this:
     544{{{
     545cd /home/web2py
     546p7zip -d GT_Lx.7z
     547python web2py.py -S eden -M
     548
     549auth.override = True
     550stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     551resource = s3db.resource("gis_location")
     552filename = "GT_L0.csv"
     553File = open(filename, "r")
     554resource.import_xml(File, format="csv", stylesheet=stylesheet)
     555db.commit()
     556filename = "GT_L1.csv"
     557File = open(filename, "r")
     558resource.import_xml(File, format="csv", stylesheet=stylesheet)
     559db.commit()
     560filename = "GT_L2.csv"
    530561File = open(filename, "r")
    531562resource.import_xml(File, format="csv", stylesheet=stylesheet)