Hi,
I have a Kendo Grid in which I use Data method in Read.Action to pass parameters to a controller action. The code is:
<% Html.Kendo().Grid<EvaluationsQuestionsEvaluationPillarsGridViewModel>()
.Name("Pillars")
.DataSource(dataSource => dataSource
.Ajax()
.Model(model => model.Id(a => a.EvaluationMasterPillarId))
.ServerOperation(true)
.Read(read => read.Action("LoadEvaluationsQuestionsEvaluationPillarsGridAjax", "Evaluations")
.Data("onLoadEvaluationsQuestionsEvaluationPillarsGridData"))
)
......
function onLoadEvaluationsQuestionsEvaluationPillarsGridData(e) {
var evaluationVersionId = $('#evaluationVersionId').val(); // "evaluationVersionId" is set beforehand
var showDeletedCheckbox = $('#Checkbox1').val();
return { evaluationVersionId: evaluationVersionId, showDeleted: showDeletedCheckbox }
}
public ActionResult LoadEvaluationsQuestionsEvaluationPillarsGridAjax(DataSourceRequest request, string evaluationVersionId, bool showDeleted)
{
......
But the controller action "LoadEvaluationsQuestionsEvaluationPillarsGridAjax" is not even invoked. I need help on this. Thanks.
Hi there, I was wondering if someone could help me. How can I bind my dropdown list to a viewbag to ensure it's getting it's data from the right place? I found a couple of guides but they didn't work for my scenario. Here is my code.
// #DDL - Broker Companies
IEnumerable<SelectListItem> thestats = seabrokersData.tbl_requirement_status
.Select(c =>
new
SelectListItem
{
Value = c.id.ToString(),
Text = c.thet_status
});
ViewBag.theStatus = theStatus;
I would like my Kendo Dropdown to use the above viewbag to populate itself. How can I do this?
Many thanks
I'm having some accessibility issues with my Kendo MVC Grid. When using the Tab button I am unable to access the pages options at the bottom left corner of the grid. After looking over your documentation I've seen that pressing ALT + Page Up or ALT + Page Down should allow me to move through the pages. Unfortunately this does not work and I'm unsure what may be causing this issue. Here is an example of my code.
@(Html.Kendo().Grid<AuthDTO.ListUserManagement>()
.Name("ManageUsersGrid")
.HtmlAttributes(new {style = " width:100%; height:86%"})
.Pageable()
.Pageable(pageable => pageable
.PageSizes(true)
.Messages(msg => msg.Display("{0:d0} - {1:d0} of {2:d0} items"))
.Refresh(true))
.Reorderable(reorder => reorder.Columns(true))
.Sortable(sort => sort.SortMode(GridSortMode.MultipleColumn))
.Filterable(ftb => ftb.Mode(GridFilterMode.Row))
.ColumnMenu()
.ColumnResizeHandleWidth(10)
.Resizable(resizable => resizable.Columns(true))
.Scrollable(o => o.Height("100%"))
.DataSource(dataSource => dataSource
.Ajax()
.Read(read => read.Action("GetUsers", "AppUser", new RouteValueDictionary {{"area", "AppUser"}}))
)
.Columns(columns =>
{
columns.Bound(o => o.Id)
.Filterable(false)
.Width(100)
.IncludeInMenu(false)
.Sortable(false)
.Title("Actions")
.ClientTemplate(
"# if(" + @ViewBag.DOD + " == 'true') { # +" +
"<a href=\"javascript: void(0);\" onclick=\"userEditItem('#: Id #');\" title=\"Edit\"><i class=\"disabled fa fa-pencil-square-o fa-lg\"></i><span class=\"sr-only\"></span></a>"
+ "# } else { # " +
"<a href=\"javascript: void(0);\" onclick=\"userEditItemCAC('#: Id #');\" title=\"Edit\"><i class=\"active fa fa-pencil-square-o fa-lg\"></i><span class=\"sr-only\"></span></a>"
+ "# } #" +
"<a href=\"javascript: void(0);\" onclick=\"impersonate('#: Id #');\" title=\"Impersonate User\"><i class=\"active fa fa-user fa-lg\"></i><span class=\"sr-only\"></span></a>"
);
columns.Bound(o => o.LastName)
.Width(200)
.Filterable(ftb => ftb.Cell(cell => cell.Operator("contains")));
columns.Bound(o => o.FirstName)
.Title("First Name")
.Width(200)
.Filterable(ftb => ftb.Cell(cell => cell.Operator("contains")));
columns.Bound(o => o.Email)
.Title("Email")
.Width(250)
.Filterable(ftb => ftb.Cell(cell => cell.Operator("contains")));
columns.Bound(o => o.Phone)
.Title("Phone")
.Width(250)
.Filterable(ftb => ftb.Cell(cell => cell.Operator("contains")));
columns.Bound(o => o.Organization)
.Title("Organization")
.Width(250)
.Filterable(ftb => ftb.Cell(cell => cell.Operator("contains")));
columns.Bound(o => o.Active)
.Title("Active")
.Width(100)
.Filterable(false);
columns.Bound(o => o.LockedAccount)
.Title("Locked Account")
.Width(100)
.Filterable(false);
columns.Bound(o => o.LockoutDateTime)
.Title("Lockout Date Time")
.Width(200);
})
)
Hello,
I have a problems with @(Html.Kendo().Editor() in Vistual Studio 2015 ASP.NET 5 MVC 6 beta 8 with "Kendo.Mvc : 2015.3.1111".
No overload for method 'Editor' takes 0 arguments
When will it be available?
Best Regards
Davide
My use case involves the user editing the content of the editor while the server occasionally updates some of the values in the text
However, when the server sends an update and the editor.value("string") happens, the cursor position is reset to the start of the text, instead of leaving it where it is
I've tried fiddling with selected ranges and such but it doesn't seem to be working
Example
if search text is "xx", no items are displayed. Instead I would like to have the following result:
I'm not sure if this us something that a Keno control could handle but I thought I'd best ask anyway. On part of my form the user can add multiple entires before submission. I need to know if it's possible to handle this behaviour with Kendo controls? I've attached a couple of images to show you what I mean.
The user can add as many items as they want.
Many thanks
Allan
Hi,
With filterable->mode set to row, is it possible to filter a date between two dates? I found this thread http://www.telerik.com/forums/how-to-define-a-kendo-grid-column-filter-between-two-dates, and currently have it applied to grid menu filter, but not sure how to make it work when the filterable mode is row.
Thanks,
Lisa
I am in need of some help, I'm building a web application that uses the KendoUI, specifically the grid to display data. I've used the entity framework under a "database first" scenario, this means that the models are created for me for all the tables in my database. I'm displaying this data in the Kendo grid but I can't edit or delete any of the entries (inline with ajax). If you delete an item it returns when you regresh the screen and the update button does nothing. I suspect this is because we have no functions to handle these events.
Is there anyway I can utilise the already created scaffolded controller to do this as it already as an edit and delete function in it.
Any help would be appreciated.