RadzenDropDown - Requires two clicks

I'm having an issue with the RadzenDropDown component. The LoadData seems to work perfectly, filters to the correct data, but requires two clicks from the user to select the option. This happens anytime LoadData is called. Anyone have an idea about what is going on?

All of the examples use IEnumerable's with DBContext, but my project is not using Entity Framework. I am using Dapper. I can link my Service and Dapper code too if needed, but I didn't think it would be helpful.

Thank you in advance!

@page "/"
@inject MainService _db;

<div class="col-3 p-3">
    @if (courses != null)
    {
            <RadzenDropDown AllowClear="true" TValue="string" Class="w-100"
                        LoadData=@LoadData AllowFiltering="true"
                        Data=@courses TextProperty="CourseTitle" ValueProperty="Id" />
    }
</div>

@code {
    private List<CourseModel> courses;

    protected override async Task OnInitializedAsync()
    {
        courses = await _db.GetCourses("A");
    }

    private async void LoadData(LoadDataArgs args)
    {
        if (!string.IsNullOrEmpty(args.Filter))
        {            
            courses = await _db.GetCourses(args.Filter);
        }

        await InvokeAsync(StateHasChanged);
    }
}

Hi @mason_rb,

I was able to reproduce the problem however I'm still not sure what's causing it and how to resolve it. The only option I can offer you at the moment is to use in-memory filtering instead LoadData in this case. I'll post here when I have more info/fix.

2 Likes

I was able to fix the problem and the fix will be part of our next update early next week.

1 Like

Thank you @enchev! I appreciate your response and am excited that you found a solution so quickly.

Version 3.16.7 fixed this issue. Thank you again @enchev !

1 Like