Selected Tags are lost when Filter is applied to Kendo MultiSelect Control

2 posts, 0 answers
  1. Sally
    Sally avatar
    4 posts
    Member since:
    Mar 2015

    Posted 17 Oct 2019 Link to this post

    I need to apply a filter to a MultiSelect control that already has selected items within Kendo-UI 2016 R3 SP1 (2016.3.1028) . I am able to apply the filter but once I do all of the selected items are no longer tagged as selected even though they still exist in the list.
    I have tried using every version of Kendo-UI (the latest being Kendo UI 2019 R3, 2019.3.917) to see if a patch has been created to resolve this issue. None work. I have tried amending the "onFiltering" method as is described in the following post:

    Nothing has worked to this point.  I have created a snippet in Dojo that shows this exact issue:

    Please note that within this example "Star Wars: The Empire Strikes Back" should be tagged as selected. If you click on the drop down list it is listed as selected. However, it is not tagged as selected when the drop down list is minimized even though it is selected. Please also note that if I make a change and remove the filter from the MultiSelect control that it will be correctly tagged as selected.

    If anyone can offer a workaround or point to a patch that will resolve this issue then I would be very grateful.

  2. Petar
    Petar avatar
    402 posts

    Posted 21 Oct 2019 Link to this post

    Hi Sally,

    If I am understanding the case correctly, the desired functionality can be implemented by adding the following script as noted in this MultiSelect DataSource manual filtering demo:

    <!-- IMPORTANT: Update filter state of the widget -->

    Please check the edited versions of the Dojo you've sent me: 

    In both of the above demos, after adding the above code line, the filtered items are being correctly selected and after the initial selection, we can continue selecting/deselecting all MultiSelect items. 

    Please check the linked Dojo projects and let me know if they demonstrate the functionality you want to acheive.

    Progress Telerik

    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top