Update registration report data tables
Use latest version of DataTables CSS and JS. Change to Bootstrap 4 styles for DataTables.
This commit is contained in:
parent
37a02c1704
commit
a06be640a4
1 changed files with 34 additions and 23 deletions
|
@ -25,7 +25,7 @@
|
||||||
{% if report.headings %}
|
{% if report.headings %}
|
||||||
<table class="table table-striped table-reportdata">
|
<table class="table table-striped table-reportdata">
|
||||||
{% else %}
|
{% else %}
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
|
@ -47,32 +47,43 @@
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<hr />
|
<hr class="my-5" />
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block extra_script %}
|
{% block extra_script %}
|
||||||
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/v/bs/jszip-2.5.0/dt-1.10.16/b-1.4.2/b-colvis-1.4.2/b-flash-1.4.2/b-html5-1.4.2/b-print-1.4.2/cr-1.4.1/fc-3.2.3/fh-3.1.3/r-2.2.0/rg-1.0.2/datatables.min.css"/>
|
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/v/bs4/jszip-2.5.0/dt-1.10.20/b-1.6.0/b-colvis-1.6.0/b-html5-1.6.0/b-print-1.6.0/cr-1.5.2/fc-3.3.0/fh-3.1.6/r-2.2.3/rg-1.1.1/datatables.min.css"/>
|
||||||
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script>
|
|
||||||
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script>
|
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script>
|
||||||
<script type="text/javascript" src="https://cdn.datatables.net/v/bs/jszip-2.5.0/dt-1.10.16/b-1.4.2/b-colvis-1.4.2/b-html5-1.4.2/b-print-1.4.2/cr-1.4.1/fc-3.2.3/fh-3.1.3/r-2.2.0/rg-1.0.2/datatables.min.js"></script>
|
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script>
|
||||||
|
<script type="text/javascript" src="https://cdn.datatables.net/v/bs4/jszip-2.5.0/dt-1.10.20/b-1.6.0/b-colvis-1.6.0/b-html5-1.6.0/b-print-1.6.0/cr-1.5.2/fc-3.3.0/fh-3.1.6/r-2.2.3/rg-1.1.1/datatables.min.js"></script>
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
$("table.table-reportdata").dataTable({
|
$("table.table-reportdata").dataTable({
|
||||||
"dom": "<'row'<'col-md-3'l><'col-md-3'B><'col-md-4'f>r>t<'row'<'col-md-3'i><'col-md-5'p>>",
|
"dom":
|
||||||
|
"<'row'<'col-sm-12 col-md-3'l><'col-sm-12 col-md-5'B><'col-sm-12 col-md-4'f>>" +
|
||||||
|
"<'row'<'col-sm-12'tr>>" +
|
||||||
|
"<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
|
||||||
"stateSave": true,
|
"stateSave": true,
|
||||||
"lengthMenu": [[10, 50, 100, -1], [10, 50, 100, "All"]],
|
"lengthMenu": [[10, 50, 100, -1], [10, 50, 100, "All"]],
|
||||||
"pageLength": 100,
|
"pageLength": 100,
|
||||||
"buttons": [ "csv", "print", {
|
"buttons": [
|
||||||
|
"csv",
|
||||||
|
"print",
|
||||||
|
{
|
||||||
extend: 'copy',
|
extend: 'copy',
|
||||||
text: 'Copy',
|
text: 'Copy',
|
||||||
exportOptions: {
|
exportOptions: {
|
||||||
columns: ':visible'
|
columns: ':visible'
|
||||||
}},
|
}
|
||||||
{ extend: 'collection',
|
},
|
||||||
|
{
|
||||||
|
extend: 'collection',
|
||||||
text: 'Columns',
|
text: 'Columns',
|
||||||
buttons: [ 'columnsToggle']
|
buttons: [ 'columnsToggle']
|
||||||
}]
|
}
|
||||||
|
]
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
Loading…
Reference in a new issue