Why im getting datatables warning table id=datatables ajax error

Why im getting datatables warning table id=datatables ajax error

tetsuphyxiatetsuphyxia Posts: 21Questions: 4Answers: 0
edited January 2020 in Free community support

heres my code

 function fill_dataTable(status=''){
      var invoiceTable = $("#invoiceTable").DataTable({
        processing: true,
        serverSide: true,
        ajax:{
          url: '/salesinvoice/'+'{{$client->id}}',
          data: {status : status}
        },
        columns:[
              {data:'invoice_number'},
              {data:'invoice_date'},
              {data:'dr_no'},
              {data:'dr_date'},
              {data:'received_date'},
              {data:'maturity'},
              {data:'amount', render: $.fn.dataTable.render.number( ',', '.', 2) },
              {data:'running_amount', render: $.fn.dataTable.render.number( ',', '.', 2) },
            {~~~~

Edited by Colin - Syntax highlighting. Details on how to highlight code using markdown can be found in this guide.

Replies

  • tetsuphyxiatetsuphyxia Posts: 21Questions: 4Answers: 0

    if i comment the serverSide theres no error

  • colincolin Posts: 15,237Questions: 1Answers: 2,598

    For server side processing, the protocol is discussed here. Also see examples here.

    I suspect your server isn't sending data back in the expected format.

    Cheers,

    Colin

This discussion has been closed.