Fixed an issue where a queryset filter argument didn't have the right datatype.
- Legacy-Id: 12403
This commit is contained in:
parent
7c2a1b2ee4
commit
671df0492a
|
@ -38,7 +38,7 @@ class UploadMaterialForm(forms.Form):
|
|||
def __init__(self, doc_type, action, group, doc, *args, **kwargs):
|
||||
super(UploadMaterialForm, self).__init__(*args, **kwargs)
|
||||
|
||||
self.fields["state"].queryset = self.fields["state"].queryset.filter(type=doc_type)
|
||||
self.fields["state"].queryset = self.fields["state"].queryset.filter(type__slug=doc_type.slug)
|
||||
|
||||
self.doc_type = doc_type
|
||||
self.action = action
|
||||
|
|
Loading…
Reference in a new issue