DropDownList makes duplicate requests when filtering is enabled and initial value is set

I've found that when enabling filtering and initializing a value on a DropDownList with a remote datasource (with offline set to true), duplicate requests to the remote datasource are made.


If the initial value is not set, or filtering is not enabled, only a single request is made to the remote datasource.

Just wondering why multiple requests are being made even though "offline" is enabled for the remote datasource.  I would think that if "offline" is enabled for the datasource, an initial request for data would be made and then all functionality afterwards would be based on the data that was initially retrieved.


Thanks,

Josh


Demo




3 Replies

BC Berly Christopher Syncfusion Team July 9, 2021 12:14 PM UTC

Hi Josh,  
  
Greetings from Syncfusion support. 
  
By default, when we bind the remote data to the DropDownList component it sends the request to the server for fetching the data. If we set the pre-defined value, then it will send a request to the server for retrieve the result based on available data source. Due to this, when we set pre-defined value along with data source, two requests are sent to the server.  
  
While checking the same scenario in the browser, the 4 requests will appear in the network tab. We would like to inform you that browser send the preflight request before the actual request has been made. It is browser’s default behavior. Kindly refer the below blog for more information.  
  
  
Regards, 
Berly B.C 



JB Josh Borgerding July 9, 2021 12:38 PM UTC

Ok, thank you.  I understand the initial request when binding the remote data to the DropDownList component, but I would have thought that an attempt to retrieve the initial value from the original request would be done before making another request.



PM Ponmani Murugaiyan Syncfusion Team July 12, 2021 03:20 PM UTC

Hi Josh,


Thanks for the update. Please get back us if you need further assistance.


Regards,
Ponmani M



Loader.
Up arrow icon