mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-10-15 12:49:17 +00:00
fix: edit widget config
This commit is contained in:
@@ -37,12 +37,16 @@ limitations under the License. -->
|
||||
/>
|
||||
</span>
|
||||
<span class="tab-icons">
|
||||
<i @click="addTabItem">
|
||||
<Icon size="middle" iconName="add" />
|
||||
</i>
|
||||
<i @click="addTabWidget">
|
||||
<Icon size="middle" iconName="playlist_add" />
|
||||
</i>
|
||||
<el-tooltip effect="dark" content="Add tab items" placement="bottom">
|
||||
<i @click="addTabItem">
|
||||
<Icon size="middle" iconName="add" />
|
||||
</i>
|
||||
</el-tooltip>
|
||||
<el-tooltip effect="dark" content="Add widgets" placement="bottom">
|
||||
<i @click="addTabWidget">
|
||||
<Icon size="middle" iconName="playlist_add" />
|
||||
</i>
|
||||
</el-tooltip>
|
||||
</span>
|
||||
</div>
|
||||
<div class="operations">
|
||||
@@ -73,7 +77,7 @@ limitations under the License. -->
|
||||
<Widget :data="item" :active="activeTabWidget === item.i" />
|
||||
</grid-item>
|
||||
</grid-layout>
|
||||
<div class="no-data-tips" v-else>No widgets, plase add widgets</div>
|
||||
<div class="no-data-tips" v-else>Please add widgets.</div>
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
|
@@ -25,10 +25,10 @@ limitations under the License. -->
|
||||
<Icon iconName="ellipsis_v" size="middle" class="operation" />
|
||||
</template>
|
||||
<div class="tools" @click="editConfig">
|
||||
<span>Edit</span>
|
||||
<span>{{ t("edit") }}</span>
|
||||
</div>
|
||||
<div class="tools" @click="removeWidget">
|
||||
<span>Delete</span>
|
||||
<span>{{ t("delete") }}</span>
|
||||
</div>
|
||||
</el-popover>
|
||||
</div>
|
||||
@@ -39,7 +39,7 @@ limitations under the License. -->
|
||||
:data="state.source"
|
||||
/>
|
||||
</div>
|
||||
<div v-else class="no-data">No data</div>
|
||||
<div v-else class="no-data">{{ t("noData") }}</div>
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts">
|
||||
@@ -50,7 +50,7 @@ import { useDashboardStore } from "@/store/modules/dashboard";
|
||||
import { useAppStoreWithOut } from "@/store/modules/app";
|
||||
import graphs from "../graphs";
|
||||
import { ElMessage } from "element-plus";
|
||||
// import { useI18n } from "vue-i18n";
|
||||
import { useI18n } from "vue-i18n";
|
||||
|
||||
const props = {
|
||||
data: {
|
||||
@@ -64,7 +64,7 @@ export default defineComponent({
|
||||
components: { ...graphs },
|
||||
props,
|
||||
setup(props) {
|
||||
// const { t } = useI18n();
|
||||
const { t } = useI18n();
|
||||
const loading = ref<boolean>(false);
|
||||
const state = reactive({
|
||||
source: {},
|
||||
@@ -110,6 +110,7 @@ export default defineComponent({
|
||||
editConfig,
|
||||
data,
|
||||
loading,
|
||||
t,
|
||||
};
|
||||
},
|
||||
});
|
||||
|
Reference in New Issue
Block a user