iwa-panda2

Manage Weather Data by International Weather Agency (Version 2)
Log | Files | Refs | README

commit b5a37a91fc09122509f2531dd6d0895c78cd3661
parent 0ebcc9611c9d2cfeb23e77093696f4f3235f9bc3
Author: Kninteman <[email protected]>
Date:   Mon, 12 Jun 2023 17:15:08 +0200

.

Diffstat:
MModel/Key.php | 1-
Mjs/panda.js | 13+++++++++----
2 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/Model/Key.php b/Model/Key.php @@ -47,7 +47,6 @@ Class Key{ function retrieveRBData($key){ $db = new mysqli("86.92.67.21", "friedel", "hailiwa", "wap2"); - $t = new Lollipop\Template(); $weather_data = []; $query = "SELECT distinct temperature, dew_point, nl.name as city FROM weather_data wd diff --git a/js/panda.js b/js/panda.js @@ -50,7 +50,7 @@ var myChart = new Chart(ctx, { labels: ['Measurement 1', 'Measurement 2', 'Measurement 3', 'Measurement 4', 'Measurement 5'], datasets: [ { - label: 'Dataset 1', + label: 'Chengdu Research Facility', data: [], backgroundColor: 'rgba(176, 204, 207, 1)', borderColor: 'rgba(176, 204, 207, 1)', @@ -70,11 +70,17 @@ var myChart = new Chart(ctx, { scales: { y: { beginAtZero: true, + grid: { + color: 'gray' + }, ticks: { color: 'white' } }, x: { + grid: { + color: 'gray' + }, ticks: { color: 'white' } @@ -102,6 +108,5 @@ function fetchDataAndUpdateChart() { myChart.update(); }) } - fetchDataAndUpdateChart(); -setInterval(fetchDataAndUpdateChart, 300000); -\ No newline at end of file +setInterval(fetchDataAndUpdateChart, 10000); +\ No newline at end of file