Generate dygraph legend on server; dygraphs can't do what we need.
Graph legend from server side.