Skip to content

Commit 4584822

Browse files
committed
fix: Fix the issue of mysql status page empty data
Refs #8945
1 parent b786d50 commit 4584822

File tree

1 file changed

+9
-5
lines changed
  • frontend/src/views/database/mysql/setting

1 file changed

+9
-5
lines changed

frontend/src/views/database/mysql/setting/index.vue

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -174,9 +174,7 @@ const jumpToConf = async () => {
174174
loadMysqlConf();
175175
};
176176
177-
const changeTab = (tab: string) => {
178-
activeName.value = tab;
179-
177+
watch(activeName, (tab) => {
180178
switch (tab) {
181179
case 'slowLog':
182180
nextTick(() => {
@@ -185,13 +183,19 @@ const changeTab = (tab: string) => {
185183
break;
186184
case 'status':
187185
nextTick(() => {
188-
statusRef.value!.acceptParams({ type: props.type, database: props.database });
186+
statusRef.value!.acceptParams({type: props.type, database: props.database});
189187
});
190188
break;
191189
case 'tuning':
192-
loadVariables();
190+
nextTick(() => {
191+
loadVariables();
192+
});
193193
break;
194194
}
195+
}, {immediate: true});
196+
197+
const changeTab = (tab: string) => {
198+
activeName.value = tab;
195199
};
196200
197201
const onSubmitChangePort = async () => {

0 commit comments

Comments
 (0)