Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

  • Isomorphic
    replied
    Hi Mathias

    We see the behavior you are describing

    We'll take a look at this case, but for now you can get past this by explicitly clearing out the data object and re-fetching instead of relying on invalidateCache() after setting the operation ID.
    This can be achieved with a 'setData(...)' call, passing in an empty list, then calling 'fetchData()' to re-fetch with the new fetchOperation

    Regards
    Isomorphic Software

    Leave a comment:


  • mathias
    replied
    Doesn't matter, once you set it, the grid will use that operationId in requests forever, from what I can tell.
    Code:
    private void handleOperationId(boolean setEnabled){
            String newOpId = setEnabled ? operationId : "fetch";
            GWT.log("handleOperationId: " + operationId + ", setEnabled: " + setEnabled +  ", setting operation to: " + newOpId);
            grid.setFetchOperation(newOpId);
        }
    If you set it to fetch or anything else first, it will always have that, and the other way around.
    Last edited by mathias; 26 Nov 2024, 03:53.

    Leave a comment:


  • Blama
    replied
    Hi mathias,

    what happens with
    Code:
    grid.setFetchOperation(setEnabled ? operationId : "fetch")
    ?

    Best regards
    Blama

    Leave a comment:


  • Set operationId on listgrid multiple times not working?

    Hello,

    just tried this on a list grid:

    Code:
    private void handleOperationId(boolean setEnabled){
            GWT.log("handleOperationId: " + operationId + ", setEnabled: " + setEnabled);
            grid.setFetchOperation(setEnabled ? operationId : null);
        }
    But it seems that after you set it once, it doesn't change? After my method above, I do invalidateCache, and it still uses the old operation when fetching.
Working...
X