1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-08-05 05:45:22 +02:00

refactor(docker/containers): migrate inspect view to react [EE-2190] (#11005)
Some checks failed
ci / build_images (map[arch:amd64 platform:linux version:]) (push) Has been cancelled
ci / build_images (map[arch:amd64 platform:windows version:1809]) (push) Has been cancelled
ci / build_images (map[arch:amd64 platform:windows version:ltsc2022]) (push) Has been cancelled
ci / build_images (map[arch:arm platform:linux version:]) (push) Has been cancelled
ci / build_images (map[arch:arm64 platform:linux version:]) (push) Has been cancelled
ci / build_images (map[arch:ppc64le platform:linux version:]) (push) Has been cancelled
ci / build_images (map[arch:s390x platform:linux version:]) (push) Has been cancelled
/ triage (push) Has been cancelled
Lint / Run linters (push) Has been cancelled
Test / test-client (push) Has been cancelled
Test / test-server (map[arch:amd64 platform:linux]) (push) Has been cancelled
Test / test-server (map[arch:amd64 platform:windows version:1809]) (push) Has been cancelled
Test / test-server (map[arch:amd64 platform:windows version:ltsc2022]) (push) Has been cancelled
Test / test-server (map[arch:arm64 platform:linux]) (push) Has been cancelled
ci / build_manifests (push) Has been cancelled

This commit is contained in:
Chaim Lev-Ari 2024-04-11 19:07:58 +03:00 committed by GitHub
parent de473fc10e
commit 2100155ab5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
17 changed files with 181 additions and 105 deletions

View file

@ -1,27 +0,0 @@
angular.module('portainer.docker').controller('ContainerInspectController', [
'$scope',
'$transition$',
'Notifications',
'ContainerService',
'HttpRequestHelper',
'endpoint',
function ($scope, $transition$, Notifications, ContainerService, HttpRequestHelper, endpoint) {
$scope.state = {
DisplayTextView: false,
};
$scope.containerInfo = {};
function initView() {
HttpRequestHelper.setPortainerAgentTargetHeader($transition$.params().nodeName);
ContainerService.inspect(endpoint.Id, $transition$.params().id)
.then(function success(d) {
$scope.containerInfo = d;
})
.catch(function error(e) {
Notifications.error('Failure', e, 'Unable to inspect container');
});
}
initView();
},
]);

View file

@ -1,28 +0,0 @@
<page-header
title="'Container inspect'"
breadcrumbs="[
{ label:'Containers', link:'docker.containers' },
{
label:(containerInfo.Name | trimcontainername),
link: 'docker.containers.container',
linkParams: { id: containerInfo.Id },
}, 'Inspect']"
>
</page-header>
<div class="row">
<div class="col-lg-12 col-md-12 col-xs-12">
<rd-widget>
<rd-widget-header icon="circle" title-text="Inspect">
<span class="btn-group btn-group-sm">
<label class="btn btn-light" ng-model="state.DisplayTextView" uib-btn-radio="false"><pr-icon icon="'code'"></pr-icon>Tree</label>
<label class="btn btn-light" ng-model="state.DisplayTextView" uib-btn-radio="true"><pr-icon icon="'file'"></pr-icon>Text</label>
</span>
</rd-widget-header>
<rd-widget-body>
<pre ng-show="state.DisplayTextView">{{ containerInfo | json: 4 }}</pre>
<json-tree ng-hide="state.DisplayTextView" object="containerInfo" root-name="containerInfo.Id" start-expanded="true"></json-tree>
</rd-widget-body>
</rd-widget>
</div>
</div>