or
$("#contactsGrid").delegate(".details-button", "click", function (e) { e.preventDefault(); //debugger; contactViewModel.set("selectedContact", $("#contactsGrid").data("kendoGrid").dataItem($(this).closest("tr"))); wnd.center().open(); // this wipes the newly selected contact details });New documentation portal feature requests....
MVVM:
So I do know the answers to some of these, I just would like docs\samples on these scenarios…I’m trying to move a couple people onto MVVM, but the current docs are pretty bad (please, no offense intended).
------------
UNRELATED (the best kind of related):
Feature request: KnockoutJS has the mapping plugin to plug remote data into the model…right now we have to do an $.each loop…
//Lamefor (var field in jsonData) { viewModel.set(field, jsonData[field]); }I was
hoping we could get something like
//AwesomeviewModel.load(jsonData)------------
Wishlist: Each doc sample contains a fiddle to play with\fork so we can help flesh out demos\samples…
data-bind="checked: AvailableToHamilton, click: shareWith"success: function (e) { setTimeout(function(){ viewModel.getTotalCapacity(); }, 100);}<div id='bottomDiv'> <div id="tabstrip"> <ul> <li>Grid</li> </ul> <div> <div id="ticketListDiv"> </div> </div> </div> <div id='mapDiv'></div></div>$("#ticketListDiv").kendoGrid({ dataSource : { // JSONP is required for cross-domain AJAX dataType: "jsonp", transport: { read: baseURL + "Data;jsessionid="+ jsessionId + "?browserid=" + browserId + "&type=2&tool=KendoUIResourceList" }, schema: { model: { fields: { firstName: { type: "string" }, lastName: { type: "string" } } } }, pageSize: 10, serverPaging: true, serverFiltering: true, serverSorting: true }, toolbar: kendo.template($("#template").html()), height: 250, filterable: true, sortable: true, pageable: true, groupable: true, selectable: "single row", filterable: { messages: { info: "Ticket Filter", // sets the text on top of the filter menu filter: "ausführen", // sets the text for the "Filter" button clear: "zurücksetzen", // sets the text for the "Clear" button }, operators: { //filter menu for "string" type columns string: { eq: "entspricht", neq: "entspricht nicht", startswith: "startet mit", contains: "enthält", endswith: "endet mit" } } }, dataBound: resizeGrid, columns : [{ field : "firstName", title : "Vorname", width : 50 }, { field : "lastName", title : "Nachname", width : 50 }] });$(document).ready(function () { var tipaiindeksai = new kendo.data.DataSource({ transport: { read: { url: "http://localhost:11336/Mobile/GetTipaiIrIndeksai", dataType: "jsonp", jsonp: "d" //cache: false, //jsonpCallback: "callback" } }, schema: { data: "" } }); var ats = tipaiindeksai.read();HTTP/1.1 200 OKServer: ASP.NET Development Server/10.0.0.0Date: Wed, 23 May 2012 08:35:01 GMTX-AspNet-Version: 4.0.30319X-AspNetMvc-Version: 4.0Cache-Control: privateContent-Type: application/json; charset=utf-8Content-Length: 939Connection: ClosejQuery1710758081869687885_1337762101342([{"ID":0,"pav":"asd","indeksas":141.8},{"ID":10,"pav":"asdasd","indeksas":101.7}])