mirror of
https://github.com/datarhei/core.git
synced 2025-12-24 13:07:56 +08:00
Fix correctly assign input and output IDs to progress data for report history
This commit is contained in:
@@ -337,21 +337,8 @@ func (t *task) Report() (*app.Report, error) {
|
||||
report.History[i].UnmarshalParser(&h)
|
||||
e := &report.History[i]
|
||||
|
||||
for i, p := range e.Progress.Input {
|
||||
if int(p.Index) >= len(t.process.Config.Input) {
|
||||
continue
|
||||
}
|
||||
|
||||
e.Progress.Input[i].ID = t.process.Config.Input[p.Index].ID
|
||||
}
|
||||
|
||||
for i, p := range e.Progress.Output {
|
||||
if int(p.Index) >= len(t.process.Config.Output) {
|
||||
continue
|
||||
}
|
||||
|
||||
e.Progress.Output[i].ID = t.process.Config.Output[p.Index].ID
|
||||
}
|
||||
e.Progress.Input = assignConfigID(e.Progress.Input, t.process.Config.Input)
|
||||
e.Progress.Output = assignConfigID(e.Progress.Output, t.process.Config.Input)
|
||||
}
|
||||
|
||||
return report, nil
|
||||
|
||||
Reference in New Issue
Block a user