mirror of https://github.com/portainer/portainer
fix(wizard): return back to envs page EE-3419 (#7065)
parent
892fdbf60d
commit
66799a53f4
|
@ -14,7 +14,7 @@
|
||||||
>
|
>
|
||||||
<i class="fa fa-trash-alt space-right" aria-hidden="true"></i>Remove
|
<i class="fa fa-trash-alt space-right" aria-hidden="true"></i>Remove
|
||||||
</button>
|
</button>
|
||||||
<button type="button" class="btn btn-sm btn-primary" ng-click="$ctrl.setRefferer()" ui-sref="portainer.wizard.endpoints" data-cy="endpoint-addEndpointButton">
|
<button type="button" class="btn btn-sm btn-primary" ng-click="$ctrl.setReferrer()" ui-sref="portainer.wizard.endpoints" data-cy="endpoint-addEndpointButton">
|
||||||
<i class="fa fa-plus-circle space-right" aria-hidden="true"></i>Add environment
|
<i class="fa fa-plus-circle space-right" aria-hidden="true"></i>Add environment
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -34,8 +34,8 @@ angular.module('portainer.app').controller('EndpointsDatatableController', [
|
||||||
this.paginationChanged();
|
this.paginationChanged();
|
||||||
};
|
};
|
||||||
|
|
||||||
this.setRefferer = function () {
|
this.setReferrer = function () {
|
||||||
window.localStorage.setItem('wizardRefferer', 'environments');
|
window.localStorage.setItem('wizardReferrer', 'environments');
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -118,8 +118,8 @@ export function EnvironmentCreationView() {
|
||||||
])
|
])
|
||||||
),
|
),
|
||||||
});
|
});
|
||||||
if (localStorage.getItem('wizardRefferer') === 'environments') {
|
if (localStorage.getItem('wizardReferrer') === 'environments') {
|
||||||
localStorage.removeItem('wizardRefferer');
|
localStorage.removeItem('wizardReferrer');
|
||||||
router.stateService.go('portainer.endpoints');
|
router.stateService.go('portainer.endpoints');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue