Changes between Version 139 and Version 140 of GIS/Data


Ignore:
Timestamp:
10/24/17 17:43:28 (4 years ago)
Author:
Fran Boon
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GIS/Data

    v139 v140  
    693693db.commit()
    694694filename = "NI_L2.csv"
     695File = open(filename, "r")
     696resource.import_xml(File, format="csv", stylesheet=stylesheet)
     697db.commit()
     698gis.update_location_tree()
     699db.commit()
     700}}}
     701
     702=== Panama ===
     703Admin Boundaries:
     704* [http://eden.sahanafoundation.org/downloads/PA_Lx.7z PA_Lx.7z]
     705
     706Source is [http://gadm.org GADM] via [https://data.humdata.org/dataset/panama-administrative-level-0-1-2-and-3-boundaries HDX].
     707
     708Use [http://7zip.org 7-Zip] to extract to your web2py folder & then install like this:
     709{{{
     710cd /home/web2py
     711p7zip -d PA_Lx.7z
     712python web2py.py -S eden -M
     713
     714auth.override = True
     715stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl")
     716resource = s3db.resource("gis_location")
     717filename = "PA_L0.csv"
     718File = open(filename, "r")
     719resource.import_xml(File, format="csv", stylesheet=stylesheet)
     720db.commit()
     721filename = "PA_L1.csv"
     722File = open(filename, "r")
     723resource.import_xml(File, format="csv", stylesheet=stylesheet)
     724db.commit()
     725filename = "PA_L2.csv"
     726File = open(filename, "r")
     727resource.import_xml(File, format="csv", stylesheet=stylesheet)
     728db.commit()
     729filename = "PA_L3.csv"
    695730File = open(filename, "r")
    696731resource.import_xml(File, format="csv", stylesheet=stylesheet)