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

I currently have the grid below. And I am trying to make a different popup for when someone is creating a new entry vs editing the existing one. Mainly to show different fields and such. How do I go about doing so?

Whether I click on the Create() on the AddNewRecord or the edit, it hits the Edit() event or BeforeEdit() when I switch to that so they end up calling the same Javascript function. And within that function I cant seem to find a way to determine which button was pressed. On here I can only find this reference: Custom Popup Editor for Create and Edit in UI for ASP.NET Core | Telerik Forums , but it doesnt use the same syntax.

                            <div id="minutesDiv">
                                @Html.Kendo().Grid(Model.MinutesList).Name("MinutesGrid").Size(ComponentSize.Small).Editable(GridEditMode.PopUp).Resizable(r => r.Columns(true)).ToolBar(x =>
                                     {
                                         x.Create();
                             }).Columns(col =>
                                     {
                                         col.Bound(c => c.MinuteDate).Title("Date Created").Width(100);
                                         col.Bound(c => c.CreatedBy).Title("Entered By").Width(200);
                                         col.Bound(c => c.Minute).Title("Minutes").Width(200);
                                         col.Command(c =>
                                         {
                                             c.Edit();
                                             c.Destroy();
                                         }).Width(170);
                                     }).Events(e => 
                                         {
                                             e.Edit("HideFieldsOnEdit");
                                         }).Sortable().DataSource(dataSource => dataSource
                                     .Ajax()
                                     .Read(r => r.Url("/Appearances/OutcomeInformation?handler=Read").Data("forgeryToken"))
                                     .Update(r => r.Url("/Appearances/OutcomeInformation?handler=Update").Data("forgeryToken"))
                                     .Create(r => r.Url("/Appearances/OutcomeInformation?handler=Create").Data("forgeryToken"))
                                     .Destroy(r => r.Url("/Appearances/OutcomeInformation?handler=Destroy").Data("forgeryToken"))
                                     .Model(model =>
                                     {
                                         model.Field(Field => Field.MinuteDate);
                                         model.Field(Field => Field.CreatedBy);
                                         model.Field(Field => Field.Minute);
                                     }))
                            </div>



                function HideFieldsOnEdit(e){
                    e.container.find("#MinuteID").hide();
                    e.container.find("label[for='MinuteID']").hide();
                    e.container.find("#CreatedBy").hide();
                    e.container.find("label[for='CreatedBy']").hide();
                    e.container.find("#MinuteDate").hide();
                    e.container.find("label[for='MinuteDate']").hide();   
                    e.container.find("#FileID").hide();
                    e.container.find("label[for='FileID']").hide();
                }

Eyup
Telerik team
 answered on 07 Mar 2025
1 answer
47 views

Environment Info: ASP for .Net Core, taghelper kendo-grid

I have defined a template for a kendo grid popup editor. 

<editable mode="popup" template-id="popup-editor">
    <editable-window title="Add/Edit Collateral"/>
</editable>

This is the template

@using Kendo.Mvc.UI

@addTagHelper *, Kendo.Mvc

@model MyApp.Web.ViewModels.MyViewModel

<div id="divEditImpliedSupport">
<form method="post" id="frmImpliedSupport" asp-action="SaveImpliedSupport" asp-controller="ReviewApi">
<input type="hidden" asp-for="CollateralID" />
<div class="row">
<div>
<formgroup>
<formlabel asp-for="CollateralDescription" ></formlabel>
<div>
<forminput asp-for="CollateralDescription" style="width:400px;"></forminput>
</div>
</formgroup>
</div>
</div>
</form>
</div>

 

How do I set the size of the popup window?

 

Eyup
Telerik team
 answered on 05 Mar 2025
2 answers
49 views

Hello,

I can't seem to find a component for asp.net core that will just rotate images on a home page for example. Am I missing something? What component will do this?

Thanks

Anton Mironov
Telerik team
 answered on 05 Mar 2025
1 answer
52 views

Hi

I have a form component, and ideally I'd like to embed some custom HTML within it alongside one of the fields.

For example pseudo code for if this sort of thing was possible :

items.Add()
.Field(f => f.Task.StartDate)
.Label(l => l.Text("Call Date"))
.Editor(e =>
{
	e.DateTimePicker()
	.Size(ComponentSize.Small)
	.Format("{0:dd/MM/yyyy HH:mm}")
	.Min(DateTime.Now)
	.DateInput();
});

