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

Closes #10545: Standardize description & comment fields on primary models (#10834)

* Standardize description & comments fields on primary models

* Update REST API serializers

* Update forms

* Update tables

* Update templates
This commit is contained in:
Jeremy Stretch
2022-11-04 08:28:09 -04:00
committed by GitHub
parent e2f5ee661a
commit bc6b5bc4be
105 changed files with 1014 additions and 534 deletions

View File

@ -2,9 +2,8 @@ from django.contrib.contenttypes.fields import GenericForeignKey
from django.contrib.contenttypes.models import ContentType
from django.db import models
from django.urls import reverse
from mptt.models import TreeForeignKey
from netbox.models import ChangeLoggedModel, NestedGroupModel, OrganizationalModel, NetBoxModel
from netbox.models import ChangeLoggedModel, NestedGroupModel, OrganizationalModel, PrimaryModel
from netbox.models.features import WebhooksMixin
from tenancy.choices import *
@ -41,7 +40,7 @@ class ContactRole(OrganizationalModel):
return reverse('tenancy:contactrole', args=[self.pk])
class Contact(NetBoxModel):
class Contact(PrimaryModel):
"""
Contact information for a particular object(s) in NetBox.
"""
@ -73,9 +72,6 @@ class Contact(NetBoxModel):
link = models.URLField(
blank=True
)
comments = models.TextField(
blank=True
)
clone_fields = (
'group', 'name', 'title', 'phone', 'email', 'address', 'link',