Skip to content

Commit 4931c61

Browse files
committed
pass group to frontend
1 parent 72895d7 commit 4931c61

File tree

11 files changed

+40
-0
lines changed

11 files changed

+40
-0
lines changed

coderd/apidoc/docs.go

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

coderd/apidoc/swagger.json

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

coderd/database/db2sdk/db2sdk.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -508,6 +508,10 @@ func Apps(dbApps []database.WorkspaceApp, statuses []database.WorkspaceAppStatus
508508
apps := make([]codersdk.WorkspaceApp, 0)
509509
for _, dbApp := range dbApps {
510510
statuses := statusesByAppID[dbApp.ID]
511+
group := ""
512+
if dbApp.DisplayGroup.Valid {
513+
group = dbApp.DisplayGroup.String
514+
}
511515
apps = append(apps, codersdk.WorkspaceApp{
512516
ID: dbApp.ID,
513517
URL: dbApp.Url.String,
@@ -525,6 +529,7 @@ func Apps(dbApps []database.WorkspaceApp, statuses []database.WorkspaceAppStatus
525529
Threshold: dbApp.HealthcheckThreshold,
526530
},
527531
Health: codersdk.WorkspaceAppHealth(dbApp.Health),
532+
Group: group,
528533
Hidden: dbApp.Hidden,
529534
OpenIn: codersdk.WorkspaceAppOpenIn(dbApp.OpenIn),
530535
Statuses: WorkspaceAppStatuses(statuses),

codersdk/workspaceapps.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ type WorkspaceApp struct {
8383
// Healthcheck specifies the configuration for checking app health.
8484
Healthcheck Healthcheck `json:"healthcheck,omitempty"`
8585
Health WorkspaceAppHealth `json:"health"`
86+
Group string `json:"group"`
8687
Hidden bool `json:"hidden"`
8788
OpenIn WorkspaceAppOpenIn `json:"open_in"`
8889

docs/reference/api/agents.md

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/reference/api/builds.md

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/reference/api/schemas.md

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy