From 18ad2a8a933be57859b8285d6ad3af08591fd2a4 Mon Sep 17 00:00:00 2001 From: Martin Artnik Date: Wed, 6 Aug 2025 15:41:24 +0200 Subject: [PATCH] Fix team assignments for new protocol drafts [SCI-12199] --- app/models/protocol.rb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/models/protocol.rb b/app/models/protocol.rb index 00ff966fd..0e2715aea 100644 --- a/app/models/protocol.rb +++ b/app/models/protocol.rb @@ -607,6 +607,11 @@ class Protocol < ApplicationRecord parent_protocol.user_group_assignments.each do |parent_user_group_assignment| parent_protocol.sync_child_protocol_assignment(parent_user_group_assignment, draft.id) end + + parent_protocol.team_assignments.each do |parent_team_assignment| + parent_protocol.sync_child_protocol_assignment(parent_team_assignment, draft.id) + end + draft end