DB: Add tables for tracking project extending delegations to teams

This commit is contained in:
Pere Lev 2024-05-14 23:14:12 +03:00
parent d23144e2c4
commit 46cb13e5b0
No known key found for this signature in database
GPG key ID: 5252C5C863E5E57D
4 changed files with 61 additions and 1 deletions

View file

@ -0,0 +1,24 @@
ComponentConvey
component ComponentEnableId
team SquadUsStartId
grant OutboxItemId
UniqueComponentConvey component team
UniqueComponentConveyGrant grant
SourceUsConvey
source SourceUsSendDelegatorId
team SquadUsStartId
grant OutboxItemId
SourceUsConveyFromLocal
convey SourceUsConveyId
from SourceThemDelegateLocalId
UniqueSourceUsConveyFromLocal convey
SourceUsConveyFromRemote
convey SourceUsConveyId
from SourceThemDelegateRemoteId
UniqueSourceUsConveyFromRemote convey

View file

@ -3811,6 +3811,8 @@ changes hLocal ctx =
, removeEntity "StemIdentLoom" , removeEntity "StemIdentLoom"
-- 638 -- 638
, addEntities model_638_effort_squad , addEntities model_638_effort_squad
-- 639
, addEntities model_639_component_convey
] ]
migrateDB migrateDB

View file

@ -77,6 +77,7 @@ module Vervis.Migration.Entities
, model_603_resource , model_603_resource
, model_626_komponent , model_626_komponent
, model_638_effort_squad , model_638_effort_squad
, model_639_component_convey
) )
where where
@ -301,3 +302,6 @@ model_626_komponent = $(schema "626_2024-04-29_komponent")
model_638_effort_squad :: [Entity SqlBackend] model_638_effort_squad :: [Entity SqlBackend]
model_638_effort_squad = $(schema "638_2024-05-14_effort_squad") model_638_effort_squad = $(schema "638_2024-05-14_effort_squad")
model_639_component_convey :: [Entity SqlBackend]
model_639_component_convey = $(schema "639_2024-05-14_component_convey")

View file

@ -1073,6 +1073,16 @@ ComponentGather
UniqueComponentGather component parent UniqueComponentGather component parent
UniqueComponentGatherGrant grant UniqueComponentGatherGrant grant
-- Witnesses that the project has extended the delegation to a given team
ComponentConvey
component ComponentEnableId
team SquadUsStartId
grant OutboxItemId
UniqueComponentConvey component team
UniqueComponentConveyGrant grant
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
-- Components, from component perspective -- Components, from component perspective
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
@ -1432,6 +1442,26 @@ SourceUsLeafToRemote
UniqueSourceUsLeafToRemote leaf UniqueSourceUsLeafToRemote leaf
-- Witnesses that, seeing the delegation from them, I've sent an
-- extension-Grant to a team-collaborator of mine
SourceUsConvey
source SourceUsSendDelegatorId
team SquadUsStartId
grant OutboxItemId
SourceUsConveyFromLocal
convey SourceUsConveyId
from SourceThemDelegateLocalId
UniqueSourceUsConveyFromLocal convey
SourceUsConveyFromRemote
convey SourceUsConveyId
from SourceThemDelegateRemoteId
UniqueSourceUsConveyFromRemote convey
-------------------------------- Source remove ------------------------------- -------------------------------- Source remove -------------------------------
-- Witnesses there's a removal request from the child's side, and I'm waiting -- Witnesses there's a removal request from the child's side, and I'm waiting
@ -1971,7 +2001,7 @@ SquadThemSendDelegatorRemote
UniqueSquadThemSendDelegatorRemoteTopic topic UniqueSquadThemSendDelegatorRemoteTopic topic
UniqueSquadThemSendDelegatorRemoteGrant grant UniqueSquadThemSendDelegatorRemoteGrant grant
-- Witnesses that, seeing the delegator-Grant, I've sent my new parent a -- Witnesses that, seeing the delegator-Grant, I've sent my new team a
-- start-Grant to delegate further -- start-Grant to delegate further
SquadUsStart SquadUsStart