mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
chore: add template_with_user view to include user contextual data (#8568)
* chore: Refactor template sql queries to use new view * TemplateWithUser -> Template * Add unit test to enforce good view
This commit is contained in:
@@ -21,12 +21,24 @@ overrides:
|
||||
- column: "templates.group_acl"
|
||||
go_type:
|
||||
type: "TemplateACL"
|
||||
- column: "template_with_users.user_acl"
|
||||
go_type:
|
||||
type: "TemplateACL"
|
||||
- column: "template_with_users.group_acl"
|
||||
go_type:
|
||||
type: "TemplateACL"
|
||||
- column: "template_with_users.created_by_avatar_url"
|
||||
go_type:
|
||||
type: "string"
|
||||
rename:
|
||||
template: TemplateTable
|
||||
template_with_user: Template
|
||||
api_key: APIKey
|
||||
api_key_scope: APIKeyScope
|
||||
api_key_scope_all: APIKeyScopeAll
|
||||
api_key_scope_application_connect: APIKeyScopeApplicationConnect
|
||||
avatar_url: AvatarURL
|
||||
created_by_avatar_url: CreatedByAvatarURL
|
||||
session_count_vscode: SessionCountVSCode
|
||||
session_count_jetbrains: SessionCountJetBrains
|
||||
session_count_reconnecting_pty: SessionCountReconnectingPTY
|
||||
|
||||
Reference in New Issue
Block a user