1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593
| <!DOCTYPE HTML>
<!--
Editorial by HTML5 UP
html5up.net | @ajlkn
Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
-->
<html>
<head>
<title>Outil d'aide à la décision - Capacité de charge</title>
<meta charset="utf-8" />
<link rel="stylesheet" href="assets/css/main.css" />
<link rel="stylesheet" href="css/tether.min.css">
<!-- <link rel="stylesheet" href="css/bootstrap.min.css">
<link rel="stylesheet" href="css/bootstrap-grid.min.css">
<link rel="stylesheet" href="css/bootstrap-reboot.min.css"> -->
<link rel="stylesheet" href="css/Chart.min.css">
<!-- <link rel="stylesheet" href="css/css_card.css"> -->
<link rel="stylesheet" href="css/leaflet.css">
<link rel="stylesheet" href="css/monstyle.css">
<script src="js/jquery.js"></script>
<script src="js/chart.js"></script>
<!-- <script src="js/bootstrap.js"></script> -->
</head>
<body class="is-preload">
<!-- Wrapper -->
<div id="wrapper">
<!-- Main -->
<div id="main">
<div class="inner">
<!-- Header -->
<header id="header">
<a href="index.html" class="logo"><strong>Outil d'aide à la décision - Capacité de charge Saint-Jean-Pied-de-Port</strong> <br> Maïtena Haristouy M2TIC</a>
</header>
<!-- Content -->
<section>
<header class="main">
<h3>Tableau de bord par jour et créneau horaire de la fréquentation de Saint-Jean-Pied-de-Port</h3>
</header>
<div class ="container3">
<div class ="row">
<div>
<select id="date"></select>
<select id="creneauhoraire"></select>
<div></div>
</div>
<div class ="meteo"><iframe src="https://www.meteoblue.com/fr/meteo/widget/daily/saint-jean-pied-de-port_france_2979207?geoloc=fixed&days=2&tempunit=CELSIUS&windunit=KILOMETER_PER_HOUR&precipunit=MILLIMETER&coloured=coloured&pictoicon=0&pictoicon=1&maxtemperature=0&maxtemperature=1&mintemperature=0&mintemperature=1&windspeed=0&windgust=0&winddirection=0&uv=0&humidity=0&precipitation=0&precipitation=1&precipitationprobability=0&spot=0&pressure=0&layout=light" frameborder="0" scrolling="NO" allowtransparency="true" sandbox="allow-same-origin allow-scripts allow-popups allow-popups-to-escape-sandbox" style="width: 108px; height: 210px"></iframe><!-- DO NOT REMOVE THIS LINK --><a href="https://www.meteoblue.com/fr/meteo/semaine/saint-jean-pied-de-port_france_2979207?utm_source=weather_widget&utm_medium=linkus&utm_content=daily&utm_campaign=Weather%2BWidget" target="_blank"></a></div>
</div>
</div>
<div class ="container2">
<div class ="row">
<div id="chart1" class='small.item'>
<canvas id="myChart"></canvas>
</div>
<div id="chart4" class='small.item4'>
<canvas id="bar-chart-grouped"></canvas>
</div>
</div>
</div>
<br>
<div class ="container2">
<div class ="row">
<div id="chart5" class='small.item5'>
<canvas id="mixed-chart"></canvas>
</div>
<div id="chart6" class='small.item6'>
<canvas id="mixed-chart2"></canvas>
</div>
</div>
</div>
<br>
<div class ="container2">
<div class ="row">
<div id="chart7" class='small.item7'>
<canvas id="bar-chart-grouped-7"></canvas>
</div>
<div id="chart8" class='small.item8'>
<canvas id="bar-chart-grouped-8"></canvas>
</div>
</div>
</div>
<br>
<div id="chart9" class='small.item9'>
<canvas id="bar-chart-grouped-9"></canvas>
</div>
<script>
var listedate
var listedate="<option>Veuillez choisir une date</option>"
$.getJSON("connect/selectdate.php", function(data){
for(var i=0;i<data.tabdate.length;i++){
listedate+="<option value='"+data.tabdate[i].egun+"'> "+data.tabdate[i].egun+"</option>"
}
$("#date").append(listedate)
}).done(function(){
$("#date").css('display','block')
})
var quelledate
$("#date").change(function(){
quelledate=$(this).val()
})
var listecreneauhoraire
var listecreneauhoraire="<option>Veuillez choisir un créneau horaire</option>"
$.getJSON("connect/selectcreneauhoraire.php", function(data){
for(var i=0;i<data.tabcreneauhoraire.length;i++){
listecreneauhoraire+="<option value='"+data.tabcreneauhoraire[i].tenorea+"'> "+data.tabcreneauhoraire[i].tenorea+"</option>"
}
$("#creneauhoraire").append(listecreneauhoraire)
}).done(function(){
$("#creneauhoraire").css('display','block')
})
var quelcreneau
$("#creneauhoraire").change(function(){
quelcreneau=$(this).val()
afficheplaces()
affichedonnees()
affichedonnees2()
affichedonnees3()
affichedonnees4()
affichedonnees5()
affichedonnees6()
})
var texteliste=""
var donnees=[]
var date=[]
var creneauhoraire=[]
var placesoccupees=[]
function afficheplaces(){
$.getJSON("json/parking.json", function(data){
for(var i=0;i<data.length;i++){
if (data[i].date==quelledate & data[i].creneauhoraire==quelcreneau){
donnees.push([data[i].creneauhoraire,data[i].placesoccupees])
}
}
console.log(donnees)
for(var i=0;i<donnees.length;i++){
creneauhoraire.push(donnees[i][0])
placesoccupees.push(donnees[i][1])
}
}).done(function(){
creelegraph()
})
}
function creelegraph(){
let bgColors=$.map(placesoccupees,function(value,i){
return value<567?"green":value>567 && value<850?"orange":value>=850&&value<=1133?"red":value>1133?"black":"none";
});
var ctx = document.getElementById('myChart').getContext('2d');
var myChart = new Chart(ctx, {
type: 'doughnut',
data: {
labels: [placesoccupees + ' places de parkings occupées sur 1133'],
datasets: [{
label: 'Créneau horaire',
backgroundColor: bgColors,
borderColor: [bgColors],
data: placesoccupees
}]
},
options: {
circumference : 1 * Math.PI,
rotation : 1 * Math.PI,
}
});
}
var texteliste=""
var donnees4=[]
var date=[]
var creneauhoraire4=[]
var volumefvt=[]
var volumeeco=[]
function affichedonnees(){
$.getJSON("json/combine.json", function(data){
for(var i=0;i<data.length;i++){
if (data[i].date==quelledate & data[i].creneauhoraire==quelcreneau){
donnees4.push([data[i].creneauhoraire,data[i].volumefvt,data[i].volumeeco])
}
}
console.log(donnees4)
for(var i=0;i<donnees4.length;i++){
creneauhoraire4.push(donnees4[i][0])
volumefvt.push(donnees4[i][1])
volumeeco.push(donnees4[i][2])
}
}).done(function(){
creelegraph1()
})
}
function creelegraph1(){
var chart4=new Chart(document.getElementById("bar-chart-grouped").getContext('2d'), {
type: 'bar',
data: {
labels: [creneauhoraire],
datasets: [
{
label: 'Fréquentation FVT',
backgroundColor: "#d11d5d",
data: volumefvt
}, {
label: 'Fréquentation éco compteurs',
backgroundColor: "grey",
data: volumeeco
}
]
},
options: {
title: {
display: true,
text: 'Comparatif FVT / éco compteurs'
}
}
});
}
var texteliste=""
var donnees5=[]
var date=[]
var creneauhoraire5=[]
var freqecocompteurs=[]
var ozone=[]
function affichedonnees2(){
$.getJSON("json/ecopollution.json", function(data){
for(var i=0;i<data.length;i++){
if (data[i].date==quelledate & data[i].creneauhoraire==quelcreneau){
donnees5.push([data[i].creneauhoraire,data[i].freqecocompteurs,data[i].ozone])
}
}
console.log(donnees5)
for(var i=0;i<donnees5.length;i++){
creneauhoraire5.push(donnees5[i][0])
freqecocompteurs.push(donnees5[i][1])
ozone.push(donnees5[i][2])
}
}).done(function(){
creelegraph2()
})
}
function creelegraph2(){
let bgColors=$.map(ozone,function(value,i){
return value<50?"green":value>50 && value<100?"orange":value>100?"black":"none";
});
var chart5=new Chart(document.getElementById("mixed-chart").getContext('2d'), {
type: 'bar',
data: {
labels: [creneauhoraire],
datasets: [{
label: "Taux d'ozone",
type: "line",
borderColor: "grey",
backgroundColor: bgColors,
data: ozone,
fill: false
}, {
label: "Fréquentation",
type: "bar",
backgroundColor: "#d11d5d",
data: freqecocompteurs,
}
]
},
options: {
title: {
display: true,
text: 'Fréquentation et pollution'
},
legend: { display: false }
}
});
};
var texteliste=""
var donnees6=[]
var date=[]
var creneauhoraire6=[]
var volumeecorecla=[]
var nombrereclamation=[]
function affichedonnees3(){
$.getJSON("json/ecoreclamation.json", function(data){
for(var i=0;i<data.length;i++){
if (data[i].date==quelledate & data[i].creneauhoraire==quelcreneau){
donnees6.push([data[i].creneauhoraire,data[i].volumeecorecla,data[i].nombrereclamation])
}
}
console.log(donnees6)
for(var i=0;i<donnees6.length;i++){
creneauhoraire6.push(donnees6[i][0])
volumeecorecla.push(donnees6[i][1])
nombrereclamation.push(donnees6[i][2])
}
}).done(function(){
creelegraph3()
})
}
function creelegraph3(){
let bgColors=$.map(nombrereclamation,function(value,i){
return value<1?"green":value>1 && value<2?"orange":value>=2&&value<=3?"red":value>3?"black":"none";
});
var chart6=new Chart(document.getElementById("mixed-chart2").getContext('2d'), {
type: 'bar',
data: {
labels: [creneauhoraire],
datasets: [{
label: "Réclamations",
type: "line",
borderColor: "grey",
backgroundColor:bgColors,
data: nombrereclamation,
fill: true
}, {
label: "Fréquentation",
type: "bar",
backgroundColor: "#d11d5d",
data: volumeecorecla,
}
]
},
options: {
title: {
display: true,
text: 'Fréquentation et réclamations'
},
legend: { display: false }
}
});
}
var texteliste=""
var donnees7=[]
var date=[]
var creneauhoraire7=[]
var caresto=[]
var freqresto=[]
function affichedonnees4(){
$.getJSON("json/restos.json", function(data){
for(var i=0;i<data.length;i++){
if (data[i].date==quelledate & data[i].creneauhoraire==quelcreneau){
donnees7.push([data[i].creneauhoraire,data[i].caresto,data[i].freqresto])
}
}
console.log(donnees7)
for(var i=0;i<donnees7.length;i++){
creneauhoraire7.push(donnees7[i][0])
caresto.push(donnees7[i][1])
freqresto.push(donnees7[i][2])
}
}).done(function(){
creelegraph4()
})
}
function creelegraph4(){
var chart7=new Chart(document.getElementById("bar-chart-grouped-7").getContext('2d'), {
type: 'bar',
data: {
labels: [creneauhoraire],
datasets: [
{
label: "Fréquentation des restaurants",
backgroundColor: "#d11d5d",
data: freqresto,
}, {
label: "CA des restaurants",
backgroundColor: "grey",
data: caresto,
}
]
},
options: {
title: {
display: true,
text: 'Fréquentation et CA des restaurants'
}
}
});
}
var texteliste=""
var donnees8=[]
var date=[]
var creneauhoraire8=[]
var catotalsite=[]
var frequentationsite=[]
function affichedonnees5(){
$.getJSON("json/sites.json", function(data){
for(var i=0;i<data.length;i++){
if (data[i].date==quelledate & data[i].creneauhoraire==quelcreneau){
donnees8.push([data[i].creneauhoraire,data[i].catotalsite,data[i].frequentationsite])
}
}
console.log(donnees8)
for(var i=0;i<donnees8.length;i++){
creneauhoraire8.push(donnees8[i][0])
catotalsite.push(donnees8[i][1])
frequentationsite.push(donnees8[i][2])
}
}).done(function(){
creelegraph5()
})
}
function creelegraph5(){
var chart8=new Chart(document.getElementById("bar-chart-grouped-8").getContext('2d'), {
type: 'bar',
data: {
labels: [creneauhoraire],
datasets: [
{
label: "Fréquentation des sites",
backgroundColor: "#d11d5d",
data: frequentationsite
}, {
label: "CA total des sites",
backgroundColor: "grey",
data: catotalsite
}
]
},
options: {
title: {
display: true,
text: 'CA total des sites en fonction de la fréquentation'
}
}
});
}
var texteliste=""
var donnees9=[]
var date=[]
var creneauhoraire9=[]
var catotalcommerces=[]
var frequentationcommerces=[]
function affichedonnees6(){
$.getJSON("json/commerces.json", function(data){
for(var i=0;i<data.length;i++){
if (data[i].date==quelledate & data[i].creneauhoraire==quelcreneau){
donnees9.push([data[i].creneauhoraire,data[i].catotalcommerces,data[i].frequentationcommerces])
}
}
console.log(donnees9)
for(var i=0;i<donnees9.length;i++){
creneauhoraire9.push(donnees9[i][0])
catotalcommerces.push(donnees9[i][1])
frequentationcommerces.push(donnees9[i][2])
}
}).done(function(){
creelegraph6()
})
}
function creelegraph6(){
var chart9=new Chart(document.getElementById("bar-chart-grouped-9").getContext('2d'), {
type: 'bar',
data: {
labels: [creneauhoraire],
datasets: [
{
label: "Fréquentation des commerces",
backgroundColor: "#d11d5d",
data: frequentationcommerces
}, {
label: "CA total des commerces",
backgroundColor: "grey",
data: catotalcommerces
}
]
},
options: {
title: {
display: true,
text: 'CA total des commerces en fonction de la fréquentation'
}
}
});
}
myChart.destroy();
chart4.destroy();
chart5.destroy();
chart6.destroy();
chart7.destroy();
chart8.destroy();
</script>
<script src="js/chart.js"></script>
</section>
</div>
</div>
<!-- Sidebar -->
<div id="sidebar">
<div class="inner">
<!-- Menu -->
<nav id="menu">
<header class="major">
<h2>Menu</h2>
</header>
<ul>
<li><a href="index.html">Page d'accueil</a></li>
<li><a href="avertissement.html">Avertissement</a></li>
<li><a href="legende.html">Légende des indicateurs</a></li>
<li><a href="ongletgraphjour.html">Tableau de bord journalier</a></li>
<li><a href="tableaudebordcreneauhoraire.html">Tableau de bord journalier et créneau horaire</a></li>
<li><a href="evolutionjauge.html">Tableau de bord comparatif plusieurs années</a></li>
</nav>
<!-- Footer -->
<footer id="footer">
<p class="copyright">© Maïtena Haristouy. Design: <a href="https://html5up.net">HTML5 UP</a>.</p>
</footer>
</div>
</div>
</div>
<!-- Scripts -->
<script src="assets/js/jquery.min.js"></script>
<script src="assets/js/browser.min.js"></script>
<script src="assets/js/breakpoints.min.js"></script>
<script src="assets/js/util.js"></script>
<script src="assets/js/main.js"></script>
</body>
</html> |
Partager