2
0
Эх сурвалжийг харах

Removed tags from the admin UI

Jeremy Stretch 6 жил өмнө
parent
commit
75b4ba2c3a

+ 2 - 1
CHANGELOG.md

@@ -97,7 +97,8 @@ the Config Context from being included in any results.
 
 
 NetBox now makes use of its own `Tag` model instead of the vanilla model which ships with django-taggit. This new model
 NetBox now makes use of its own `Tag` model instead of the vanilla model which ships with django-taggit. This new model
 lives in the `extras` app and thus any permissions that you may have configured using "Taggit | Tag" should be changed
 lives in the `extras` app and thus any permissions that you may have configured using "Taggit | Tag" should be changed
-to now use "Extras | Tag."
+to now use "Extras | Tag." Also note that the admin interface for tags has been removed as it was redundant to the
+functionality provided by the front end UI.
 
 
 ## Enhancements
 ## Enhancements
 
 

+ 0 - 12
netbox/netbox/admin.py

@@ -2,17 +2,6 @@ from django.conf import settings
 from django.contrib.admin import AdminSite
 from django.contrib.admin import AdminSite
 from django.contrib.auth.admin import GroupAdmin, UserAdmin
 from django.contrib.auth.admin import GroupAdmin, UserAdmin
 from django.contrib.auth.models import Group, User
 from django.contrib.auth.models import Group, User
-from taggit.admin import TagAdmin, TaggedItemInline
-
-from extras.models import Tag, TaggedItem
-
-
-class NetBoxTaggedItemInline(TaggedItemInline):
-    model = TaggedItem
-
-
-class NetBoxTagAdmin(TagAdmin):
-    inlines = [NetBoxTaggedItemInline]
 
 
 
 
 class NetBoxAdminSite(AdminSite):
 class NetBoxAdminSite(AdminSite):
@@ -29,7 +18,6 @@ admin_site = NetBoxAdminSite(name='admin')
 # Register external models
 # Register external models
 admin_site.register(Group, GroupAdmin)
 admin_site.register(Group, GroupAdmin)
 admin_site.register(User, UserAdmin)
 admin_site.register(User, UserAdmin)
-admin_site.register(Tag, NetBoxTagAdmin)
 
 
 # Modify the template to include an RQ link if django_rq is installed (see RQ_SHOW_ADMIN_LINK)
 # Modify the template to include an RQ link if django_rq is installed (see RQ_SHOW_ADMIN_LINK)
 if settings.WEBHOOKS_ENABLED:
 if settings.WEBHOOKS_ENABLED: