jQWidgets Forums

jQuery UI Widgets Forums Grid Create a grid with default state

This topic contains 7 replies, has 2 voices, and was last updated by  Mallikarjun Baddur 9 years, 3 months ago.

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
  • Create a grid with default state #79863

    Mallikarjun Baddur
    Participant

    I have a grid state at session storage, by default on grid initialization I need to load my grid with the available state. When I tried to load state in ‘ready’ callback function two server requests are triggered. How can I avoid two server requests?

    Please suggest me a way to create a grid with some state.

    Thanks,
    Mallikarjun

    Create a grid with default state #79864

    Peter Stoev
    Keymaster

    Hi Mallikarjun,

    You cannot avoid them if you have sorting and filtering saved in the state.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Create a grid with default state #79865

    Mallikarjun Baddur
    Participant

    Hi Peter,

    Thanks for reply. Is there any way to stop adapter automatic server request call, so that I can stop that when I have any grid state.

    Regards,
    Mallikarjun

    Create a grid with default state #79866

    Peter Stoev
    Keymaster

    Hi Mallikarjun,

    The adapter does not make automatic server requests unless you load such saved state. No, you cannot stop these.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Create a grid with default state #79868

    Mallikarjun Baddur
    Participant

    Hi Peter,

    Here are two server requests

    1) On grid initialization automatic data adapter call (This call doesn’t contain any sort and filter params)
    2) When a grid state is loaded a call with sort and filter params

    So When I have any previous grid state, I need to stop automatic data adapter call and use only load state call.

    Or please suggest any other mechanism to initialize grid with default sort and filter on few columns.

    Thanks & Regards,
    Mallikarjun

    Create a grid with default state #79872

    Peter Stoev
    Keymaster

    Hi Mallikarjun,

    I understand, but that is how the Grid works. It data binds to the data adapter, then you Load the state via the Grid’s API or by turning on autoloadstate and the Grid will make a request with filter, sort, etc params.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Create a grid with default state #79918

    Mallikarjun Baddur
    Participant

    Hi Peter,

    I will try using ‘autoloadstate’ option. How could I remove saved grid state?

    Regards,
    Mallikarjun

    Create a grid with default state #80032

    Mallikarjun Baddur
    Participant

    Hi,

    Any update on this please. I just need to remove grid state when user is logged out. How could I achieve that, please assist me.

    Thanks,
    Mallikarjun

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

You must be logged in to reply to this topic.