This commit is contained in:
Matthias 2021-10-04 19:50:56 +02:00
parent 90d36069c8
commit cec29310dc
No known key found for this signature in database
GPG Key ID: F50EF5741D33E076

View File

@ -263,6 +263,7 @@ class IntegrationPluginBase(MixinBase, plugin.InvenTreePlugin):
self.set_sign_values()
# properties
@property
def slug(self):
"""slug for the plugin"""
@ -279,6 +280,7 @@ class IntegrationPluginBase(MixinBase, plugin.InvenTreePlugin):
name = self.plugin_name()
return name
# mixins
def mixin(self, key):
"""check if mixin is registered"""
return key in self._mixins
@ -290,6 +292,7 @@ class IntegrationPluginBase(MixinBase, plugin.InvenTreePlugin):
return getattr(self, fnc_name, True)
return False
# git
def get_plugin_commit(self):
"""get last git commit for plugin"""
return get_git_log(self.def_path)