mirror of
https://github.com/davidhalter/django-stubs.git
synced 2025-12-07 04:34:29 +08:00
This ensures that the order in which these mixins are included into a derrived class does not matter and ends up more accurately reflecting the return type of SuccessMessageMixin in the process (its code doesn't appear to enforce that the returned response is a redirect). This provides a fix to a secondary aspect of https://github.com/mkurnikov/django-stubs/issues/79.
11 lines
307 B
Plaintext
11 lines
307 B
Plaintext
[CASE successmessagemixin_compatible_with_formmixin]
|
|
from django.views.generic.edit import FormMixin
|
|
from django.contrib.messages.views import SuccessMessageMixin
|
|
|
|
class FormFirstView(FormMixin, SuccessMessageMixin):
|
|
pass
|
|
|
|
class SuccessMessageFirstView(FormMixin, SuccessMessageMixin):
|
|
pass
|
|
[/CASE]
|