mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-17 04:25:42 +00:00
Adds sample plugin which responds to triggered events
- Adds some example trigger events for the "Part" model
This commit is contained in:
@ -63,3 +63,15 @@ class InvenTreePlugin():
|
||||
raise error
|
||||
|
||||
return cfg
|
||||
|
||||
def is_active(self):
|
||||
"""
|
||||
Return True if this plugin is currently active
|
||||
"""
|
||||
|
||||
cfg = self.plugin_config()
|
||||
|
||||
if cfg:
|
||||
return cfg.active
|
||||
else:
|
||||
return False
|
||||
|
Reference in New Issue
Block a user