Re: Mixin add field to fields in forms

2021-04-18 Thread Shaheed Haque
Actually, looking again at the source, it might be generally belter to use self.base_fields. (Yes, my previous answer is not an exact copy of my code, so I got it wrong). On Sun, 18 Apr 2021 at 17:16, Shaheed Haque wrote: > > > On Sun, 18 Apr 2021 at 14:38, sebasti...@gmail.com < > sebastian.ju.

Re: Mixin add field to fields in forms

2021-04-18 Thread Shaheed Haque
On Sun, 18 Apr 2021 at 14:38, sebasti...@gmail.com < sebastian.ju...@gmail.com> wrote: > Hello, > > Thanks for your fast response. But i don't know how i can > use self.declared_fields and why this would help me... > The "how" is easy. Here is a fragment from my code where the problem is that ev

Re: Mixin add field to fields in forms

2021-04-18 Thread sebasti...@gmail.com
Hello, Thanks for your fast response. But i don't know how i can use self.declared_fields and why this would help me... Regards shahee...@gmail.com schrieb am Sonntag, 18. April 2021 um 15:14:03 UTC+2: > Try updating self.declared_fields instead. > > On Sun, 18 Apr 2021, 13:47 sebasti...@gma

Re: Mixin add field to fields in forms

2021-04-18 Thread Shaheed Haque
Try updating self.declared_fields instead. On Sun, 18 Apr 2021, 13:47 sebasti...@gmail.com, wrote: > Hello, > > > *forms.py:* > > class Newsletterform(StandardMixin): > class Meta: > model = Newsletter > fields = ['newslettername', 'from_link', 'to_list', > 'email_subject', '