diff --git a/assets/vue/app/domain/activity/domain/entities/job.js b/assets/vue/app/domain/activity/domain/entities/job.js index f26a8a8..ea1882c 100644 --- a/assets/vue/app/domain/activity/domain/entities/job.js +++ b/assets/vue/app/domain/activity/domain/entities/job.js @@ -7,8 +7,12 @@ export class Job { payload = {}, result = null, error = null, + failureReason = null, createdAt = new Date().toISOString(), - updatedAt = new Date().toISOString() + updatedAt = new Date().toISOString(), + attempts = 0, + maxAttempts = 1, + context = {} }) { this.id = id; this.type = type; @@ -16,9 +20,12 @@ export class Job { this.progress = progress; this.payload = payload; this.result = result; - this.error = error; + this.error = failureReason ?? error; this.createdAt = createdAt; this.updatedAt = updatedAt; + this.attempts = attempts; + this.maxAttempts = maxAttempts; + this.context = context; } static create(data) { diff --git a/assets/vue/app/domain/activity/presentation/components/JobItem.vue b/assets/vue/app/domain/activity/presentation/components/JobItem.vue index faada3f..2521421 100644 --- a/assets/vue/app/domain/activity/presentation/components/JobItem.vue +++ b/assets/vue/app/domain/activity/presentation/components/JobItem.vue @@ -10,7 +10,12 @@