Use ajax in stats
Work in process
Merge branch 'migrate_courses'