Datatable rendering taking 10 sec to load 2000 rows
Datatable rendering taking 10 sec to load 2000 rows
Hi
We are using jquery datatable to render about 2300 records.we have 15 columns in it and out of 15 , 8 columns are using custom renderers like placing images in it. We are also having client side pagination.What can we make to decrease the grid load time.Below is example of one column renderer. We have similar renderers across 8 columns.I heard about deferRender attribute.Does it help my case.And also am doing some operation on createdRow
{
"render": function ( data, type, row ) {
var catetatus = row.categoriesStatus;
var output = convertTimeFromMs(data, type, row );
var imageStr = '<img alt="5:" src="/IpvodWebApp/resources/images/white.gif" height="1" width="1"/>';
var sortingTime;
if(data == undefined)
data = "";
else
sortingTime = millitoMinutes(data);
if(catetatus == 'Posted' && output.length > 0)
imageStr = '<img alt="1:'+ sortingTime +'" src="/IpvodWebApp/resources/images/whitecircle.png" />';
if(catetatus == 'Queued' && output.length > 0)
imageStr = '<img alt="2:'+ sortingTime +'" src="/IpvodWebApp/resources/images/waitcircle.png" />';
if(catetatus == 'Working' && output.length > 0)
imageStr = '<img alt="3:'+ sortingTime +'" src="/IpvodWebApp/resources/images/loading_image.png" />';
if(catetatus == 'Completed' && output.length > 0)
imageStr = '<img alt="4:'+ sortingTime +'" src="/IpvodWebApp/resources/images/green.png" />';
return imageStr + '<p title=\"'+ convertUTCDatetoLocalDate(data) +'\">' + output + '</p >';
},
"data": "categoriesTime",
"defaultContent": "",
"type": "alt-string",
"targets": [10],
"width": "97px"
},