mirror of
https://github.com/coder/coder.git
synced 2025-07-03 16:13:58 +00:00
feat: add notifications inbox db (#16599)
This PR is linked [to the following issue](https://github.com/coder/internal/issues/334). The objective is to create the DB layer and migration for the new `Coder Inbox`.
This commit is contained in:
@ -168,6 +168,12 @@ func (TemplateVersion) RBACObject(template Template) rbac.Object {
|
||||
return template.RBACObject()
|
||||
}
|
||||
|
||||
func (i InboxNotification) RBACObject() rbac.Object {
|
||||
return rbac.ResourceInboxNotification.
|
||||
WithID(i.ID).
|
||||
WithOwner(i.UserID.String())
|
||||
}
|
||||
|
||||
// RBACObjectNoTemplate is for orphaned template versions.
|
||||
func (v TemplateVersion) RBACObjectNoTemplate() rbac.Object {
|
||||
return rbac.ResourceTemplate.InOrg(v.OrganizationID)
|
||||
|
Reference in New Issue
Block a user