mirror of
https://github.com/coder/coder.git
synced 2025-07-08 11:39:50 +00:00
fix: do not skip properties on creating templates (#5060)
* fix: do not skip properties while creating templates * test: empty edit
This commit is contained in:
@ -2091,6 +2091,8 @@ func (q *fakeQuerier) InsertTemplate(_ context.Context, arg database.InsertTempl
|
||||
CreatedBy: arg.CreatedBy,
|
||||
UserACL: arg.UserACL,
|
||||
GroupACL: arg.GroupACL,
|
||||
DisplayName: arg.DisplayName,
|
||||
Icon: arg.Icon,
|
||||
}
|
||||
q.templates = append(q.templates, template)
|
||||
return template, nil
|
||||
|
@ -239,6 +239,8 @@ func (api *API) postTemplateByOrganization(rw http.ResponseWriter, r *http.Reque
|
||||
GroupACL: database.TemplateACL{
|
||||
organization.ID.String(): []rbac.Action{rbac.ActionRead},
|
||||
},
|
||||
DisplayName: createTemplate.DisplayName,
|
||||
Icon: createTemplate.Icon,
|
||||
})
|
||||
if err != nil {
|
||||
return xerrors.Errorf("insert template: %s", err)
|
||||
|
Reference in New Issue
Block a user