diff options
Diffstat (limited to 'src/marlin.web/Models')
| -rw-r--r-- | src/marlin.web/Models/Job.cs | 13 | ||||
| -rw-r--r-- | src/marlin.web/Models/LogEventRecord.cs | 16 |
2 files changed, 20 insertions, 9 deletions
diff --git a/src/marlin.web/Models/Job.cs b/src/marlin.web/Models/Job.cs index bd60773..f7b6278 100644 --- a/src/marlin.web/Models/Job.cs +++ b/src/marlin.web/Models/Job.cs @@ -1,5 +1,7 @@ namespace marlin.web.Models; +using core.models; + public class Job { public Guid Id { get; set; } @@ -25,6 +27,8 @@ public class Job public string Recipe { get; set; } // plan + + public ICollection<LogEventRecord> Logs { get; set; } } public class JobStatusUpdate @@ -36,13 +40,4 @@ public class JobStatusUpdate public DateTime At { get; set; } public JobStatus Status { get; set; } -} - -public enum JobStatus -{ - Pending, - Active, - Cancelled, - Success, - Failed }
\ No newline at end of file diff --git a/src/marlin.web/Models/LogEventRecord.cs b/src/marlin.web/Models/LogEventRecord.cs new file mode 100644 index 0000000..1a916d8 --- /dev/null +++ b/src/marlin.web/Models/LogEventRecord.cs @@ -0,0 +1,16 @@ +namespace marlin.web.Models; + +using core.models; + +public class LogEventRecord +{ + public Guid Id { get; set; } + + public Guid JobId { get; set; } + public Job? Job { get; set; } + + public DateTime At { get; set; } + public string Message { get; set; } + public bool Error { get; set; } + public string StepId { get; set; } +}
\ No newline at end of file |
