Announcement

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

    fetchData criteria on operationBinding with operationId

    How to apply criteria for fetchData on a data source with operationId? For example on:

    Code:
    isc.DataSource.get("test_ds").fetchData({type_id:5}, function(dsRequest, data){
    
    console.log(data)
    
    }, {operationId: "custom_fetch"})
    the fetched data return all the rows without taking into account the criteria i provide. The field type_id in my data source file, does not have the customSQL attribute, it's a normal integer field. This happens only when using a custom fetch operation, using the default one works as expected.

    Using SmartClient Version: v11.1p_2021-05-26/Enterprise Deployment (built 2021-05-26)

    Thank you

    #2
    There's no enough information here to help. There are lots of ways this could be broken:

    1. if you typo'd the field name

    2. if the opertaionId isn't actually declared in the DS

    3. if you've added server logic that breaks normal criteria processing

    .. etc ..

    Take a look at the Debugging overview to understand the information you need to provide in order to make it possible for people to help you.

    Comment


      #3
      Hi Isomorphic,

      Thank you for replying. I figured it out. I neglected to add "where $defaultWhereClause" on my query, that's why the criteria was not working as expected. :rolleyes:

      Thank you nevertheless

      Comment

      Working...
      X