From 04454653f7ead834a754a1c0bf5cfc880d1fdb49 Mon Sep 17 00:00:00 2001 From: bud313 Date: Thu, 25 Jul 2024 15:01:20 -0400 Subject: [PATCH] Update template_content.py I ran into problems with this on netbox 4 . I believe this needs to be updated like the other files to change the import depending on netbox version. --- nextbox_ui_plugin/template_content.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/nextbox_ui_plugin/template_content.py b/nextbox_ui_plugin/template_content.py index c0164d3..00c1d82 100644 --- a/nextbox_ui_plugin/template_content.py +++ b/nextbox_ui_plugin/template_content.py @@ -4,6 +4,10 @@ NETBOX_CURRENT_VERSION = version.parse(settings.VERSION) +if NETBOX_CURRENT_VERSION >= version.parse("4.0.0"): + from netbox.plugins import PluginConfig +else: + from extras.plugins import PluginConfig class SiteTopologyButtons(PluginTemplateExtension): """