mirror of https://github.com/apache/cloudstack.git
ui: Hidden features checkbox as user role (#5597)
* hidden features checkbox as user role * change display conditions
This commit is contained in:
parent
f2ca11fc68
commit
e63234e8fc
|
|
@ -144,17 +144,11 @@
|
|||
<a-form-item
|
||||
:label="$t('label.ispublic')"
|
||||
v-if="$store.getters.userInfo.roletype === 'Admin' || $store.getters.features.userpublictemplateenabled" >
|
||||
<a-switch
|
||||
v-decorator="['ispublic', {
|
||||
initialValue: false
|
||||
}]" />
|
||||
<a-switch v-decorator="['ispublic', { initialValue: false }]" />
|
||||
</a-form-item>
|
||||
|
||||
<a-form-item :label="$t('label.isfeatured')">
|
||||
<a-switch
|
||||
v-decorator="['isfeatured', {
|
||||
initialValue: false
|
||||
}]" />
|
||||
<a-form-item :label="$t('label.isfeatured')" v-if="$store.getters.userInfo.roletype === 'Admin'">
|
||||
<a-switch v-decorator="['isfeatured', { initialValue: false }]" />
|
||||
</a-form-item>
|
||||
|
||||
<div :span="24" class="action-button">
|
||||
|
|
|
|||
|
|
@ -350,8 +350,6 @@
|
|||
{{ $t('label.passwordenabled') }}
|
||||
</a-checkbox>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-checkbox value="isdynamicallyscalable">
|
||||
{{ $t('label.isdynamicallyscalable') }}
|
||||
|
|
@ -362,23 +360,17 @@
|
|||
{{ $t('label.requireshvm') }}
|
||||
</a-checkbox>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12">
|
||||
<a-col :span="12" v-if="isAdminRole">
|
||||
<a-checkbox value="isfeatured">
|
||||
{{ $t('label.isfeatured') }}
|
||||
</a-checkbox>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-checkbox
|
||||
value="ispublic"
|
||||
v-if="$store.getters.userInfo.roletype === 'Admin' || $store.getters.features.userpublictemplateenabled" >
|
||||
<a-col :span="12" v-if="isAdminRole || $store.getters.features.userpublictemplateenabled">
|
||||
<a-checkbox value="ispublic">
|
||||
{{ $t('label.ispublic') }}
|
||||
</a-checkbox>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :span="12" v-if="$store.getters.userInfo.roletype === 'Admin'">
|
||||
<a-col :span="12" v-if="isAdminRole">
|
||||
<a-checkbox value="isrouting">
|
||||
{{ $t('label.isrouting') }}
|
||||
</a-checkbox>
|
||||
|
|
@ -473,6 +465,9 @@ export default {
|
|||
this.fetchData()
|
||||
},
|
||||
computed: {
|
||||
isAdminRole () {
|
||||
return this.$store.getters.userInfo.roletype === 'Admin'
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
fetchData () {
|
||||
|
|
|
|||
Loading…
Reference in New Issue