mirror of
https://github.com/inventree/InvenTree.git
synced 2025-04-30 20:46:47 +00:00
added version identifier
This commit is contained in:
parent
ef858f7701
commit
e7237d13ae
@ -258,6 +258,7 @@ class IntegrationPluginBase(MixinBase, plugin.InvenTreePlugin):
|
|||||||
|
|
||||||
AUTHOR = None
|
AUTHOR = None
|
||||||
PUBLISH_DATE = None
|
PUBLISH_DATE = None
|
||||||
|
VERSION = None
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
super().__init__()
|
super().__init__()
|
||||||
@ -304,6 +305,12 @@ class IntegrationPluginBase(MixinBase, plugin.InvenTreePlugin):
|
|||||||
name = _('No date found')
|
name = _('No date found')
|
||||||
return name
|
return name
|
||||||
|
|
||||||
|
@property
|
||||||
|
def version(self):
|
||||||
|
"""returns version of plugin"""
|
||||||
|
name = getattr(self, 'VERSION', None)
|
||||||
|
return name
|
||||||
|
|
||||||
# mixins
|
# mixins
|
||||||
def mixin(self, key):
|
def mixin(self, key):
|
||||||
"""check if mixin is registered"""
|
"""check if mixin is registered"""
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
<th>{% trans "Name" %}</th>
|
<th>{% trans "Name" %}</th>
|
||||||
<th>{% trans "Author" %}</th>
|
<th>{% trans "Author" %}</th>
|
||||||
<th>{% trans "Date" %}</th>
|
<th>{% trans "Date" %}</th>
|
||||||
|
<th>{% trans "Version" %}</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
|
||||||
@ -48,6 +49,7 @@
|
|||||||
</td>
|
</td>
|
||||||
<td>{{ plugin.author }}</td>
|
<td>{{ plugin.author }}</td>
|
||||||
<td>{{ plugin.pub_date }}</td>
|
<td>{{ plugin.pub_date }}</td>
|
||||||
|
<td>{{ plugin.version }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</tbody>
|
</tbody>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user