1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Set display_field where needed

This commit is contained in:
Jeremy Stretch
2020-08-13 09:27:21 -04:00
parent 0b14b66727
commit 53f9f82317
4 changed files with 27 additions and 8 deletions

View File

@@ -63,7 +63,8 @@ class SecretRoleCSVForm(CSVModelForm):
class SecretForm(BootstrapMixin, CustomFieldModelForm):
device = DynamicModelChoiceField(
queryset=Device.objects.all()
queryset=Device.objects.all(),
display_field='display_name'
)
plaintext = forms.CharField(
max_length=SECRET_PLAINTEXT_MAX_LENGTH,