Skip to content

Commit

Permalink
update polygon
Browse files Browse the repository at this point in the history
  • Loading branch information
RobertBroersma committed Dec 18, 2023
1 parent 60e683a commit 9d4c13d
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions app/pages/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,12 @@ function instantiateDraw(map) {
const data = draw.getAll()
polygons.value = data.features
let polygonJson = encodeURIComponent(
JSON.stringify(draw.getAll().features[0].geometry),
)
pdfLink.value = `${pdfEndpoint}?polygon=${polygonJson}`
return
let { allData, indices, rpValues, gwlValues } = await getDataByPolygon(data)
Expand Down Expand Up @@ -340,13 +346,7 @@ async function downloadNotebook() {
URL.revokeObjectURL(url)
}
let pdfLink = computed(() => {
let polygonJson = encodeURIComponent(
JSON.stringify(draw.getAll().features[0].geometry),
)
return `${pdfEndpoint}?polygon=${polygonJson}`
})
let pdfLink = ref('')
</script>

<template>
Expand Down

0 comments on commit 9d4c13d

Please sign in to comment.