Skip to content

Commit 43dbe3b

Browse files
committed
Fix django 1.7 deprecation warnings: Always set fields= or exclude= in Meta for ModelForm subclasses.
- Legacy-Id: 8828
1 parent b5dad67 commit 43dbe3b

2 files changed

Lines changed: 3 additions & 0 deletions

File tree

ietf/ipr/admin.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
class IprDocRelAdminForm(forms.ModelForm):
1313
class Meta:
1414
model = IprDocRel
15+
fields = '__all__'
1516
widgets = {
1617
'sections':forms.TextInput,
1718
}

ietf/ipr/forms.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ class DraftForm(forms.ModelForm):
9393

9494
class Meta:
9595
model = IprDocRel
96+
fields = '__all__'
9697
widgets = {
9798
'sections': forms.TextInput(),
9899
}
@@ -167,6 +168,7 @@ def __init__(self,*args,**kwargs):
167168
class Meta:
168169
"""This will be overridden"""
169170
model = IprDisclosureBase
171+
fields = '__all__'
170172

171173
def clean(self):
172174
super(IprDisclosureFormBase, self).clean()

0 commit comments

Comments
 (0)