draw multipolygon in map

parent fc0e7818
...@@ -84,16 +84,16 @@ function drawPolygon(element) { ...@@ -84,16 +84,16 @@ function drawPolygon(element) {
osmap.removePolygon(); osmap.removePolygon();
// draw wkt polygon // draw wkt polygon
osmap.addWKTPolygon(polygon.wkt_polygon); // osmap.addWKTPolygon(polygon.wkt_polygon);
// format coords to draw // format coords to draw
// var coords = osmap.formatCoords(polygon.geojson.geometry.coordinates); var coords = osmap.formatCoords(polygon.geojson.geometry.coordinates);
// get the biggest area // get the biggest area
// var biggest = osmap.getBiggestPolygon(coords); // var biggest = osmap.getBiggestPolygon(coords);
// draw coordsR // draw coordsR
// osmap.addPolygon(biggest); osmap.addPolygon(coords);
} }
}) })
} }
...@@ -148,7 +148,7 @@ function drawApiResponse(element) { ...@@ -148,7 +148,7 @@ function drawApiResponse(element) {
console.log("footprint:\n", data.product.footprint); console.log("footprint:\n", data.product.footprint);
if (!prevfeature.has(data.uuid)){ if (!prevfeature.has(data.uuid)){
element.style.textDecoration = 'underline'; element.style.textDecoration = 'underline';
prevfeature.set(data.uuid, osmap.addfootprint(data.product.footprint, prevfeature)); prevfeature.set(data.uuid, osmap.addfootprint(data.product.footprint, prevfeature));
}else{ }else{
if (prevfeature.length != 0){ if (prevfeature.length != 0){
element.style.textDecoration = 'none'; element.style.textDecoration = 'none';
...@@ -156,7 +156,7 @@ function drawApiResponse(element) { ...@@ -156,7 +156,7 @@ function drawApiResponse(element) {
prevfeature.delete(data.uuid); prevfeature.delete(data.uuid);
} }
} }
} }
} }
} }
...@@ -322,7 +322,6 @@ $(document).ready(function () { ...@@ -322,7 +322,6 @@ $(document).ready(function () {
}); });
console.log("DD: ", data);
productListGlobe.push(data); productListGlobe.push(data);
}); });
......
...@@ -90,12 +90,12 @@ def productList(request): ...@@ -90,12 +90,12 @@ def productList(request):
catalog = [] catalog = []
for p in products: for p in products:
# img_link = products[p]['link_icon'] # img_link = products[p]['link_icon']
# img_link = img_link[:img_link.find("/")+2] + "emmhp:geoemm29@" + img_link[img_link.find("/")+2:] # img_link = img_link[:img_link.find("/")+2] + "emmhp:geoemm29@" + img_link[img_link.find("/")+2:]
if products[p].get('tileid') is None: if products[p].get('tileid') is None:
titleid = products[p]['title'].split("_") titleid = products[p]['title'].split("_")
products[p]['tileid'] = titleid[5][1:] products[p]['tileid'] = titleid[5][1:]
catalog.append({ catalog.append({
'process' : process, 'process' : process,
'start_date' : init_date, 'start_date' : init_date,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment