KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

Reload Datagrid with ajax #2461

Open Anjali opened this topic on on Nov 26, 2021 - 1 comments

Anjali commented on Nov 26, 2021

Hello, I have given table name in option while creating Datatable. but there is no way i can reload datatable without refreshing all page. Please suggest me . Datatable name is "faqs-table". I am using laravel with ajax and datagrid of koolreport.

 $('faqs-table').DataTable().ajax.reload();
Sebastian Morales commented on Nov 26, 2021

Pls use a name without space or dash like "faqsTable". Then ajax reload table is as following:

<?php
DataTables::create(array(
    "name" => "faqsTable",
    "serverSide" => true,
    ...
));
?>
<script>
    function reloadFaqsTable() {
        faqsTable.ajax.reload();
    }
</script>

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
help needed

None