Eliminating the sorting icons from column rows
Eliminating the sorting icons from column rows
mkhan0104
Posts: 2Questions: 0Answers: 0
I have tried searching for this in various ways and haven't found anything relevant so I am posting this as a question and hopefully someone can help out.
I have sorting enabled using "bSortable" in "aoColumnDefs" and defined like so:
[code]
"aoColumnDefs": [
{ "bSortable": false, "aTargets": [0] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [1] },
{ "bSortable": true, "sWidth": '110px', "aTargets": [2] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [3] },
{ "bSortable": false, "aTargets": [4] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [5] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [6] },
{ "bSortable": true, "sWidth": '200px', "aTargets": [7] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [8] }
],
[/code]
The "bSortable" option causes all the rows that have sorting enabled to display the sorting icon on each row. I just want the sorting icon to appear in the header for the columns that need to be sorted. I am not sure if there is something I am doing wrong in the I am defining it above or should I target this in CSS and somehow force it not to display the icons in the rows.
Thank You.
I have sorting enabled using "bSortable" in "aoColumnDefs" and defined like so:
[code]
"aoColumnDefs": [
{ "bSortable": false, "aTargets": [0] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [1] },
{ "bSortable": true, "sWidth": '110px', "aTargets": [2] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [3] },
{ "bSortable": false, "aTargets": [4] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [5] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [6] },
{ "bSortable": true, "sWidth": '200px', "aTargets": [7] },
{ "bSortable": true, "sWidth": '100px', "aTargets": [8] }
],
[/code]
The "bSortable" option causes all the rows that have sorting enabled to display the sorting icon on each row. I just want the sorting icon to appear in the header for the columns that need to be sorted. I am not sure if there is something I am doing wrong in the I am defining it above or should I target this in CSS and somehow force it not to display the icons in the rows.
Thank You.
This discussion has been closed.
Replies
[code]
td.sorting, td.sorting_asc , td.sorting_desc , td.sorting_asc_disabled , td.sorting_desc_disabled
{
background: none;
}
[/code]
Just added the above to my page to temporarily fix the issue but I am assuming there is some better workaround for this in the way I am implementing it.