Skip to content

How to make this plugin have its own menu section? #56

Description

please edit the navigation.py to move towards a modern user interface. Most all plugins are moving away from being a submenu underneath the "plugins" menu and moving towards top level menus.

Here is the code (tested) to accomplish this for the phonebox plugin.

from netbox.plugins import PluginMenu, PluginMenuItem

menu = PluginMenu(
    label="Voice",
    icon_class="mdi mdi-phone-outgoing",
    groups=(
        (
            "Voice",
            (
                PluginMenuItem(
                    link="plugins:phonebox_plugin:list_view",
                    link_text="Numbers",
                ),
                PluginMenuItem(
                    link="plugins:phonebox_plugin:voice_circuit_list_view",
                    link_text="Voice Circuits",
                ),
            ),
        ),
    ),
)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions