def get_success_url(self):
        object = getattr(self, 'object', self.get_object())
        if self.success_url:
            url = self.success_url % object.__dict__
        else:
            try:
                url = object.get_absolute_url()
            except AttributeError:
                raise ImproperlyConfigured(
                    "No URL to redirect to.  Either provide a url or define"
                    " a get_absolute_url method on the document.")
        return url
dataset/ETHPy150Open MongoEngine/django-mongoengine/django_mongoengine/views/embedded.py/EmbeddedFormMixin.get_success_url/original