This topic contains 0 replies, has 1 voice, and was last updated by  intelsa 2 months ago.

Datatable don't return "query" values using "getDataSourceQuery"


  • intelsa
    Participant

    Posts: 2
    Member Reply #19850

    I need help!.

    i use getDataSourceQuery to get current query datasource parameter, but it on Metronic v5.5.5 not work… I use it on v5.0.3 and it works well..

    This is the code:

    var query = datatable.getDataSourceQuery();     <——-  NOT WORK!

    $(‘#m_form_status’).on(‘change’, function () {
    // shortcode to datatable.getDataSourceParam(‘query’);
    var query = datatable.getDataSourceQuery();
    query.Status = $(this).val().toLowerCase();
    // shortcode to datatable.setDataSourceParam(‘query’, query);
    datatable.setDataSourceQuery(query);
    datatable.load();
    }).val(typeof query.Status !== ‘undefined’ ? query.Status : ”);

    • This topic was modified 2 months ago by  intelsa.

You must be logged in to reply to this topic.