jQWidgets Forums

jQuery UI Widgets Forums Grid Nested Grid refresh data

This topic contains 7 replies, has 5 voices, and was last updated by  ziggy 9 years ago.

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
  • Nested Grid refresh data #14829

    Good day,
    Currently I am working with nested grid using the code in your DEMO “Nested Grid”. Works perfectly fine, it INSERT the data to my Database. My question is how can I refresh nested grid? I tried ==> $(“#jqxgrid”).jqxGrid(‘updatebounddata’); but this is not the grid that I want to refresh, the grid that I want to refresh after saving to DB = = >> $(“#grid”).jqxGrid(‘updatebounddata’) but its not working!

    Thanks in advance for your help.

    Nested Grid refresh data #14833

    Peter Stoev
    Keymaster

    Hi Mcgyver,

    When you create the Nested Grids in the “initrowdetails” callback, you may store the nested Grid’s HTML Element in a custom Array. Then when you want to refresh these nested Grids, loop through your array and call their “updatebounddata” method.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Nested Grid refresh data #14835

    hello Peter!

    A BIG Thanks for a fast reply.

    Just to give you an additional info on what I’m doing, I integrate the popup editing to a Nested grid again base on the demo!
    so when I click the edit button on the popup editing (I change the edit button to save button) it will save to my database no problem with saving it saves the data. Can you please give me an example on how to do it base on the example demo!

    Thanks again!

    Nested Grid refresh data #59391

    kev1989
    Participant

    Hi peter, would you mind showing an example of what you mentioned above. i too have run into this hickup and cant seem to find a way around it.

    Nested Grid refresh data #67156

    ziggy
    Participant

    a code of a working sample would help a lot of us. Thanks

    Nested Grid refresh data #67160

    Peter Stoev
    Keymaster

    Hi Karen,

    Unfortunately, we do not have example for exactly that scenario. Within the “initrowdetails” function store the passed HTML Elements within an array. When you want to refresh a nested Grid data, use that array i.e something like $(array[0]).jqxGrid(‘updatebounddata’) or $(array[0]).jqxGrid({source: newAdapter});

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Nested Grid refresh data #76937

    netto.paulo
    Participant

    Jack, you got it?

    Nested Grid refresh data #83393

    ziggy
    Participant

    Hi Peter,

    I assigned a specific id for the nested grid

    
     var grid = $($(parentElement).children()[0]);
            $(grid).attr('id', 'details_' + id);

    However, I get the error

    jqxcore.js:7 Uncaught Error: Invalid Selector - #details_2! Please, check whether the used ID or CSS Class name is correct. 
    

    when I tried to $(“#details_2”).jqxGrid(“updatebounddata”);

    Help.

    Thanks!

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.