mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-12-24 08:43:13 +08:00
adds data-hook to copy_to_protocol_repository button [fixes SCI-2439]
This commit is contained in:
parent
1bc869d4ca
commit
86c4093bf2
1 changed files with 4 additions and 2 deletions
|
@ -32,9 +32,11 @@
|
|||
<a href="#" class="btn btn-default disabled"><span class="glyphicon glyphicon-export"></span><span class="hidden-xs-custom"> <%= t("my_modules.protocols.buttons.export") %></span></a>
|
||||
<% end %>
|
||||
<% if can_read_protocol_in_module?(@protocol) && can_create_protocols_in_repository?(@protocol.team) %>
|
||||
<%= link_to copy_to_repository_modal_protocol_path(@protocol, format: :json), id: "protocol-copy-to-repository", class: "btn btn-default", remote: true, data: { action: "copy-to-repository" } do %>
|
||||
<span class="glyphicon glyphicon-saved"></span><span class="hidden-xs-custom"> <%= t("my_modules.protocols.buttons.copy_to_repository") %></span>
|
||||
<span data-hook="protocol-copy-to-repository">
|
||||
<%= link_to copy_to_repository_modal_protocol_path(@protocol, format: :json), id: "protocol-copy-to-repository", class: "btn btn-default", remote: true, data: { action: "copy-to-repository" } do %>
|
||||
<span class="glyphicon glyphicon-saved"></span><span class="hidden-xs-custom"> <%= t("my_modules.protocols.buttons.copy_to_repository") %></span>
|
||||
<% end %>
|
||||
</span>
|
||||
<% else %>
|
||||
<a href="#" class="btn btn-default disabled"><span class="glyphicon glyphicon-saved"></span><span class="hidden-xs-custom"> <%= t("my_modules.protocols.buttons.copy_to_repository") %></span></a>
|
||||
<% end %>
|
||||
|
|
Loading…
Reference in a new issue