From 087f81a6aad001ca7d26a8633b8f8c03fdeab843 Mon Sep 17 00:00:00 2001 From: Jasder <2053003901@@qq.com> Date: Tue, 25 Aug 2020 17:59:32 +0800 Subject: [PATCH] ADD duration time for stage and step --- app/views/ci/builds/_stage.json.jbuilder | 1 + app/views/ci/builds/_step.json.jbuilder | 1 + 2 files changed, 2 insertions(+) diff --git a/app/views/ci/builds/_stage.json.jbuilder b/app/views/ci/builds/_stage.json.jbuilder index 256f81e77..57c68bf63 100644 --- a/app/views/ci/builds/_stage.json.jbuilder +++ b/app/views/ci/builds/_stage.json.jbuilder @@ -14,6 +14,7 @@ json.started format_utc_time(stage.stage_started) json.stopped format_utc_time(stage.stage_stopped) json.created format_utc_time(stage.stage_created) json.updated format_utc_time(stage.stage_updated) +json.duration_time render_duartion_time(stage.stage_started, stage.stage_stopped) json.version stage.stage_version json.on_success stage.stage_on_success json.on_failure stage.stage_on_failure diff --git a/app/views/ci/builds/_step.json.jbuilder b/app/views/ci/builds/_step.json.jbuilder index 93b1353fc..970149d89 100644 --- a/app/views/ci/builds/_step.json.jbuilder +++ b/app/views/ci/builds/_step.json.jbuilder @@ -5,4 +5,5 @@ json.status step.step_status json.exit_code step.step_exit_code json.started format_utc_time(step.step_started) json.stopped format_utc_time(step.step_stopped) +json.duration_time render_duartion_time(step.step_started, step.step_stopped) json.version step.step_version