From a70438ec4f441ec48367f5471d19f162fad854e1 Mon Sep 17 00:00:00 2001 From: Francesco Siddi Date: Thu, 5 May 2022 17:04:08 +0200 Subject: [PATCH] Load table data on 'tableBuilt' event Before this change, the tables would not get consistently populated with the jobs or task data. Thanks Sybren for the fix! --- web/app/src/components/JobsTable.vue | 2 +- web/app/src/components/TasksTable.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/web/app/src/components/JobsTable.vue b/web/app/src/components/JobsTable.vue index 918f66de..e52b48c4 100644 --- a/web/app/src/components/JobsTable.vue +++ b/web/app/src/components/JobsTable.vue @@ -66,7 +66,7 @@ export default { this.tabulator = new Tabulator('#flamenco_job_list', this.options); this.tabulator.on("rowSelected", this.onRowSelected); this.tabulator.on("rowDeselected", this.onRowDeselected); - this.fetchAllJobs(); + this.tabulator.on("tableBuilt", this.fetchAllJobs); }, methods: { onReconnected() { diff --git a/web/app/src/components/TasksTable.vue b/web/app/src/components/TasksTable.vue index dc1695e2..3b6f10fa 100644 --- a/web/app/src/components/TasksTable.vue +++ b/web/app/src/components/TasksTable.vue @@ -67,7 +67,7 @@ export default { this.tabulator = new Tabulator('#flamenco_task_list', this.options); this.tabulator.on("rowSelected", this.onRowSelected); this.tabulator.on("rowDeselected", this.onRowDeselected); - this.fetchTasks(); + this.tabulator.on("tableBuilt", this.fetchTasks); }, watch: { jobID() {