Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Volker Coors
Visualization
Commits
891ee8fb
Commit
891ee8fb
authored
1 year ago
by
Rushikesh Padsala
Browse files
Options
Download
Email Patches
Plain Diff
Added Chart.js to Leaflet.js
parent
d8909462
Pipeline
#7518
passed with stages
in 8 seconds
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
Exercise 1/index.html
+11
-15
Exercise 1/index.html
with
11 additions
and
15 deletions
+11
-15
Exercise 1/index.html
+
11
-
15
View file @
891ee8fb
<html>
<html>
<head>
<head>
<title>
Building - Heat Demand
</title>
<title>
Building - Heat Demand
</title>
<meta
charset=
"utf-8"
>
<meta
charset=
"utf-8"
>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1.0"
>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1.0"
>
...
@@ -34,7 +32,6 @@
...
@@ -34,7 +32,6 @@
}
}
</style>
</style>
</head>
</head>
<body>
<body>
<div
id=
"map-container"
>
<div
id=
"map-container"
>
<div
id=
"mapid"
></div>
<div
id=
"mapid"
></div>
...
@@ -42,6 +39,8 @@
...
@@ -42,6 +39,8 @@
<div
id=
"chart-container"
>
<div
id=
"chart-container"
>
<canvas
id=
"yocChart"
></canvas>
<canvas
id=
"yocChart"
></canvas>
</div>
</div>
<script>
<script>
var
mymap
=
L
.
map
(
'
mapid
'
).
setView
([
48.79205
,
9.20758
],
16
);
var
mymap
=
L
.
map
(
'
mapid
'
).
setView
([
48.79205
,
9.20758
],
16
);
var
OpenStreetMap_DE
=
L
.
tileLayer
(
'
https://{s}.tile.openstreetmap.de/tiles/osmde/{z}/{x}/{y}.png
'
,
{
var
OpenStreetMap_DE
=
L
.
tileLayer
(
'
https://{s}.tile.openstreetmap.de/tiles/osmde/{z}/{x}/{y}.png
'
,
{
...
@@ -91,6 +90,9 @@
...
@@ -91,6 +90,9 @@
onEachFeature
:
onEachFeature
,
onEachFeature
:
onEachFeature
,
style
:
style
,
style
:
style
,
}).
addTo
(
mymap
);
}).
addTo
(
mymap
);
// Retrieve the building year of construction data from the GeoJSON
// Retrieve the building year of construction data from the GeoJSON
var
buildingYoc
=
building_data
.
features
.
map
(
function
(
feature
)
{
var
buildingYoc
=
building_data
.
features
.
map
(
function
(
feature
)
{
return
feature
.
properties
.
Year_of_co
;
return
feature
.
properties
.
Year_of_co
;
...
@@ -146,12 +148,6 @@ var yocChart = new Chart(ctx, {
...
@@ -146,12 +148,6 @@ var yocChart = new Chart(ctx, {
}
}
});
});
</script>
</script>
</body>
</body>
</html>
</html>
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets