'Creates a new VisibleBlocks model object.
Argument \'blocks\' should be a BlockRecordList.'

def create_from_blockrecords(self, blocks):

    (model, _) = self.get_or_create(hashed=blocks.hash_value, defaults={u'blocks_json': blocks.json_value, u'course_id': blocks.course_key})
    return model
