From 3f3b385de725ddd32f162420c3dcc1c6102d4793 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Thu, 29 Mar 2018 13:49:50 -0400 Subject: [PATCH] Fixes #1999: Added missing description field to site edit form --- netbox/dcim/forms.py | 7 ++++--- netbox/templates/dcim/site_edit.html | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/netbox/dcim/forms.py b/netbox/dcim/forms.py index df4d91c66..b360108bf 100644 --- a/netbox/dcim/forms.py +++ b/netbox/dcim/forms.py @@ -112,9 +112,8 @@ class SiteForm(BootstrapMixin, TenancyForm, CustomFieldForm): class Meta: model = Site fields = [ - 'name', 'slug', 'status', 'region', 'tenant_group', 'tenant', 'facility', 'asn', 'description', - 'physical_address', 'shipping_address', 'contact_name', 'contact_phone', 'contact_email', 'time_zone', - 'comments', + 'name', 'slug', 'status', 'region', 'tenant_group', 'tenant', 'facility', 'asn', 'time_zone', 'description', + 'physical_address', 'shipping_address', 'contact_name', 'contact_phone', 'contact_email', 'comments', ] widgets = { 'physical_address': SmallTextarea(attrs={'rows': 3}), @@ -124,6 +123,8 @@ class SiteForm(BootstrapMixin, TenancyForm, CustomFieldForm): 'name': "Full name of the site", 'facility': "Data center provider and facility (e.g. Equinix NY7)", 'asn': "BGP autonomous system number", + 'time_zone': "Local time zone", + 'description': "Short description (will appear in sites list)", 'physical_address': "Physical location of the building (e.g. for GPS)", 'shipping_address': "If different from the physical address" } diff --git a/netbox/templates/dcim/site_edit.html b/netbox/templates/dcim/site_edit.html index 582f93996..399551434 100644 --- a/netbox/templates/dcim/site_edit.html +++ b/netbox/templates/dcim/site_edit.html @@ -12,6 +12,7 @@ {% render_field form.facility %} {% render_field form.asn %} {% render_field form.time_zone %} + {% render_field form.description %}