< 1 min read

    var oTable;
    fnServerObjectToArray = function () {
        return function (sSource, aoData, fnCallback) {
            $.ajax({
                "dataType": 'json',
                "type": "GET",
                "url": sSource,
                "data": 'datefrom=' + $('#DateFromUniqueUsers').val() + '&dateto=' + $('#DateToUniqueUsers').val() + '&DateRange=' + $('#DateRangeUniqueUsers').val(),
                "success": function (json) {
                    var a = [];
                    for (var i = 0, iLen = json.aaData.length; i < iLen; i++) {
                        var inner = [];
                        inner.push(json.aaData[i].Email);
                        inner.push(json.aaData[i].Name);
                        inner.push(json.aaData[i].Office);
                        a.push(inner);
                    }
                    json.aaData = a;
                    fnCallback(json);
                }
            });
        }
    }