mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-11-13 01:41:09 +08:00
adds label to current project in clone experiment modal [fixes SCI-341]
This commit is contained in:
parent
9440371f3f
commit
d482dff2e6
2 changed files with 11 additions and 2 deletions
|
|
@ -13,7 +13,15 @@
|
||||||
<h4 class="modal-title" id="clone-experiment-modal-label"><%= t("experiments.clone.modal_title", experiment: @experiment.name ) %></h5>
|
<h4 class="modal-title" id="clone-experiment-modal-label"><%= t("experiments.clone.modal_title", experiment: @experiment.name ) %></h5>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
<%= f.select :project_id, options_for_select(@projects.collect { |p| [ p.name, p.id ] },
|
<%= f.select :project_id,
|
||||||
|
options_for_select(
|
||||||
|
@projects.collect do |p|
|
||||||
|
if p == @experiment.project
|
||||||
|
[ "#{p.name} #{t('experiments.clone.current_project')}", p.id ]
|
||||||
|
else
|
||||||
|
[ p.name, p.id ]
|
||||||
|
end
|
||||||
|
end,
|
||||||
@project.id ),
|
@project.id ),
|
||||||
{}, {class: "form-control selectpicker", "data-role" => "clear"} %>
|
{}, {class: "form-control selectpicker", "data-role" => "clear"} %>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -631,6 +631,7 @@ en:
|
||||||
modal_submit: 'Clone'
|
modal_submit: 'Clone'
|
||||||
success_flash: "Successfully cloned experiment %{experiment}"
|
success_flash: "Successfully cloned experiment %{experiment}"
|
||||||
error_flash: 'Could not clone the experiment.'
|
error_flash: 'Could not clone the experiment.'
|
||||||
|
current_project: '(current project)'
|
||||||
move:
|
move:
|
||||||
modal_title: 'Move experiment %{experiment}'
|
modal_title: 'Move experiment %{experiment}'
|
||||||
notice: 'Moving is possible only to projects that contain same (or additional) users.'
|
notice: 'Moving is possible only to projects that contain same (or additional) users.'
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue