fix: translate all sidebar items
This commit is contained in:
parent
fb55c6d95c
commit
e3d5eea217
2 changed files with 2 additions and 2 deletions
|
|
@ -537,6 +537,7 @@ def get_sentry_dsn():
|
|||
|
||||
|
||||
def get_sidebar_items():
|
||||
from frappe import _
|
||||
from frappe.desk.doctype.workspace_sidebar.workspace_sidebar import auto_generate_sidebar_from_module
|
||||
|
||||
sidebars = frappe.get_all("Workspace Sidebar", fields=["name", "header_icon"])
|
||||
|
|
@ -560,7 +561,7 @@ def get_sidebar_items():
|
|||
}
|
||||
for si in w.items:
|
||||
workspace_sidebar = {
|
||||
"label": si.label,
|
||||
"label": _(si.label),
|
||||
"link_to": si.link_to,
|
||||
"link_type": si.link_type,
|
||||
"type": si.type,
|
||||
|
|
|
|||
|
|
@ -222,7 +222,6 @@ frappe.ui.Sidebar = class Sidebar {
|
|||
if (items && items.length > 0) {
|
||||
items.forEach((w) => {
|
||||
if (!w.display_depends_on || frappe.utils.eval(w.display_depends_on)) {
|
||||
w.label = __(w.label);
|
||||
this.add_item(this.$items_container, w);
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue