I have written the following code using ASP.NET MVC3 and it's throwing me an error at the bold line(.Model(Function(model) model.id(Function(p) p.CostCentreID). It's saying that the expression does not produce a value? I thought it's asking for a primary key column only? Isn't that the case?
Please help
@ModelType IEnumerable(Of Mail.BAL.CostCentre)
@Code
ViewData("Title") = "Index"
End Code
@(Html.Kendo().Grid(Model) _
.Name("CostCentres") _
.Columns(Function(modelItem) modelItem.Bound(Function(p) p.CostCentreID).Hidden) _
.Columns(Function(modelItem) modelItem.Bound(Function(p) p.CostCentre)) _
.Columns(Function(modelItem) modelItem.Bound(Function(p) p.Active)) _
.ToolBar(Function(toolbar) toolbar.Create()) _
.Groupable() _
.Pageable() _
.Sortable() _
.Scrollable() _
.DataSource(Function(datasource) datasource _
.Ajax() _
**.Model(Function(model) model.Id(Function(p) p.CostCentreID)) _**
.Create(Function(create) create.Action("Create", "Home")))
)
@(Html.Kendo().Menu() .Name("menu") .Items(menu => { menu.Add().Text("Home").Action("Index", "Home"); menu.Add().Text("About").Action("About", "Home"); }).Events(events => events.Select("onSelect")) )
$('#feeValue').width(250).kendoNumericTextBox({ format: 'c2' });
var chart = $("#chart").data("kendoChart");chart.title.text = "Test";[ {"id":"1","text":"host1","spriteCssClass":"server"} {"id":"2","text":"host2","spriteCssClass":"server"}]$("#treeview-hosts").kendoTreeView({ dragAndDrop: true, dataSource: { transport: { read: { url: "/main/getEnvHosts", type: 'POST', data: '{"env":"'+env+'"}', } }, schema: { model: { id: "id" }, }, } });Hi,
I have a grid marked as Batch Editable. Only one cell is editable, I can do this by the field list of the Datasource like this:
fieldList['cellname'] = { type: 'number', editable: true };
It is working ok. When you change a cell in a row the Grid set a visual clue, like Excel, indicating that the cell has been changed.
The problem is when you, before saving the changes, navigate to another, using the pageable control. If you return
to the previous page the visual sign disappears. Internally the row is marked as dirty but there is visual sign
anymore.
How can I fix That ???
If this is a known bug I need to detect the event of page change so that I can warn the user of non saved fields.
How can I do that ???
Thanks in advance
<ul id="hosts"> <li id="host1"><span class="maas-sprite server"></span>host1</li> <li id="host2"><span class="maas-sprite server"></span>host2</li> <li id="host3"><span class="maas-sprite server"></span>host3</li></ul> $('#hosts').kendoTreeView({ dragAndDrop: true,});