'Returns all the content type strings that apply to this model.
This includes the models\' content type and all concrete ancestor
models that inherit from Indexed.
For example: ["myapp.MyPageModel", "wagtailcore.Page"]
["myapp.MyModel"]'

def get_all_content_types(self):

    content_types = [self.get_content_type()]
    ancestor = self.get_parent()
    while ancestor:
        content_types.append(ancestor.get_content_type())
        ancestor = ancestor.get_parent()
    return content_types
