'Validate inline class\'s fk field is not excluded.'

def check_inline(self, cls, parent_model):

    fk = _get_foreign_key(parent_model, cls.model, fk_name=cls.fk_name, can_fail=True)
    if (hasattr(cls, 'exclude') and cls.exclude):
        if (fk and (fk.name in cls.exclude)):
            raise ImproperlyConfigured(("%s    cannot    exclude    the    field    '%s'    -    this    is    the    foreign    key    to    the    parent    model    %s.%s." % (cls.__name__, fk.name, parent_model._meta.app_label, parent_model.__name__)))
