File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -529,6 +529,24 @@ const user = {
529529 } )
530530 } )
531531 } ,
532+ RefreshZones ( { commit } ) {
533+ return new Promise ( ( resolve , reject ) => {
534+ api ( 'listZones' ) . then ( json => {
535+ const zones = json . listzonesresponse . zone || [ ]
536+ commit ( 'SET_ZONES' , zones )
537+ resolve ( zones )
538+ } ) . catch ( error => {
539+ reject ( error )
540+ } )
541+ api (
542+ 'listNetworkServiceProviders' ,
543+ { name : 'SecurityGroupProvider' , state : 'Enabled' }
544+ ) . then ( response => {
545+ const showSecurityGroups = response . listnetworkserviceprovidersresponse . count > 0
546+ commit ( 'SET_SHOW_SECURITY_GROUPS' , showSecurityGroups )
547+ } ) . catch ( ignored => { } )
548+ } )
549+ } ,
532550 RefreshFeatures ( { commit } ) {
533551 return new Promise ( ( resolve , reject ) => {
534552 api ( 'listCapabilities' ) . then ( response => {
Original file line number Diff line number Diff line change @@ -1733,6 +1733,7 @@ export default {
17331733
17341734 try {
17351735 await this .enableZone (params)
1736+ await this .$store .dispatch (' RefreshZones' ).catch (() => {})
17361737 await this .$message .success (' Success' )
17371738 this .loading = false
17381739 this .steps = []
You can’t perform that action at this time.
0 commit comments