Nested Datatables 1.10.11
Nested Datatables version 1.10.11.
HTML
<link rel="stylesheet" href="https://cdn.datatables.net/1.10.11/css/jquery.dataTables.min.css">
<script src="https://cdn.datatables.net/1.10.11/js/jquery.dataTables.min.js"></script>
<script src="https://cdn.datatables.net/1.10.11/js/dataTables.bootstrap.min.js"></script>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
<table id="opiniondt" class="display" cellspacing="0" width="100%" >
<thead >
<tr >
<th></th>
<th width="10%" >time</th>
<th width="20%" >reason</th>
<th width="70%">range</th>
<th style="display: none;"></th>
</tr>
</thead>
<tr><td></td><td></td><td></td><td></td></tr>
</table>
CSS
td.details-control {
background: url('http://i.imgur.com/SD7Dz.png') no-repeat center center;
cursor: pointer;
}
tr.shown td.details-control {
background: url('http://i.imgur.com/SD7Dz.png') no-repeat center center;
}
JavaScript
var options = [{
"aggr_id": "5",
"starttime": "2016-10-03 10:52:15",
"rs": "down ",
"loc": "ad0/7/0/19"
}, {
"aggr_id": "5",
"starttime": "2016-10-03 10:52:15",
"rs": "user error ",
"loc": "ad0/7/0/19,"
}, {
"aggr_id": "5",
"starttime": "2016-10-03 10:52:15",
"rs": "pwd error ",
"loc": "2-02_ad0/7/0/19"
}, {
"aggr_id": "5",
"starttime": "2016-10-03 10:52:15",
"rs": "pwd error ",
"loc": "2-02_ad0/7/0/19"
}, {
"aggr_id": "5",
"starttime": "2016-10-03 10:52:15",
"rs": "pwd error ",
"loc": "2-02_ad0/7/0/19"
}, {
"aggr_id": "5",
"starttime": "2016-10-03 10:52:15",
"rs": "pwd error ",
"loc": "2-02_ad0/7/0/19"
}
];
var sections = [
[{
"eventtime": "2016-10-07 13:55:21",
"device": "01",
"ip": "10.10.232.3",
"info": "ad0\/8\/0\/0",
"remark": "116"
}, {
"eventtime": "2016-10-07 13:55:21",
"device": "10-01",
"ip": "10.10.242.3",
"info": "N/A",
"remark": "N/A"
}, {
"eventtime": "2016-10-07 13:55:21",
"device": "10-01",
"ip": "10.10.240.3",
"info": "N/A",
"remark": "N/A"
}, {
"eventtime": "2016-10-07 13:55:21",
"device": "10-01",
"ip": "10.10.243.3",
"info": "ad0\/6\/1\/4",
"remark": "64"
}],
[{
"eventtime": "2016-10-03 10:52:11",
"device": "01",
"ip": "10.10.230.3",
"info": "ad0\/8\/0\/2",
"remark": "74"
}, {
"eventtime": "2016-10-03 10:52:15",
"device": "AHL",
"ip": "10.110.201.42",
"info": "N\/A",
"remark": "N\/A"
}],
[{
"eventtime": "2016-10-03 10:52:11",
"device": "10-01",
"ip": "10.10.246.3",
"info": "ad0\/6\/1\/2",
"remark": "62"
}, {
"eventtime": "2016-10-03 10:52:11",
"device": "10-01",
"ip": "10.10.10.3",
"info":...