Declined
Last Updated: 26 Sep 2024 15:46 by ADMIN

REPL to reproduce the problem following the steps below: https://netcorerepl.telerik.com/wSYNlmbA55iBcMhu20

Steps to reproduce

Type "wil" to get suggestions:


Hit tab to accept the first suggestion.

Click the arrow to display the list of options:


Observe the list of unrelated options, and the textbox now containing the value of the first option listed:

 

Additional information

The "normal" read request sends what is ultimately handled as a DataSourceRequest object in the controller that includes (among other things) information on how the data should be sorted. The "value mapper" request, on the other hand, sends only the raw values that need to be mapped (without any information on how they are being sorted by the DataSource). As a result, the positional index returned to the value mapper is incorrect if/when the data is sorted differently.

For example, the "normal" read request calls the controller action, it retrieves data [A, C, D, B], and the DataSourceRequest is applied to sort it as [A, B, C, D] and this is how it's displayed in the dropdown list. If the value "B" needs to be mapped, the "value mapper" request calls a similar (but different) controller action, it retrieves the same set of data [A, C, D, B] but does not make any attempt to sort it, finds "B" in the list (#4), and this is returned to the component (which then sets the dropdown's selectedIndex = 4, but in the dropdown's sorted list of data, this corresponds with the value "D", not "B" [which would be 2]).

Completed
Last Updated: 29 Jun 2019 07:07 by ADMIN
Would love to see support for multi column combo box for asp.net core
Completed
Last Updated: 14 Sep 2021 07:41 by ADMIN

Bug report

In Core when the ComboBoxFor helper is used as an editor in a Grid (Shared/EditorTemplates) and its Name is set, the Grid does not render and no exception is displayed, to indicate that the Name option should not be set.

Reproduction of the problem

Reproducible in the Editing custom editor Grid demo.

  1. Set the ComboBox' Name in the ClientCategory.cshtml template
@(Html.Kendo().ComboBoxFor(m => m)
    .Name("CategoryID")
    .DataValueField("CategoryID")
    .DataTextField("CategoryName")
    .BindTo((System.Collections.IEnumerable)ViewData["categories"])
)

Current behavior

We throw an exception when the Name is set (e.g. if the ComboBox is used outside of a Grid), but in this scenario it is not displayed.

Expected/desired behavior

An exception is thrown and its message is displayed.

Environment

  • Kendo UI version: 2019.2.619
  • jQuery version: x.y
  • Browser: [all]