diff --git a/src/App.js b/src/App.js
index f4d4e8c..1f4b698 100644
--- a/src/App.js
+++ b/src/App.js
@@ -284,31 +284,31 @@ function App () {
}
}
- function searchTable() {
- var input = document.getElementById("tableSearchInput").value.toUpperCase();
- var tr = document.getElementById("applicationTable").getElementsByTagName("tr");
-
- for (let i = 0; i < tr.length; i++) {
- var tdAddr = tr[i].getElementsByTagName("td")[0];
- var tdRef = tr[i].getElementsByTagName("td")[1];
- var tdDesc = tr[i].getElementsByTagName("td")[2];
- var tdStat = tr[i].getElementsByTagName("td")[4];
-
- if (tdAddr) {
- if (tdAddr.innerText.toUpperCase().indexOf(input) > -1 || tdRef.innerText.toUpperCase().indexOf(input) > -1 || tdDesc.innerText.toUpperCase().indexOf(input) > -1 ) {
- if (document.getElementById("filterSelect").value === "None") {
- tr[i].style.display = "";
- }
- else if (document.getElementById("filterSelect").value === tdStat.innerText) {
- tr[i].style.display = "";
- }
- }
- else {
- tr[i].style.display = "none";
- }
- }
- }
- }
+ // function searchTable() {
+ // var input = document.getElementById("tableSearchInput").value.toUpperCase();
+ // var tr = document.getElementById("applicationTable").getElementsByTagName("tr");
+
+ // for (let i = 0; i < tr.length; i++) {
+ // var tdAddr = tr[i].getElementsByTagName("td")[0];
+ // var tdRef = tr[i].getElementsByTagName("td")[1];
+ // var tdDesc = tr[i].getElementsByTagName("td")[2];
+ // var tdStat = tr[i].getElementsByTagName("td")[4];
+
+ // if (tdAddr) {
+ // if (tdAddr.innerText.toUpperCase().indexOf(input) > -1 || tdRef.innerText.toUpperCase().indexOf(input) > -1 || tdDesc.innerText.toUpperCase().indexOf(input) > -1 ) {
+ // if (document.getElementById("filterSelect").value === "None") {
+ // tr[i].style.display = "";
+ // }
+ // else if (document.getElementById("filterSelect").value === tdStat.innerText) {
+ // tr[i].style.display = "";
+ // }
+ // }
+ // else {
+ // tr[i].style.display = "none";
+ // }
+ // }
+ // }
+ // }
const onEachFeature = (feature, layer) => {
if (feature.properties && feature.properties.description && feature.properties.status && feature.properties.publicUrl) {
@@ -386,10 +386,11 @@ function App () {
if (layer._latlng === undefined) { return; }
if (map.getBounds().contains(layer._latlng)) {
- toDisplay.push(layer.feature.properties.reference);
+ if (layer.feature) {
+ toDisplay.push(layer.feature.properties.reference);
+ }
}
- console.log(toDisplay)
var tr = document.getElementById("applicationTable").getElementsByTagName("tr");
for (let i = 0; i < tr.length; i++) {
@@ -447,62 +448,64 @@ function App () {
url="https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"
/>
-
+
+
+
+
-
-
-
-
-
- {/*
+
+ {/*
*/}
-
-
-
-
-
-
-
-
-
-
-
-
- Address |
- Reference number |
- Description |
- Date received |
- Current Status |
- More info |
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Address |
+ Reference number |
+ Description |
+ Date received |
+ Current Status |
+ More info |
+
+
+
+
);
}
diff --git a/src/LocationMarker.js b/src/LocationMarker.js
index 0691add..62810f6 100644
--- a/src/LocationMarker.js
+++ b/src/LocationMarker.js
@@ -42,7 +42,7 @@ function LocationMarker() {
return (
<>
-