]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/+admin/system/jobs/jobs.component.ts
Add `i18n` prop where it is missing (#3946)
[github/Chocobozzz/PeerTube.git] / client / src / app / +admin / system / jobs / jobs.component.ts
index 6ab17b3c15d8eb0950f7673035bb03636e5c4164..43578eedd434a4f9c92cd50754b7c21ec73e5a27 100644 (file)
@@ -22,18 +22,21 @@ export class JobsComponent extends RestTable implements OnInit {
   jobType: JobTypeClient = 'all'
   jobTypes: JobTypeClient[] = [
     'all',
+
     'activitypub-follow',
     'activitypub-http-broadcast',
     'activitypub-http-fetcher',
     'activitypub-http-unicast',
+    'activitypub-refresher',
+    'activitypub-cleaner',
+    'actor-keys',
     'email',
-    'video-transcoding',
     'video-file-import',
     'video-import',
-    'videos-views',
-    'activitypub-refresher',
+    'video-live-ending',
     'video-redundancy',
-    'video-live-ending'
+    'video-transcoding',
+    'videos-views'
   ]
 
   jobs: Job[] = []
@@ -44,7 +47,7 @@ export class JobsComponent extends RestTable implements OnInit {
   constructor (
     private notifier: Notifier,
     private jobsService: JobService
-    ) {
+  ) {
     super()
   }
 
@@ -73,7 +76,11 @@ export class JobsComponent extends RestTable implements OnInit {
   }
 
   getColspan () {
-    return this.jobState === 'all' ? 5 : 4
+    if (this.jobState === 'all' && this.hasProgress()) return 7
+
+    if (this.jobState === 'all' || this.hasProgress()) return 6
+
+    return 5
   }
 
   onJobStateOrTypeChanged () {
@@ -93,6 +100,13 @@ export class JobsComponent extends RestTable implements OnInit {
     return ''
   }
 
+  refresh () {
+    this.jobs = []
+    this.totalRecords = 0
+
+    this.loadData()
+  }
+
   protected loadData () {
     let jobState = this.jobState as JobState
     if (this.jobState === 'all') jobState = null