Skip to content

Replies

0
S R
S R answered on Sep 23, 2014 6:17 PM

Hello Mike, I wish it was that simple. I been experimenting with this setting: $("#mRecordsTable").igGridFiltering( "filter", [], false );

The issue I have is that, when calling this line of code, even with the updateUI set to false, a webApi call gets launched in the back, one without filter.
Then after that, I use the following code to set the new filter: $("#mRecordsTable").igGridFiltering("filter", ([{ fieldName: 'IsSolved', expr: true, cond: 'equals'}]));
This immediately triggers a second apiWeb WITH parameter this time to be called.

In the hope to make it even cleare for you, this is an overview of the web-api calls that I can see in fiddler:

Initial .igGrid initialisation with datasource filter:

  • /api/mrecordapi/avalidID?%24orderby=Grouping+asc&%24filter=IsSolved+eq+false&%24skip=0&%24top=10&%24inlinecount=allpages

resetting the filter + setting the new filter as described above (2calls):

  • /api/mrecordapi/avalidID?%24orderby=Grouping+asc&%24skip=0&%24top=10&%24inlinecount=allpages
  • /api/mrecordapi/avalidID?%24orderby=Grouping+asc&%24filter=IsSolved+eq+true&%24skip=0&%24top=10&%24inlinecount=allpages

After this, sometimes the api call without filter gets shows or the one with the new filter gets shown, which results in very confusing behaviour.

Is this a known bug ? Do I need to configure more settings to avoid this behaviour ? Is there a workaround?!

Would realy appreciate if you could help me out with this one, I've been looking for a solution quite some time now.
Thanks