Revert "Revert "Merge pull request #960 from dimagi/fd-types-cleanup""

This reverts commit b7db27efb3d1307ad7754ba66876cc724f5b8662.
create js class for handling visualizations
pull out get_stats_data into it's own fn
add custom data parameter; add ability to override the url updating behavior; support week, month, and day intervals; fix global bug
adhere to couchdbkit 0.6.2+ hightened strictness on doc types in view results

(is backwards compatible with 0.5.7)
allow users to set the interval
don't display graphs when the query returned no data
add ability to specify whether you're using hash-tabs; don't display the no-data text on load
fix stupid bug with no-data commit
explicitly pass in wrapper class to SubmissionErrorLog.view

for couchdbkit 0.6.2+ compatibility
override MobileBackend.view to happily wrap anything

for 0.6.2+ compatibility
use explicit wrapper instead of a hacky classes thing
write failed doc IDs to a file and enable reading doc IDs from a file
Survive when CouchUser.get_by_username returns None
Merge pull request #963 from dimagi/fd-types-cleanup

Revert "Revert "Merge pull request #960 from dimagi/fd-types-cleanup""
Merge pull request #1085 from dimagi/copy_domain_errors

write failed doc IDs to a file and enable reading doc IDs from a file
Merge pull request #1086 from kennknowles/sso-no-couch-user

Survive when CouchUser.get_by_username returns None
Merge pull request #1074 from dimagi/viz

Visualizations Refactor
Merge pull request #1081 from dimagi/couchdbkit-0.6.4

Fix tests for couchdbkit 0.6.4
Advance couchforms submodule