Enable the select2 widget for the quick label selection field.

Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
Roberto Rosario
2018-08-08 17:02:16 -04:00
parent 565f6caa0d
commit 87ff0696d3
2 changed files with 7 additions and 1 deletions

View File

@@ -22,6 +22,7 @@
- Add support for client side caching of document page images. The time
the images are cached is controlled by the new setting
DOCUMENTS_PAGE_IMAGE_CACHE_TIME which defaults to 3600 seconds (1 hour).
- The document quick label selection field now uses a select2 widget.
3.0.1 (2018-07-08)
=================

View File

@@ -91,7 +91,12 @@ class DocumentForm(forms.ModelForm):
] = forms.ModelChoiceField(
queryset=filenames_qs,
required=False,
label=_('Quick document rename')
label=_('Quick document rename'),
widget=forms.Select(
attrs={
'class': 'select2'
}
)
)
def clean(self):