diff --git a/web/newWebsite/graph-main.js b/web/newWebsite/graph-main.js index e07f628..457fbce 100644 --- a/web/newWebsite/graph-main.js +++ b/web/newWebsite/graph-main.js @@ -110,12 +110,12 @@ container.appendChild(filterButton); document.body.appendChild(container); // Function to get the link for the get request -function generateLink(dateStart, dateEnd, node) { +function generateLink(dateStart, dateEnd, node, dataTypes) { const baseUrl = 'http://145.92.8.114/getMeasurements'; const formattedDateStart = new Date(dateStart).toISOString().replace('T', '%20'); const formattedDateEnd = new Date(dateEnd).toISOString().replace('T', '%20'); - link = `${baseUrl}?dateStart=${formattedDateStart}&dateEnd=${formattedDateEnd}&node=${node}`; + link = `${baseUrl}?dateStart=${formattedDateStart}&dateEnd=${formattedDateEnd}&node=${node}&dataTypes=${dataTypes}`; console.log(link); }