'Decode the json into CourseGradingModel and save any changes. Returns the modified model.
Probably not the usual path for updates as it\'s too coarse grained.'

@staticmethod
def update_from_json(course_key, jsondict, user):

    descriptor = modulestore().get_course(course_key)
    graders_parsed = [CourseGradingModel.parse_grader(jsonele) for jsonele in jsondict['graders']]
    descriptor.raw_grader = graders_parsed
    descriptor.grade_cutoffs = jsondict['grade_cutoffs']
    modulestore().update_item(descriptor, user.id)
    CourseGradingModel.update_grace_period_from_json(course_key, jsondict['grace_period'], user)
    CourseGradingModel.update_minimum_grade_credit_from_json(course_key, jsondict['minimum_grade_credit'], user)
    _grading_event_and_signal(course_key, user.id)
    return CourseGradingModel.fetch(course_key)
