This is an automated email from the ASF dual-hosted git repository.

dahn pushed a commit to branch 4.20
in repository https://gitbox.apache.org/repos/asf/cloudstack.git


The following commit(s) were added to refs/heads/4.20 by this push:
     new 6a145358a92 ui: fix tab name in query params (#11590)
6a145358a92 is described below

commit 6a145358a92c16a7a371349a763375d63b66fc21
Author: Abhishek Kumar <abhishek.mr...@gmail.com>
AuthorDate: Mon Sep 15 15:02:10 2025 +0530

    ui: fix tab name in query params (#11590)
---
 ui/src/components/view/ResourceView.vue | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/ui/src/components/view/ResourceView.vue 
b/ui/src/components/view/ResourceView.vue
index 2c1764da143..af27a3d1b95 100644
--- a/ui/src/components/view/ResourceView.vue
+++ b/ui/src/components/view/ResourceView.vue
@@ -33,17 +33,17 @@
             :is="tabs[0].component"
             :resource="resource"
             :loading="loading"
-            :tab="tabs[0].name" />
+            :tab="tabName(tabs[0])" />
         </keep-alive>
         <a-tabs
           v-else
           style="width: 100%; margin-top: -12px"
           :animated="false"
-          :activeKey="activeTab || tabs[0].name"
+          :activeKey="activeTab || tabName(tabs[0])"
           @change="onTabChange" >
-          <template v-for="tab in tabs" :key="tab.name">
+          <template v-for="tab in tabs" :key="tabName(tab)">
             <a-tab-pane
-              :key="tab.name"
+              :key="tabName(tab)"
               :tab="$t('label.' + tabName(tab))"
               v-if="showTab(tab)">
               <keep-alive>
@@ -183,12 +183,12 @@ export default {
         return
       }
       if (!this.historyTab || !this.$route.meta.tabs || 
this.$route.meta.tabs.length === 0) {
-        this.activeTab = this.tabs[0].name
+        this.activeTab = this.tabName(this.tabs[0])
         return
       }
-      const tabIdx = this.$route.meta.tabs.findIndex(tab => tab.name === 
this.historyTab)
+      const tabIdx = this.$route.meta.tabs.findIndex(tab => this.tabName(tab) 
=== this.historyTab)
       if (tabIdx === -1) {
-        this.activeTab = this.tabs[0].name
+        this.activeTab = this.tabName(this.tabs[0])
       } else {
         this.activeTab = this.historyTab
       }

Reply via email to