mirror of
https://github.com/portainer/portainer.git
synced 2025-08-09 07:45:22 +02:00
refactor(docker/configs): remove EndpointProvider [EE-5746] (#9198)
This commit is contained in:
parent
cd3c6e3089
commit
1b0fd60115
7 changed files with 25 additions and 23 deletions
|
@ -6,7 +6,8 @@ angular.module('portainer.docker').controller('ConfigController', [
|
|||
'$state',
|
||||
'ConfigService',
|
||||
'Notifications',
|
||||
function ($scope, $transition$, $state, ConfigService, Notifications) {
|
||||
'endpoint',
|
||||
function ($scope, $transition$, $state, ConfigService, Notifications, endpoint) {
|
||||
$scope.resourceType = ResourceControlType.Config;
|
||||
|
||||
$scope.onUpdateResourceControlSuccess = function () {
|
||||
|
@ -14,7 +15,7 @@ angular.module('portainer.docker').controller('ConfigController', [
|
|||
};
|
||||
|
||||
$scope.removeConfig = function removeConfig(configId) {
|
||||
ConfigService.remove(configId)
|
||||
ConfigService.remove(endpoint.Id, configId)
|
||||
.then(function success() {
|
||||
Notifications.success('Success', 'Configuration successfully removed');
|
||||
$state.go('docker.configs', {});
|
||||
|
@ -25,7 +26,7 @@ angular.module('portainer.docker').controller('ConfigController', [
|
|||
};
|
||||
|
||||
function initView() {
|
||||
ConfigService.config($transition$.params().id)
|
||||
ConfigService.config(endpoint.Id, $transition$.params().id)
|
||||
.then(function success(data) {
|
||||
$scope.config = data;
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue