mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-07-18 06:25:24 +00:00
update
This commit is contained in:
parent
4d09ae6bd0
commit
d2a17bbfae
@ -386,6 +386,6 @@ const msg = {
|
|||||||
tabExpressions: "Tab Expressions",
|
tabExpressions: "Tab Expressions",
|
||||||
hierarchyNodeMetrics: "Metrics for Hierarchy Graph Node",
|
hierarchyNodeMetrics: "Metrics for Hierarchy Graph Node",
|
||||||
hierarchyNodeDashboard: "As dashboard for Hierarchy Graph Node",
|
hierarchyNodeDashboard: "As dashboard for Hierarchy Graph Node",
|
||||||
contentDecorations: "Content Decorations",
|
valueMappings: "Value Mappings",
|
||||||
};
|
};
|
||||||
export default msg;
|
export default msg;
|
||||||
|
@ -386,6 +386,6 @@ const msg = {
|
|||||||
tabExpressions: "Tab Expressions",
|
tabExpressions: "Tab Expressions",
|
||||||
hierarchyNodeMetrics: "Metrics for Hierarchy Graph Node",
|
hierarchyNodeMetrics: "Metrics for Hierarchy Graph Node",
|
||||||
hierarchyNodeDashboard: "As dashboard for Hierarchy Graph Node",
|
hierarchyNodeDashboard: "As dashboard for Hierarchy Graph Node",
|
||||||
contentDecorations: "Content Decorations",
|
valueMappings: "Value Mappings",
|
||||||
};
|
};
|
||||||
export default msg;
|
export default msg;
|
||||||
|
@ -384,6 +384,6 @@ const msg = {
|
|||||||
tabExpressions: "Tab表达式",
|
tabExpressions: "Tab表达式",
|
||||||
hierarchyNodeMetrics: "层次图节点的指标",
|
hierarchyNodeMetrics: "层次图节点的指标",
|
||||||
hierarchyNodeDashboard: "作为层次图节点的dashboard",
|
hierarchyNodeDashboard: "作为层次图节点的dashboard",
|
||||||
contentDecorations: "内容装饰",
|
valueMappings: "值映射",
|
||||||
};
|
};
|
||||||
export default msg;
|
export default msg;
|
||||||
|
@ -14,8 +14,8 @@ See the License for the specific language governing permissions and
|
|||||||
limitations under the License. -->
|
limitations under the License. -->
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<span class="label">{{ t("contentDecorations") }}</span>
|
<span class="label">{{ t("valueMappings") }}</span>
|
||||||
<content-decorations />
|
<value-mappings />
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<span class="label">{{ t("fontSize") }}</span>
|
<span class="label">{{ t("fontSize") }}</span>
|
||||||
@ -39,7 +39,7 @@ limitations under the License. -->
|
|||||||
import { ref } from "vue";
|
import { ref } from "vue";
|
||||||
import { useI18n } from "vue-i18n";
|
import { useI18n } from "vue-i18n";
|
||||||
import { useDashboardStore } from "@/store/modules/dashboard";
|
import { useDashboardStore } from "@/store/modules/dashboard";
|
||||||
import ContentDecorations from "./components/ContentDecorations.vue";
|
import ValueMappings from "./components/ValueMappings.vue";
|
||||||
|
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const dashboardStore = useDashboardStore();
|
const dashboardStore = useDashboardStore();
|
||||||
|
@ -14,8 +14,8 @@ See the License for the specific language governing permissions and
|
|||||||
limitations under the License. -->
|
limitations under the License. -->
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<span class="label">{{ t("contentDecorations") }}</span>
|
<span class="label">{{ t("valueMappings") }}</span>
|
||||||
<content-decorations />
|
<value-mappings />
|
||||||
</div>
|
</div>
|
||||||
<div class="item">
|
<div class="item">
|
||||||
<span class="label">{{ t("showValues") }}</span>
|
<span class="label">{{ t("showValues") }}</span>
|
||||||
@ -41,7 +41,7 @@ limitations under the License. -->
|
|||||||
import { ref } from "vue";
|
import { ref } from "vue";
|
||||||
import { useI18n } from "vue-i18n";
|
import { useI18n } from "vue-i18n";
|
||||||
import { useDashboardStore } from "@/store/modules/dashboard";
|
import { useDashboardStore } from "@/store/modules/dashboard";
|
||||||
import ContentDecorations from "./components/ContentDecorations.vue";
|
import ValueMappings from "./components/ValueMappings.vue";
|
||||||
|
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const dashboardStore = useDashboardStore();
|
const dashboardStore = useDashboardStore();
|
||||||
|
@ -39,8 +39,8 @@ limitations under the License. -->
|
|||||||
|
|
||||||
const dashboardStore = useDashboardStore();
|
const dashboardStore = useDashboardStore();
|
||||||
const graph = dashboardStore.selectedGrid.graph;
|
const graph = dashboardStore.selectedGrid.graph;
|
||||||
const decorations = ref<{ [key: string]: string }>(graph?.decorations || {});
|
const decorations = ref<{ [key: string]: string }>(graph?.valueMappings || {});
|
||||||
const keys = ref<string[]>(graph.decorations ? Object.keys(decorations.value) : [""]);
|
const keys = ref<string[]>(graph.valueMappings ? Object.keys(decorations.value) : [""]);
|
||||||
|
|
||||||
function changeKeys(event: any, index: number) {
|
function changeKeys(event: any, index: number) {
|
||||||
const params = event.target.textContent || "";
|
const params = event.target.textContent || "";
|
||||||
@ -50,12 +50,12 @@ limitations under the License. -->
|
|||||||
}
|
}
|
||||||
delete decorations.value[list[index]];
|
delete decorations.value[list[index]];
|
||||||
keys.value = Object.keys(decorations.value);
|
keys.value = Object.keys(decorations.value);
|
||||||
updateConfig({ decorations: decorations.value });
|
updateConfig();
|
||||||
}
|
}
|
||||||
|
|
||||||
function changeValues(event: any, key: string) {
|
function changeValues(event: any, key: string) {
|
||||||
decorations.value[key] = event.target.textContent || "";
|
decorations.value[key] = event.target.textContent || "";
|
||||||
updateConfig({ decorations: decorations.value });
|
updateConfig();
|
||||||
}
|
}
|
||||||
|
|
||||||
function addDecoration() {
|
function addDecoration() {
|
||||||
@ -68,13 +68,13 @@ limitations under the License. -->
|
|||||||
}
|
}
|
||||||
delete decorations.value[keys.value[index]];
|
delete decorations.value[keys.value[index]];
|
||||||
keys.value.splice(index, 1);
|
keys.value.splice(index, 1);
|
||||||
updateConfig({ decorations: decorations.value });
|
updateConfig();
|
||||||
}
|
}
|
||||||
|
|
||||||
function updateConfig(param: { [key: string]: unknown }) {
|
function updateConfig() {
|
||||||
const graph = {
|
const graph = {
|
||||||
...dashboardStore.selectedGrid.graph,
|
...dashboardStore.selectedGrid.graph,
|
||||||
...param,
|
valueMappings: decorations.value,
|
||||||
};
|
};
|
||||||
dashboardStore.selectWidget({ ...dashboardStore.selectedGrid, graph });
|
dashboardStore.selectWidget({ ...dashboardStore.selectedGrid, graph });
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user