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

Declare TaggableManager on PrimaryModel base class

This commit is contained in:
Jeremy Stretch
2021-03-10 14:32:50 -05:00
parent 20f60cd99d
commit fc5bb966f0
16 changed files with 11 additions and 66 deletions

View File

@@ -6,10 +6,8 @@ from django.core.exceptions import ValidationError
from django.db import models
from django.db.models import F
from django.urls import reverse
from taggit.managers import TaggableManager
from dcim.models import Device
from extras.models import TaggedItem
from extras.utils import extras_features
from netbox.models import OrganizationalModel, PrimaryModel
from ipam.choices import *
@@ -107,7 +105,6 @@ class Aggregate(PrimaryModel):
max_length=200,
blank=True
)
tags = TaggableManager(through=TaggedItem)
objects = RestrictedQuerySet.as_manager()
@@ -292,7 +289,6 @@ class Prefix(PrimaryModel):
max_length=200,
blank=True
)
tags = TaggableManager(through=TaggedItem)
objects = PrefixQuerySet.as_manager()
@@ -564,7 +560,6 @@ class IPAddress(PrimaryModel):
max_length=200,
blank=True
)
tags = TaggableManager(through=TaggedItem)
objects = IPAddressManager()