mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-01-01 13:13:22 +08:00
Merge pull request #90 from ZmagoD/zd_SCI_376
fixes cloned experiment protocol [fixes SCI-376]
This commit is contained in:
commit
0de7ea31ea
2 changed files with 8 additions and 1 deletions
|
@ -312,6 +312,13 @@ class MyModule < ActiveRecord::Base
|
|||
clone.protocols << self.protocol.deep_clone_my_module(self, current_user)
|
||||
clone.reload
|
||||
|
||||
# fixes linked protocols
|
||||
clone.protocols.each do |protocol|
|
||||
next unless protocol.linked?
|
||||
protocol.updated_at = protocol.parent_updated_at
|
||||
protocol.save
|
||||
end
|
||||
|
||||
return clone
|
||||
end
|
||||
|
||||
|
|
|
@ -144,4 +144,4 @@
|
|||
</ul>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in a new issue