Skip to content

Commit 7f8b3d0

Browse files
committed
add wfr_id in template/list api
1 parent 57eb6b6 commit 7f8b3d0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

internal/sql/repository/DeploymentTemplateRepository.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ type DeploymentTemplateComparisonMetadata struct {
3838
EnvironmentId int `json:"environmentId,omitempty"`
3939
EnvironmentName string `json:"environmentName,omitempty"`
4040
DeploymentTemplateHistoryId int `json:"deploymentTemplateHistoryId,omitempty"`
41+
WfrId int `json:"wfrId,omitempty"`
4142
StartedOn *time.Time `json:"startedOn,omitempty"`
4243
FinishedOn *time.Time `json:"finishedOn,omitempty"`
4344
Status string `json:"status,omitempty"`
@@ -69,7 +70,7 @@ func (impl DeploymentTemplateRepositoryImpl) FetchDeploymentHistoryWithChartRefs
6970
limit := 15
7071

7172
query := "select p.id as pipeline_id, dth.id as deployment_template_history_id," +
72-
" wfr.finished_on, wfr.status, c.chart_ref_id, c.chart_version FROM cd_workflow_runner wfr" +
73+
" wfr.id as wfr_id, wfr.finished_on, wfr.status, c.chart_ref_id, c.chart_version FROM cd_workflow_runner wfr" +
7374
" JOIN cd_workflow wf ON wf.id = wfr.cd_workflow_id JOIN pipeline p ON p.id = wf.pipeline_id" +
7475
" JOIN deployment_template_history dth ON dth.deployed_on = wfr.started_on " +
7576
"JOIN pipeline_config_override pco ON pco.cd_workflow_id = wf.id " +

0 commit comments

Comments
 (0)