Closed malohtie closed 5 years ago
Hi when im trying to group my data by column it working but i see a duplicate group i believe it a bug ? here is a screen shoot
also my grouping code
rowGroup: { startRender: function ( rows, group ) { console.log(rows); console.log(group); return $("<tr/>") .append( "<td colspan=\"7\" align=\"center\">Entity : "+group.toUpperCase()+"</td>" ); }, endRender: null, dataSrc: "entity" },
when using console log it show me this
finally my json data
"data":[{"id":3,"username":"mohamed","full_name":"alami ahmed","role":"leader","is_active":true,"team":"none","entity":"sqsq","nb_logs":"0"},{"id":4,"username":"cvxcvxcv","full_name":"cxxcvxx","role":"mailer","is_active":true,"team":"hotmail","entity":"prosoft","nb_logs":"0"},{"id":1,"username":"admin","full_name":"Mohamed Amine","role":"admin","is_active":true,"team":"admin","entity":"prosoft","nb_logs":"4"},{"id":5,"username":"vbccvb","full_name":"cvbvcbcvb","role":"admin","is_active":true,"team":"admin","entity":"prosoft","nb_logs":"0"}]
ps version used : <script type="text/javascript" src="https://cdn.datatables.net/v/bs4/dt-1.10.18/b-1.5.6/r-2.2.2/rg-1.1.0/datatables.min.js"></script>
<script type="text/javascript" src="https://cdn.datatables.net/v/bs4/dt-1.10.18/b-1.5.6/r-2.2.2/rg-1.1.0/datatables.min.js"></script>
thanks
Ok seem that i need to order by the same fields
order: [[3, "asc"],[4, "asc"]], rowGroup: { dataSrc: [3, 4] },
Hi when im trying to group my data by column it working but i see a duplicate group i believe it a bug ? here is a screen shoot
also my grouping code
when using console log it show me this
finally my json data
"data":[{"id":3,"username":"mohamed","full_name":"alami ahmed","role":"leader","is_active":true,"team":"none","entity":"sqsq","nb_logs":"0"},{"id":4,"username":"cvxcvxcv","full_name":"cxxcvxx","role":"mailer","is_active":true,"team":"hotmail","entity":"prosoft","nb_logs":"0"},{"id":1,"username":"admin","full_name":"Mohamed Amine","role":"admin","is_active":true,"team":"admin","entity":"prosoft","nb_logs":"4"},{"id":5,"username":"vbccvb","full_name":"cvbvcbcvb","role":"admin","is_active":true,"team":"admin","entity":"prosoft","nb_logs":"0"}]
ps version used :
<script type="text/javascript" src="https://cdn.datatables.net/v/bs4/dt-1.10.18/b-1.5.6/r-2.2.2/rg-1.1.0/datatables.min.js"></script>
thanks