jquery - using knockout paged grid in durandal -
i created single page app using durandal , knockout paged grid in example http://knockoutjs.com/examples/grid.html.
my question how able values on selected row. tried following steps nothing happened. on attached event of viewmodel have command.
$(view).find('.table tbody>tr').on('click', function (event) { $(view).find('.table tbody>tr').addclass('success') .siblings().removeclass('success'); });
durandal samples has knockout examples integrated e.g. http://dfiddle.github.io/dfiddle-2.0/#knockout-samples/pagedgrid might better starting point.
please take @ of knockout documentation @ http://learn.knockoutjs.com figure out why it's idea not use jquery things better handled in knockout. read click binding http://knockoutjs.com/documentation/click-binding.html. once got app working way read http://www.knockmeout.net/2012/11/revisit-event-delegation-in-knockout-js.html , upgrade solution use it.
Comments
Post a Comment