- Language: en
48 results for super in version 3.2
-
The Django admin site
- … super(PersonAdmin, self).__init__(*args, **kwargs) . You can use super().__init__(*args, **kwargs) . Discovery of admin …
-
Using mixins with class-based views
- … super () . get ( request , * args , ** kwargs ) def get_context_data ( self , ** kwargs ): context = super () . get_context …
-
Writing custom model fields
- … super () . __init__ ( * args , ** kwargs ) def deconstruct ( self ): name , path , args , kwargs = super () . deconstruct () del kwargs …
-
Multiple databases
- … super() ) or do the appropriate handling of the _db attribute on the manager (a string …
-
Testing tools
- … super implementation: class MyTestCase ( TestCase ): @classmethod def setUpClass ( cls ): super () . setUpClass () ... @classmethod def tearDownClass ( cls ): ... super …
-
Built-in class-based generic views
- … super), any children of that class will also need to explicitly set it after super …
-
Form and field validation
- … super() call and use self.cleaned_data instead: def clean ( self ): super () . clean () cc_myself = self …
-
Query Expressions
- … super () . as_sql ( compiler , connection , function = 'CONCAT_WS' , template = " %(function)s ('', %(expressions …
-
Model instance reference
- … super()). if len ( values ) != len ( cls . _meta . concrete_fields ): values = list ( values ) values . reverse () values …
-
Form handling with class-based views
- … super () . form_valid ( form ) Notes: FormView inherits TemplateResponseMixin so template_name can be used here …