| | 567 | === Haiti === |
| | 568 | Admin Boundaries: |
| | 569 | * [http://eden.sahanafoundation.org/downloads/HT_Lx.7z HT_Lx.7z] |
| | 570 | |
| | 571 | Source is Centre National de l'Information Géo-Spatiale (CNIGS) via [https://data.humdata.org/dataset/hti-polbndl-adm1-cnigs-zip HDX] |
| | 572 | |
| | 573 | Use [http://7zip.org 7-Zip] to extract to your web2py folder & then install like this: |
| | 574 | {{{ |
| | 575 | cd /home/web2py |
| | 576 | p7zip -d HT_Lx.7z |
| | 577 | python web2py.py -S eden -M |
| | 578 | |
| | 579 | auth.override = True |
| | 580 | stylesheet = os.path.join(request.folder, "static", "formats", "s3csv", "gis", "location.xsl") |
| | 581 | resource = s3db.resource("gis_location") |
| | 582 | filename = "HT_L0.csv" |
| | 583 | File = open(filename, "r") |
| | 584 | resource.import_xml(File, format="csv", stylesheet=stylesheet) |
| | 585 | db.commit() |
| | 586 | filename = "HT_L1.csv" |
| | 587 | File = open(filename, "r") |
| | 588 | resource.import_xml(File, format="csv", stylesheet=stylesheet) |
| | 589 | db.commit() |
| | 590 | filename = "HT_L2.csv" |
| | 591 | File = open(filename, "r") |
| | 592 | resource.import_xml(File, format="csv", stylesheet=stylesheet) |
| | 593 | db.commit() |
| | 594 | filename = "HT_L3.csv" |
| | 595 | File = open(filename, "r") |
| | 596 | resource.import_xml(File, format="csv", stylesheet=stylesheet) |
| | 597 | db.commit() |
| | 598 | gis.update_location_tree() |
| | 599 | db.commit() |
| | 600 | }}} |
| | 601 | |