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

refactor(docker/events): migrate list view to react [EE-2228] (#11581)

This commit is contained in:
Chaim Lev-Ari 2024-08-28 13:41:15 -06:00 committed by GitHub
parent 9797201c2a
commit 33ce841040
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
11 changed files with 71 additions and 69 deletions

View file

@ -1,3 +0,0 @@
<page-header title="'Event list'" breadcrumbs="['Events']" reload="true"> </page-header>
<docker-events-datatable dataset="events"></docker-events-datatable>

View file

@ -1,23 +0,0 @@
import moment from 'moment';
angular.module('portainer.docker').controller('EventsController', [
'$scope',
'Notifications',
'SystemService',
function ($scope, Notifications, SystemService) {
function initView() {
const since = moment().subtract(24, 'hour').unix();
const until = moment().unix();
SystemService.events({ since, until })
.then(function success(data) {
$scope.events = data;
})
.catch(function error(err) {
Notifications.error('Failure', err, 'Unable to load events');
});
}
initView();
},
]);