修改树形控件名称

This commit is contained in:
fangxiang 2022-04-06 20:08:26 +08:00
parent 6d8c58eb0a
commit 276f88b48e
1 changed files with 6 additions and 2 deletions

View File

@ -225,6 +225,7 @@ class _TreeHelper {
tree: any, tree: any,
group_name: string, group_name: string,
items_name: string, items_name: string,
root_text: string,
createTreeItem: ( createTreeItem: (
uuid?: string, uuid?: string,
parent?: string, parent?: string,
@ -246,7 +247,7 @@ class _TreeHelper {
const groups = playload.response[group_name] ?? []; const groups = playload.response[group_name] ?? [];
const items = playload.response[items_name] ?? []; const items = playload.response[items_name] ?? [];
const root = createTreeItem("", "", $t.t("root"), true); const root = createTreeItem("", "", $t.t(root_text ?? "root"), true);
tree.splice(0, tree.length); tree.splice(0, tree.length);
tree.push(root); tree.push(root);
@ -615,7 +616,7 @@ export default store(function (/* { ssrContext } */) {
const root = new SignalSourceTreeItemEntity( const root = new SignalSourceTreeItemEntity(
"", "",
"", "",
$t.t("root"), $t.t("signal source"),
true true
); );
@ -666,6 +667,7 @@ export default store(function (/* { ssrContext } */) {
state.mode_tree, state.mode_tree,
"mode_groups", "mode_groups",
"modes", "modes",
"mode",
( (
uuid?: string, uuid?: string,
parent?: string, parent?: string,
@ -724,6 +726,7 @@ export default store(function (/* { ssrContext } */) {
state.plan_tree, state.plan_tree,
"plan_groups", "plan_groups",
"plans", "plans",
"plan",
( (
uuid?: string, uuid?: string,
parent?: string, parent?: string,
@ -788,6 +791,7 @@ export default store(function (/* { ssrContext } */) {
state.polling_tree, state.polling_tree,
"polling_groups", "polling_groups",
"pollings", "pollings",
"signal polling",
( (
uuid?: string, uuid?: string,
parent?: string, parent?: string,