jqGrid & knockout combination

1,422 views
Skip to first unread message

surfer

unread,
May 15, 2011, 7:45:35 PM5/15/11
to KnockoutJS
Knockout has got so much potential I'm hoping to use this in our
product in the future as it'll save us so a huge amount of time not
having to write code maintaining changes to the UI.

I see there is a simple client side grid but is there a more advanced
one or someway to use the mapping with something like jqGrid?

I need to support server side pagination, sorting, searching etc and
would like to use something like jqGrid along with knockout to manage
dynamic changes to visible data in the grid in real-time.

Steven Sanderson

unread,
May 29, 2011, 12:05:58 PM5/29/11
to knock...@googlegroups.com
Hi Surfer

Thanks for your message. Glad to hear you're excited about KO!

I'm sure it's entirely possible to hook KO and jqGrid together - you'd just need to create a jqGrid equivalent of the ko.simpleGrid.viewModel (referenced from the http://knockoutjs.com/examples/grid.html example you mentioned) to encapsulate access to the jqGrid API behind observables. If you're interested in making something reusable and releasing it as a plugin, I'd be happy to provide feedback and link to it from knockoutjs.com if you want.

For the longer term future, I'm pretty keen on the jQuery Grid project that looks like it will have a much nicer API than jqGrid when finished. Here's an extremely simple example of using it with KO: http://jsfiddle.net/ZCJQw/1/ . Might that be something you could build on?

Regards
Steve

Entity Spaces

unread,
Jun 28, 2011, 6:13:53 AM6/28/11
to KnockoutJS
Did you every do any more with this grid, the sample looks cool in
jsfiddle, I tried to added editing to it but couldn't get it to work?

Entity Spaces

unread,
Jun 28, 2011, 6:14:54 AM6/28/11
to KnockoutJS
There is an "editing[]" property but it doesn't seem to work, I
assumed that would let me do inline editing,
Reply all
Reply to author
Forward
0 new messages