Skip to content

Commit c36a3b8

Browse files
authored
ui: fix create menu item access (apache#9104)
Signed-off-by: Abhishek Kumar <[email protected]>
1 parent 261530c commit c36a3b8

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

ui/src/components/header/CreateMenu.vue

+6-6
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<a-dropdown>
2020
<template #overlay>
2121
<a-menu>
22-
<a-menu-item style="width: 100%; padding: 12px">
22+
<a-menu-item style="width: 100%; padding: 12px" v-if="'deployVirtualMachine' in $store.getters.apis">
2323
<router-link :to="{ path: '/action/deployVirtualMachine'}">
2424
<a-row>
2525
<a-col style="margin-right: 12px">
@@ -38,7 +38,7 @@
3838
</a-row>
3939
</router-link>
4040
</a-menu-item>
41-
<a-menu-item style="width: 100%; padding: 12px" v-if="'listKubernetesClusters' in $store.getters.apis">
41+
<a-menu-item style="width: 100%; padding: 12px" v-if="'createKubernetesCluster' in $store.getters.apis">
4242
<router-link :to="{ path: '/kubernetes', query: { action: 'createKubernetesCluster' } }">
4343
<a-row>
4444
<a-col style="margin-right: 12px">
@@ -57,7 +57,7 @@
5757
</a-row>
5858
</router-link>
5959
</a-menu-item>
60-
<a-menu-item style="width: 100%; padding: 12px">
60+
<a-menu-item style="width: 100%; padding: 12px" v-if="'createVolume' in $store.getters.apis">
6161
<router-link :to="{ path: '/volume', query: { action: 'createVolume' } }">
6262
<a-row>
6363
<a-col style="margin-right: 12px">
@@ -76,7 +76,7 @@
7676
</a-row>
7777
</router-link>
7878
</a-menu-item>
79-
<a-menu-item style="width: 100%; padding: 12px">
79+
<a-menu-item style="width: 100%; padding: 12px" v-if="'createNetwork' in $store.getters.apis">
8080
<router-link :to="{ path: '/guestnetwork', query: { action: 'createNetwork' } }">
8181
<a-row>
8282
<a-col style="margin-right: 12px">
@@ -95,7 +95,7 @@
9595
</a-row>
9696
</router-link>
9797
</a-menu-item>
98-
<a-menu-item style="width: 100%; padding: 12px">
98+
<a-menu-item style="width: 100%; padding: 12px" v-if="'createVPC' in $store.getters.apis">
9999
<router-link :to="{ path: '/vpc', query: { action: 'createVPC' } }">
100100
<a-row>
101101
<a-col style="margin-right: 12px">
@@ -114,7 +114,7 @@
114114
</a-row>
115115
</router-link>
116116
</a-menu-item>
117-
<a-menu-item style="width: 100%; padding: 12px">
117+
<a-menu-item style="width: 100%; padding: 12px" v-if="'registerTemplate' in $store.getters.apis">
118118
<router-link :to="{ path: '/template', query: { action: 'registerTemplate' } }">
119119
<a-row>
120120
<a-col style="margin-right: 12px">

0 commit comments

Comments
 (0)