From bcf6e41b489b5447186c063193d32714856bdfc7 Mon Sep 17 00:00:00 2001 From: Oliver Walters Date: Fri, 6 May 2022 23:43:54 +1000 Subject: [PATCH] Add some example docs --- .../plugin/samples/integration/custom_panel_sample.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/InvenTree/plugin/samples/integration/custom_panel_sample.py b/InvenTree/plugin/samples/integration/custom_panel_sample.py index be6567a5fb..8b73f793d1 100644 --- a/InvenTree/plugin/samples/integration/custom_panel_sample.py +++ b/InvenTree/plugin/samples/integration/custom_panel_sample.py @@ -33,6 +33,15 @@ class CustomPanelSample(PanelMixin, IntegrationPluginBase): def get_custom_panels(self, view, request): + """ + You can decide at run-time which custom panels you want to display! + + - Display on every page + - Only on a single page or set of pages + - Only for a specific instance (e.g. part) + - Based on the user viewing the page! + """ + panels = [ { # This 'hello world' panel will be displayed on any view which implements custom panels