diff options
Diffstat (limited to 'app/Resources/views/default/AllDataPage.html.twig')
-rw-r--r-- | app/Resources/views/default/AllDataPage.html.twig | 49 |
1 files changed, 24 insertions, 25 deletions
diff --git a/app/Resources/views/default/AllDataPage.html.twig b/app/Resources/views/default/AllDataPage.html.twig index 429e13e..4607049 100644 --- a/app/Resources/views/default/AllDataPage.html.twig +++ b/app/Resources/views/default/AllDataPage.html.twig @@ -1,30 +1,29 @@ -<!DOCTYPE html> -<html lang="en"> -<head> - <meta charset="UTF-8"> - <title>All Pollution Data | Pollutometer</title> - <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.7.1/Chart.bundle.min.js"></script> -</head> -<body> -<table border="1"> - <tr> - <th>TimeStamp</th> - <th>Co</th> - <th>No</th> - <th>So</th> - </tr> - <tr> - {% for table in data %} - <td>{{ table.TimeStamp }}</td> - <td>{{ table.Co }}</td> - <td>{{ table.No }}</td> - <td>{{ table.So }}</td> - </tr> +{% extends 'base.html.twig' %} + +{% block body %} +<table class="table"> + <thead class="thead"> + <tr class="tr"> + <th>TimeStamp</th> + <th>Co</th> + <th>No</th> + <th>So</th> + </tr> + </thead> + <tbody class="tbody"> + <tr class="tr"> + {% for table in data %} + <td class="td">{{ table.TimeStamp }}</td> + <td class="td">{{ table.Co }}</td> + <td class="td">{{ table.No }}</td> + <td class="td">{{ table.So }}</td> + </tr> + </tbody> {% endfor %} </table> <canvas id="ctx"></canvas> -</body> +{% endblock %} {% block javascripts %} + <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.7.1/Chart.bundle.min.js"></script> <script src="{{ asset('js/chartOfReadings.js') }}"></script -{% endblock %} -</html>
\ No newline at end of file +{% endblock %}
\ No newline at end of file |