mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Fixes #9194: Support position assignment when add module bays to multiple devices
This commit is contained in:
@ -17,6 +17,7 @@
|
|||||||
* [#9151](https://github.com/netbox-community/netbox/issues/9151) - Child prefix counts not annotated on aggregates list under RIR view
|
* [#9151](https://github.com/netbox-community/netbox/issues/9151) - Child prefix counts not annotated on aggregates list under RIR view
|
||||||
* [#9156](https://github.com/netbox-community/netbox/issues/9156) - Fix loading UserConfig data from fixtures
|
* [#9156](https://github.com/netbox-community/netbox/issues/9156) - Fix loading UserConfig data from fixtures
|
||||||
* [#9158](https://github.com/netbox-community/netbox/issues/9158) - Do not list tags field for CSV forms which do not support tag assignment
|
* [#9158](https://github.com/netbox-community/netbox/issues/9158) - Do not list tags field for CSV forms which do not support tag assignment
|
||||||
|
* [#9194](https://github.com/netbox-community/netbox/issues/9194) - Support position assignment when add module bays to multiple devices
|
||||||
* [#9206](https://github.com/netbox-community/netbox/issues/9206) - Show header for comments field under module & module type creation views
|
* [#9206](https://github.com/netbox-community/netbox/issues/9206) - Show header for comments field under module & module type creation views
|
||||||
|
|
||||||
---
|
---
|
||||||
|
@ -3,7 +3,7 @@ from django import forms
|
|||||||
from dcim.models import *
|
from dcim.models import *
|
||||||
from extras.forms import CustomFieldsMixin
|
from extras.forms import CustomFieldsMixin
|
||||||
from extras.models import Tag
|
from extras.models import Tag
|
||||||
from utilities.forms import DynamicModelMultipleChoiceField, form_from_model
|
from utilities.forms import DynamicModelMultipleChoiceField, ExpandableNameField, form_from_model
|
||||||
from .object_create import ComponentCreateForm
|
from .object_create import ComponentCreateForm
|
||||||
|
|
||||||
__all__ = (
|
__all__ = (
|
||||||
@ -98,7 +98,13 @@ class RearPortBulkCreateForm(
|
|||||||
|
|
||||||
class ModuleBayBulkCreateForm(DeviceBulkAddComponentForm):
|
class ModuleBayBulkCreateForm(DeviceBulkAddComponentForm):
|
||||||
model = ModuleBay
|
model = ModuleBay
|
||||||
field_order = ('name_pattern', 'label_pattern', 'description', 'tags')
|
field_order = ('name_pattern', 'label_pattern', 'position_pattern', 'description', 'tags')
|
||||||
|
|
||||||
|
position_pattern = ExpandableNameField(
|
||||||
|
label='Position',
|
||||||
|
required=False,
|
||||||
|
help_text='Alphanumeric ranges are supported. (Must match the number of names being created.)'
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
class DeviceBayBulkCreateForm(DeviceBulkAddComponentForm):
|
class DeviceBayBulkCreateForm(DeviceBulkAddComponentForm):
|
||||||
|
Reference in New Issue
Block a user