Implement PDF export for graded Missions and Trainings

Resolves #260 
@wangqiang1208 Yes, to update existing courses it will be necessary to perform a `rake db:populate_course_preference` as defined here: https://github.com/Coursemology/coursemology.org/blob/development/lib/tasks/populate_course_preference.rake

Is there a better way to implement the new preferences?