From 780781e57bdd2af52aafc93afd4b11da02d522b1 Mon Sep 17 00:00:00 2001 From: Giga Chubinidze Date: Thu, 2 Mar 2023 11:35:22 +0400 Subject: [PATCH] Add the action Move to archived task & experiments view [SCI-7844] --- app/permissions/experiment.rb | 3 +-- app/permissions/my_module.rb | 1 - app/views/experiments/_table_toolbar.html.erb | 4 ++-- app/views/projects/show/_toolbar.html.erb | 2 +- 4 files changed, 4 insertions(+), 6 deletions(-) diff --git a/app/permissions/experiment.rb b/app/permissions/experiment.rb index 6279d6dc0..00c5f8768 100644 --- a/app/permissions/experiment.rb +++ b/app/permissions/experiment.rb @@ -4,8 +4,7 @@ Canaid::Permissions.register_for(Experiment) do manage_experiment_tasks manage_experiment_users archive_experiment - clone_experiment - move_experiment) + clone_experiment) .each do |perm| can perm do |_, experiment| experiment.active? && diff --git a/app/permissions/my_module.rb b/app/permissions/my_module.rb index 69a4686c4..ee5929def 100644 --- a/app/permissions/my_module.rb +++ b/app/permissions/my_module.rb @@ -21,7 +21,6 @@ Canaid::Permissions.register_for(MyModule) do update_my_module_description manage_my_module_tags update_my_module_status - move_my_module manage_my_module_steps complete_my_module_steps uncomplete_my_module_steps diff --git a/app/views/experiments/_table_toolbar.html.erb b/app/views/experiments/_table_toolbar.html.erb index daa407c11..738bedac3 100644 --- a/app/views/experiments/_table_toolbar.html.erb +++ b/app/views/experiments/_table_toolbar.html.erb @@ -12,7 +12,7 @@ <% end %> <% if can_manage_experiment?(@experiment) %> <% end %> - diff --git a/app/views/projects/show/_toolbar.html.erb b/app/views/projects/show/_toolbar.html.erb index 084469fd7..bb4909947 100644 --- a/app/views/projects/show/_toolbar.html.erb +++ b/app/views/projects/show/_toolbar.html.erb @@ -36,7 +36,7 @@ <%= button_to move_modal_experiments_path(), class: 'btn btn-light move-experiment-btn single-object-action hidden', form_class: 'move-experiments-form', - data: { for: :moveable, view_mode: 'active' }, + data: { for: :moveable }, remote: true, method: :get do %>