Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
situx committed Jan 13, 2025
1 parent f56af61 commit a1303fe
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/sparqlunicorn_ontdoc/export/api/wfsexporter.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ def generateFeatureList(outpath,deploypath,featurecollectionspaths,version,fsres
with open(coll, 'r', encoding="utf-8") as infile:
curcoll = json.load(infile)
op = outpath + "wfs/GetFeature/request=GetFeature&version="+version+"&typeName=" + coll.replace(outpath, "").replace("index.geojson", "")
os.mkdir(op)
op = op.replace(".geojson", "")
op = op.replace("//", "/")
if not os.path.exists(op):
Expand Down Expand Up @@ -50,10 +51,10 @@ def generateFeatureList(outpath,deploypath,featurecollectionspaths,version,fsres
# "") + "/items/"+collectionhtmlname+"\">[Collection as HTML]</a>&nbsp;<a href=\"" + opweb.replace(
# ".geojson", "") + "/items/\">[Collection as JSON]</a>&nbsp;<a href=\"" + opweb.replace(".geojson",
# "") + "/items/index.ttl\">[Collection as TTL]</a></td></tr>"
f = open(op + "index.json", "w", encoding="utf-8")
f = open(op + "/index.json", "w", encoding="utf-8")
f.write(json.dumps(currentcollection))
f.close()
f = open(op + "index.html", "w", encoding="utf-8")
f = open(op + "/index.html", "w", encoding="utf-8")
f.write("<html><head><meta name=\"viewport\" content=\"width=device-width, initial-scale=1\" /></head><body><h1>" + featurecollectionspaths[coll][
"name"] + "</h1><table><thead><tr><th>Collection</th><th>Links</th></tr></thead><tbody>" #+ str(curcollrow)
+ "</tbody></table></html>")
Expand Down

0 comments on commit a1303fe

Please sign in to comment.