mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Fixes #15771: Show id field as supported on all bulk import forms
This commit is contained in:
@ -70,6 +70,12 @@ class CSVModelForm(forms.ModelForm):
|
||||
"""
|
||||
ModelForm used for the import of objects in CSV format.
|
||||
"""
|
||||
id = forms.IntegerField(
|
||||
label=_('ID'),
|
||||
required=False,
|
||||
help_text=_('Numeric ID of an existing object to update (if not creating a new object)')
|
||||
)
|
||||
|
||||
def __init__(self, *args, headers=None, **kwargs):
|
||||
self.headers = headers or {}
|
||||
super().__init__(*args, **kwargs)
|
||||
|
Reference in New Issue
Block a user