Telerik Forums
UI for ASP.NET Core Forum
1 answer
93 views

I'm using DropDownList in grid as EditorTemplate. If no value is selected I get a message that says "The Id field is required". How to change the message or remove it completely?

Vasko
Telerik team
 answered on 02 Oct 2023
0 answers
74 views
I think heading is enough.
kva
Top achievements
Rank 2
Iron
Iron
Iron
 asked on 29 Sep 2023
1 answer
144 views

Hi All,

We have a table for managing a business process that needs to display an item from the inventory tables. Therefore we need the column showing what Item a record will use to be a ForeignKey column. We have had various problems getting this to work, and our best solution so far is still not functional. The DropDownList just closes as soon as you click into it. It is bound with server filtering.

The column definition:

columns.ForeignKey(p => p.ItemMasterId, ds => ds.Read(r => r.Action("ItemMasters", "MasterMix")), "ItemId", "ItemName", true)
                                    .Title("Item Name").Width(500).EditorTemplateName("ItemMasterDropDownEditor");

The editor template:

@model object

@(Html.Kendo().DropDownListFor(model => model)
        .DataSource(source =>
        {
            source.Read("ItemMasters", "MasterMix").ServerFiltering();
        })
        .Filter(FilterType.Contains)
        .DataValueField("ItemId")
        .DataTextField("ItemName")
)

The server-side call:

public ActionResult ItemMasters(string text)
        {
            var itemMasters = string.IsNullOrEmpty(text) ? db.ItemMasters.OrderBy(o => o.ItemName).Select(p => new ItemMasterVM(p.Id, p.ItemName)).ToList()
                : db.ItemMasters.OrderBy(o => o.ItemName).Where(e => e.ItemName.ToLower().Contains(text.ToLower())).Select(p => new ItemMasterVM(p.Id, p.ItemName)).ToList();
            return Json(itemMasters);
        }

 

The list is working correctly showing all we need. We just can't get the dropdown to stay open and have the cursor in the filter search text box.

Thanks in advance... Bob Graham

 

Anton Mironov
Telerik team
 answered on 27 Sep 2023
0 answers
74 views

The left column should occupy vertically the same as the right column.

kva
Top achievements
Rank 2
Iron
Iron
Iron
 asked on 27 Sep 2023
1 answer
1.6K+ views

Hi,

 

Telerik.UI.for.AspNet.Core v2023.2.82 is still referencing multiple deprecated MS packages, all of the dependencies that start with 'Microsoft.AspNetCore' are version 2.1.0 and are showing as Deprecated by Microsoft.

Mihaela
Telerik team
 answered on 25 Sep 2023
0 answers
84 views
I guess this should be possible with jquery. How to do this?
kva
Top achievements
Rank 2
Iron
Iron
Iron
 asked on 22 Sep 2023
1 answer
87 views

I need to find refresh values of DropDownList programmatically. That's what I tried:

		    let nameDropDownList = $('#Configs').getKendoDropDownList();
			console.log(nameDropDownList);
			console.log(nameDropDownList.datasource);
		    nameDropDownList.datasource.read();	
            nameDropDownList.value(currentConfigName);

When read is called, I get:

Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'read')

Log shows me, that datasource is undefined.

DropDownList definition:
            @(Html.Kendo().DropDownList()
                .Name("Configs")
                .DataTextField("Name")
                .DataValueField("Name")
                .Filter(FilterType.StartsWith)
                .DataSource(s =>
                {
                    s.Read(r => r.Action("Read", "FilteringTable"));
                }))
Read method simply returns all entities of type FilteringTable.
kva
Top achievements
Rank 2
Iron
Iron
Iron
 answered on 22 Sep 2023
0 answers
86 views
I think it could be done from jquery. As a result, dropdownlist should show nothing in the UI.
kva
Top achievements
Rank 2
Iron
Iron
Iron
 asked on 22 Sep 2023
1 answer
385 views
In grid, I have a column for User, which shows the User's Name. I want to create a checkboxes column filter which will show users' names. How to implement this?
Stoyan
Telerik team
 updated answer on 21 Sep 2023
1 answer
93 views

I would like to store filter's state in url. The url should be formed by pressing apply button. When the page with url containing filter information is opened, the filter should consume this information and display on the page.

Alexander
Telerik team
 answered on 19 Sep 2023
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?