Open amoriotechnology opened 1 year ago
I am trying to use ajax function in codeignitor to fetch data from the database and show the results in the bootgrid table. I received a valid json from controller. My json response is https://pastebin.com/As7gehP6
My script :
$(function() { var data = { csrfName: csrfHash }; $.ajax({ type: 'POST', data: data, dataType: "json", url: '<?php echo base_url();?>Cinvoice/CheckProfarmaInvoiceList', success: function(json, statut) { localStorage.setItem('json', JSON.stringify(json)); }); }); var grid = $("#document_data").bootgrid({ ajax: false, url: '<?php echo base_url();?>Cinvoice/CheckProfarmaInvoiceList' }); grid.bootgrid('append', localStorage.getItem('json'));
But data is not displaying in bootgrid table,the table is empty and Showing 1 to 10 of 1792 entries My output is :
Kindly helpme to solve this issue.
I am trying to use ajax function in codeignitor to fetch data from the database and show the results in the bootgrid table. I received a valid json from controller. My json response is https://pastebin.com/As7gehP6
My script :
But data is not displaying in bootgrid table,the table is empty and Showing 1 to 10 of 1792 entries My output is :
Kindly helpme to solve this issue.