views:

104

answers:

2

I'm trying to build a view similar to PivotalTracker where there are a variety of rows in different buckets. There is some polling to the server because rows could be updated by other users while you're working on it and the page should update on its own without having to manually refresh it.

I know how to poll the server and get updated rows, but it's not simply a matter of redrawing each row in place when it's been updated, because the row could change locations or order on the screen, and also be deleted, etc.

It's complex enough that I don't think they are doing it manually with javascript.

It looks like they are doing a versioned view, where only the diff of the changes (in JSON) is pushed down to the client on a poll so the view is kept in synch with the DB using these diffs.

I've never really heard of or seen a library to do a "versioned view" but maybe such a library or framework exists? Or is there some other way they are doing it? Thanks!

By the way, I'm using Ruby on Rails to build this.

A: 

Just peeking at the tracker page source it looks like they are using YAHOO UI widgets to do things. Their javascript has been compressed (no whitespace), so it's a pain to wade through it all, but it looks to me like they are using the yui library to update all of their views.

Mike
A: 

An email from the Pivotal tracker guys confirms that is is custom coded solution. Each UI component listens for commands from the user. The server can send commands from other users on a poll. It sounds complicated - a home grown solution.

I decided to build something similar using only RJS. Still figuring it all out..

Brian Armstrong