From 3b4ec5926deb7d9fbbc0ac8de60354533d98d4c1 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Fri, 13 Mar 2020 15:49:58 -0400 Subject: [PATCH] Standardize existing description fields to a length of 200 chars --- netbox/circuits/models.py | 6 +++--- netbox/dcim/models/__init__.py | 8 ++++---- netbox/dcim/models/device_components.py | 2 +- netbox/extras/models.py | 4 ++-- netbox/ipam/models.py | 14 +++++++------- netbox/secrets/models.py | 2 +- netbox/tenancy/models.py | 5 ++--- netbox/users/models.py | 2 +- 8 files changed, 21 insertions(+), 22 deletions(-) diff --git a/netbox/circuits/models.py b/netbox/circuits/models.py index 812eaa79e..c650e27b7 100644 --- a/netbox/circuits/models.py +++ b/netbox/circuits/models.py @@ -108,7 +108,7 @@ class CircuitType(ChangeLoggedModel): unique=True ) description = models.CharField( - max_length=100, + max_length=200, blank=True, ) @@ -173,7 +173,7 @@ class Circuit(ChangeLoggedModel, CustomFieldModel): null=True, verbose_name='Commit rate (Kbps)') description = models.CharField( - max_length=100, + max_length=200, blank=True ) comments = models.TextField( @@ -292,7 +292,7 @@ class CircuitTermination(CableTermination): verbose_name='Patch panel/port(s)' ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) diff --git a/netbox/dcim/models/__init__.py b/netbox/dcim/models/__init__.py index 1dbfdb76b..e0d0cd0cd 100644 --- a/netbox/dcim/models/__init__.py +++ b/netbox/dcim/models/__init__.py @@ -182,7 +182,7 @@ class Site(ChangeLoggedModel, CustomFieldModel): blank=True ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) physical_address = models.CharField( @@ -362,7 +362,7 @@ class RackRole(ChangeLoggedModel): ) color = ColorField() description = models.CharField( - max_length=100, + max_length=200, blank=True, ) @@ -785,7 +785,7 @@ class RackReservation(ChangeLoggedModel): on_delete=models.PROTECT ) description = models.CharField( - max_length=100 + max_length=200 ) csv_headers = ['site', 'rack_group', 'rack', 'units', 'tenant', 'user', 'description'] @@ -1142,7 +1142,7 @@ class DeviceRole(ChangeLoggedModel): help_text='Virtual machines may be assigned to this role' ) description = models.CharField( - max_length=100, + max_length=200, blank=True, ) diff --git a/netbox/dcim/models/device_components.py b/netbox/dcim/models/device_components.py index 9a3d608d7..d6582baac 100644 --- a/netbox/dcim/models/device_components.py +++ b/netbox/dcim/models/device_components.py @@ -33,7 +33,7 @@ __all__ = ( class ComponentModel(models.Model): description = models.CharField( - max_length=100, + max_length=200, blank=True ) diff --git a/netbox/extras/models.py b/netbox/extras/models.py index 68625ae2d..0de5ec8e5 100644 --- a/netbox/extras/models.py +++ b/netbox/extras/models.py @@ -242,7 +242,7 @@ class CustomField(models.Model): 'the field\'s name will be used)' ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) required = models.BooleanField( @@ -764,7 +764,7 @@ class ConfigContext(models.Model): default=1000 ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) is_active = models.BooleanField( diff --git a/netbox/ipam/models.py b/netbox/ipam/models.py index 098dac2f2..4de3cdfdd 100644 --- a/netbox/ipam/models.py +++ b/netbox/ipam/models.py @@ -63,7 +63,7 @@ class VRF(ChangeLoggedModel, CustomFieldModel): help_text='Prevent duplicate prefixes/IP addresses within this VRF' ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) custom_field_values = GenericRelation( @@ -162,7 +162,7 @@ class Aggregate(ChangeLoggedModel, CustomFieldModel): null=True ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) custom_field_values = GenericRelation( @@ -261,7 +261,7 @@ class Role(ChangeLoggedModel): default=1000 ) description = models.CharField( - max_length=100, + max_length=200, blank=True, ) @@ -342,7 +342,7 @@ class Prefix(ChangeLoggedModel, CustomFieldModel): help_text='All IP addresses within this prefix are considered usable' ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) custom_field_values = GenericRelation( @@ -612,7 +612,7 @@ class IPAddress(ChangeLoggedModel, CustomFieldModel): help_text='Hostname or FQDN (not case-sensitive)' ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) custom_field_values = GenericRelation( @@ -898,7 +898,7 @@ class VLAN(ChangeLoggedModel, CustomFieldModel): null=True ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) custom_field_values = GenericRelation( @@ -1010,7 +1010,7 @@ class Service(ChangeLoggedModel, CustomFieldModel): verbose_name='IP addresses' ) description = models.CharField( - max_length=100, + max_length=200, blank=True ) custom_field_values = GenericRelation( diff --git a/netbox/secrets/models.py b/netbox/secrets/models.py index 7cebb744c..5038823ae 100644 --- a/netbox/secrets/models.py +++ b/netbox/secrets/models.py @@ -254,7 +254,7 @@ class SecretRole(ChangeLoggedModel): unique=True ) description = models.CharField( - max_length=100, + max_length=200, blank=True, ) users = models.ManyToManyField( diff --git a/netbox/tenancy/models.py b/netbox/tenancy/models.py index 1a02184cd..649905c17 100644 --- a/netbox/tenancy/models.py +++ b/netbox/tenancy/models.py @@ -86,9 +86,8 @@ class Tenant(ChangeLoggedModel, CustomFieldModel): null=True ) description = models.CharField( - max_length=100, - blank=True, - help_text='Long-form name (optional)' + max_length=200, + blank=True ) comments = models.TextField( blank=True diff --git a/netbox/users/models.py b/netbox/users/models.py index cf0d826b5..5be784777 100644 --- a/netbox/users/models.py +++ b/netbox/users/models.py @@ -39,7 +39,7 @@ class Token(models.Model): help_text='Permit create/update/delete operations using this key' ) description = models.CharField( - max_length=100, + max_length=200, blank=True )