mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-05-13 16:27:33 +00:00
fix: update config
This commit is contained in:
parent
e80774cf94
commit
5a353b814c
13
src/App.vue
13
src/App.vue
@ -15,11 +15,22 @@ limitations under the License. -->
|
|||||||
<template>
|
<template>
|
||||||
<router-view />
|
<router-view />
|
||||||
</template>
|
</template>
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { useRoute } from "vue-router";
|
||||||
|
const route = useRoute();
|
||||||
|
|
||||||
|
setTimeout(() => {
|
||||||
|
if (route.name === "ViewWidget") {
|
||||||
|
(document.querySelector("#app") as any).style.minWidth = "120px";
|
||||||
|
} else {
|
||||||
|
(document.querySelector("#app") as any).style.minWidth = "1024px";
|
||||||
|
}
|
||||||
|
}, 500);
|
||||||
|
</script>
|
||||||
<style>
|
<style>
|
||||||
#app {
|
#app {
|
||||||
color: #2c3e50;
|
color: #2c3e50;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
min-width: 1024px;
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
|
|||||||
limitations under the License. -->
|
limitations under the License. -->
|
||||||
<template>
|
<template>
|
||||||
<div class="nav-bar flex-h">
|
<div class="nav-bar flex-h">
|
||||||
<div class="title">{{ appStore.pageTitle || t(pageName) }}</div>
|
<div class="title">{{ route.name === "ViewWidget" ? "" : appStore.pageTitle || t(pageName) }}</div>
|
||||||
<div class="app-config">
|
<div class="app-config">
|
||||||
<span class="red" v-show="timeRange">{{ t("timeTips") }}</span>
|
<span class="red" v-show="timeRange">{{ t("timeTips") }}</span>
|
||||||
<TimePicker
|
<TimePicker
|
||||||
|
@ -95,7 +95,7 @@ limitations under the License. -->
|
|||||||
} else {
|
} else {
|
||||||
appStore.setIsMobile(false);
|
appStore.setIsMobile(false);
|
||||||
}
|
}
|
||||||
if (route.params.config) {
|
if (route.name === "ViewWidget") {
|
||||||
showMenu.value = false;
|
showMenu.value = false;
|
||||||
}
|
}
|
||||||
const controlMenu = () => {
|
const controlMenu = () => {
|
||||||
|
@ -24,7 +24,7 @@ limitations under the License. -->
|
|||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="widget-chart" :style="{ height: config.height + 'px' }">
|
<div class="widget-chart" :style="{ height: config.height - 60 + 'px' }">
|
||||||
<component
|
<component
|
||||||
:is="graph.type"
|
:is="graph.type"
|
||||||
:intervalTime="appStoreWithOut.intervalTime"
|
:intervalTime="appStoreWithOut.intervalTime"
|
||||||
@ -75,7 +75,6 @@ limitations under the License. -->
|
|||||||
|
|
||||||
init();
|
init();
|
||||||
async function init() {
|
async function init() {
|
||||||
appStoreWithOut.setPageTitle("Widget");
|
|
||||||
dashboardStore.setLayer(route.params.layer);
|
dashboardStore.setLayer(route.params.layer);
|
||||||
dashboardStore.setEntity(route.params.entity);
|
dashboardStore.setEntity(route.params.entity);
|
||||||
await setSelector();
|
await setSelector();
|
||||||
@ -152,7 +151,7 @@ limitations under the License. -->
|
|||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.content {
|
.content {
|
||||||
min-width: 800px;
|
min-width: 100px;
|
||||||
border: 1px solid #eee;
|
border: 1px solid #eee;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
@ -95,7 +95,7 @@ limitations under the License. -->
|
|||||||
metrics: dashboardStore.selectedGrid.metrics,
|
metrics: dashboardStore.selectedGrid.metrics,
|
||||||
metricTypes: dashboardStore.selectedGrid.metricTypes,
|
metricTypes: dashboardStore.selectedGrid.metricTypes,
|
||||||
metricConfig: metricConfig,
|
metricConfig: metricConfig,
|
||||||
height: dashboardStore.selectedGrid.h * 20,
|
height: dashboardStore.selectedGrid.h * 20 + 60,
|
||||||
});
|
});
|
||||||
const path = `/page/${dashboardStore.layerId}/${
|
const path = `/page/${dashboardStore.layerId}/${
|
||||||
dashboardStore.entity
|
dashboardStore.entity
|
||||||
|
Loading…
Reference in New Issue
Block a user