diff --git a/apps/assets/forms.py b/apps/assets/forms.py index 24d68e02c..6fc50849e 100644 --- a/apps/assets/forms.py +++ b/apps/assets/forms.py @@ -21,7 +21,10 @@ class AssetForm(forms.ModelForm): class AssetGroupForm(forms.ModelForm): - assets = forms.ModelMultipleChoiceField(queryset=Asset.objects.all()) + assets = forms.ModelMultipleChoiceField(queryset=Asset.objects.all(), + widget=forms.SelectMultiple(attrs={ + 'class': 'select2', + 'data-placeholder': _('Select assets')})) def __init__(self, *args, **kwargs): if kwargs.get('instance'): diff --git a/apps/assets/templates/assets/assetgroup_add.html b/apps/assets/templates/assets/assetgroup_add.html index 0812d8e80..fe2238429 100644 --- a/apps/assets/templates/assets/assetgroup_add.html +++ b/apps/assets/templates/assets/assetgroup_add.html @@ -30,18 +30,18 @@