From 8787e0de6e703e0ac22df2b6ed55a3d8fc61865c Mon Sep 17 00:00:00 2001 From: Kelly Merrick Date: Wed, 17 Jul 2024 15:51:49 -0500 Subject: [PATCH 1/2] fix(api): add ref to dashboard build partial --- api/dashboard/get.go | 1 + api/types/dashboard.go | 1 + 2 files changed, 2 insertions(+) diff --git a/api/dashboard/get.go b/api/dashboard/get.go index c009e4127..1ed895955 100644 --- a/api/dashboard/get.go +++ b/api/dashboard/get.go @@ -116,6 +116,7 @@ func buildRepoPartials(c context.Context, repos []*types.DashboardRepo) ([]types Status: build.GetStatus(), Started: build.GetStarted(), Finished: build.GetFinished(), + Ref: build.GetRef(), Sender: build.GetSender(), Branch: build.GetBranch(), Event: build.GetEvent(), diff --git a/api/types/dashboard.go b/api/types/dashboard.go index 08954350f..dc51acbbd 100644 --- a/api/types/dashboard.go +++ b/api/types/dashboard.go @@ -23,6 +23,7 @@ type BuildPartial struct { Started int64 `json:"started,omitempty"` Finished int64 `json:"finished,omitempty"` Sender string `json:"sender,omitempty"` + Ref string `json:"ref,omitempty"` Status string `json:"status,omitempty"` Event string `json:"event,omitempty"` Branch string `json:"branch,omitempty"` From b086d7cad54975922339f1dc858e075fc2904b3f Mon Sep 17 00:00:00 2001 From: Kelly Merrick Date: Thu, 18 Jul 2024 10:29:56 -0500 Subject: [PATCH 2/2] fix(api): add ref to dashboard mock --- mock/server/dashboard.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mock/server/dashboard.go b/mock/server/dashboard.go index c2a017050..2b89c3265 100644 --- a/mock/server/dashboard.go +++ b/mock/server/dashboard.go @@ -81,6 +81,7 @@ const ( "number": 1, "started": 1714678666, "finished": 1714678672, + "ref": "refs/heads/main", "sender": "Octocat", "status": "failure", "event": "deployment", @@ -134,6 +135,7 @@ const ( "number": 1, "started": 1714678666, "finished": 1714678672, + "ref": "refs/heads/main", "sender": "Octocat", "status": "failure", "event": "deployment", @@ -184,6 +186,7 @@ const ( "number": 1, "started": 1714678666, "finished": 1714678672, + "ref": "refs/heads/main", "sender": "Octocat", "status": "failure", "event": "deployment",