2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-16 01:36:29 +00:00

Translation fixes (#4621)

* Remove HTML tags from translateable string

* Improve another string

* Improve strings for plugin version check

* Cleanup duplicate serials msg

* JS translations

* fmt
This commit is contained in:
Oliver
2023-04-18 00:12:14 +10:00
committed by GitHub
parent 593a716c29
commit f6b9b12745
6 changed files with 15 additions and 11 deletions

View File

@@ -447,11 +447,13 @@ class PluginsRegistry:
# Disable plugin
safe_reference(plugin=plg_i, key=plg_key, active=False)
_msg = _(f'Plugin `{plg_name}` is not compatible with the current InvenTree version {version.inventreeVersion()}!')
if plg_i.MIN_VERSION:
_msg += _(f'Plugin requires at least version {plg_i.MIN_VERSION}')
if plg_i.MAX_VERSION:
_msg += _(f'Plugin requires at most version {plg_i.MAX_VERSION}')
p = plg_name
v = version.inventreeVersion()
_msg = _(f"Plugin '{p}' is not compatible with the current InvenTree version {v}")
if v := plg_i.MIN_VERSION:
_msg += _(f'Plugin requires at least version {v}')
if v := plg_i.MAX_VERSION:
_msg += _(f'Plugin requires at most version {v}')
# Log to error stack
log_error(_msg, reference='init')
else: