mirror of
https://github.com/portainer/portainer.git
synced 2025-07-24 07:49:41 +02:00
Add several
- Add search box to easily find containers in network. This required an addition to angular-vis which is in a pending pull request: https://github.com/visjs/angular-visjs/pull/22 - Add tooltip to easily visualize container id and image name. - Add options to hide containers (and showAll to reset view) to ease visualization when there are too many containers.
This commit is contained in:
parent
008884ec59
commit
9e713b7b81
8 changed files with 146 additions and 46 deletions
5
assets/js/angular-vis.js
vendored
5
assets/js/angular-vis.js
vendored
|
@ -92,7 +92,8 @@ angular.module('ngVis', [])
|
|||
scope: {
|
||||
data: '=',
|
||||
options: '=',
|
||||
events: '='
|
||||
events: '=',
|
||||
component: '='
|
||||
},
|
||||
link: function (scope, element, attr) {
|
||||
var networkEvents = [
|
||||
|
@ -103,6 +104,7 @@ angular.module('ngVis', [])
|
|||
];
|
||||
|
||||
var network = new vis.Network(element[0], scope.data, scope.options);
|
||||
scope.component = network;
|
||||
|
||||
scope.$watch('data', function () {
|
||||
// Sanity check
|
||||
|
@ -118,6 +120,7 @@ angular.module('ngVis', [])
|
|||
|
||||
// Create the graph2d object
|
||||
network = new vis.Network(element[0]);
|
||||
scope.component = network;
|
||||
|
||||
// Attach an event handler if defined
|
||||
angular.forEach(scope.events, function (callback, event) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue