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

Closes #10761: Enable associating an export template with multiple object types

This commit is contained in:
jeremystretch
2022-10-26 13:30:45 -04:00
parent 7a155407f6
commit 16919cc1d9
16 changed files with 104 additions and 56 deletions

View File

@@ -68,16 +68,16 @@ class CustomLinkCSVForm(CSVModelForm):
class ExportTemplateCSVForm(CSVModelForm):
content_type = CSVContentTypeField(
content_types = CSVMultipleContentTypeField(
queryset=ContentType.objects.all(),
limit_choices_to=FeatureQuery('export_templates'),
help_text="Assigned object type"
help_text="One or more assigned object types"
)
class Meta:
model = ExportTemplate
fields = (
'name', 'content_type', 'description', 'mime_type', 'file_extension', 'as_attachment', 'template_code',
'name', 'content_types', 'description', 'mime_type', 'file_extension', 'as_attachment', 'template_code',
)