items.Add()
.ClientTemplate(<ul><li><a href="test1">A Link</a></li><li><a href="test2">Another Link</a></li></ul>);
How do I achieve injecting my own HTML into the form layout please?
Mihaela
Telerik team
 answered on 03 Mar 2025
0 answers
36 views

Hi support team,

 

sadly, we ran out of support so I'll try the forum for help.

 

We have bound column

 


   columns.Bound(c => c.BusinessPartner.Name).Title("Customer").Groupable(true)
       .Filterable(f => f.Multi(false).Search(true).Cell(c => c.ShowOperators(false).Operator("startswith"))).Width(250)
       .ClientTemplate(@"
           #= data.BusinessPartner.Number # #= data.BusinessPartner.Name #
           #if (data.BusinessPartner.PostalAddress != null) {#
               <span class='d-flex'> (#= data.BusinessPartner.PostalAddress.City #)</span>
           #}#");

 

From now on the filter using "startswith" is broken. Let me explain. Yesterday when entering "e" it displays all customers starting with "e". But suddenly some customers are not shown any more. Yesterday the list contained two entries and today only 1 entry any more.

I examined the SQL query behind the scenes but this is ok.

What could be wrong here?

Stefan
Top achievements
Rank 1
Iron
Iron
Iron
 asked on 25 Feb 2025
1 answer
37 views

I'm using a grid with filter multi checkboxes. I created a custom download for version 2025.1.211 with the Editing, Filtering, Row filter, and Paging  grid options checked.

When the filter button is clicked, the filter window is cut off by the 2nd row in the grid.

If I change the layout to reference kendo.all.min.js instead of kendo.custom.min.js it works fine. Is there a dependency for the row filter that is not being automatically checked?

Thank you

Anton Mironov
Telerik team
 answered on 24 Feb 2025
2 answers
37 views

When using the orgchart for a large set of nodes (2000+) it can be cumbersome to find where you are when a node is expanded. Is there a way to keep the just expanded node selected?

I've added an event handled to the Expand event which is called correct.


<script>
    function onExpand(e) {
//        alert("event: Expand --> " + e.dataItems[0].title + " expanded");
        alert(e.dataItems[0].id);
        var orgChart = $("orgChart").getKendoOrgChart();
        orgChart.select(e.dataItems[0]);
    }    
</script>

 

The alert fires with the correct id but dosen't seem to select the node that was clicked. I'd like to have that selected so the end user doesn't lose their place as the orgchart expands. Thanks!

 

Ivaylo
Telerik team
 answered on 20 Feb 2025
1 answer
31 views

Hi,

We're using the org chart component and the data binding works great and we love the template capabilty. But the org only uses a portion of the width of the display and as we have a large organization it would be better if it could use the full amount. I tried this:

.HtmlAttributes(new {style="width:100%"})

but it didn't seem to change anything. What am I missing on this? Thanks!

Ivan Danchev
Telerik team
 answered on 19 Feb 2025
1 answer
31 views
I'm a bit blown away that with all the demos that Telerik displays to feature these components, outside of DataGrid, you can't find an example on how to save user input.  I mean, we're not building static websites, guys. 

So, I've successfully fed data to a Dialog with a nested CheckboxGroup.  My checkboxes appear with labels supplied by the data.  If a user makes changes to the checkbox selections, I want to persist those changes when they click on the Dialog's "Save" button.  How do I persist the data back to the controller?  There's plenty of explanations for DataGrid, but, what about all the other components, like CheckboxGroup/Dialog.

Thanks in advance
Anton Mironov
Telerik team
 answered on 19 Feb 2025
1 answer
37 views

Hi Telerik,

To start, I will say this, yes I am using the danish language pack.

I am using the rich text editor and encountering issues with how it treats foreign language letters. I am based in Denmark, so when we have danish texts that include letters such as æ, ø, å, kendo seem to be translating them into a it's own letter combo.

This is a problem, because it is being saved like this in the database as well as, when I get the response, it does not translate it back to danish letters it stays as a weird letter dump.

Also consider that the data that is saved in the DB is later used in other places, therefore even if kendo would change it back for viewing, the fact that, this is how it is saved in the DB is a huge problem.

I attached some pictures for reference.

Thanks in advance,
Juste

Ivaylo
Telerik team
 answered on 12 Feb 2025
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
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
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?