diff --git a/app/controllers/result_tables_controller.rb b/app/controllers/result_tables_controller.rb index 711f5baa0..c2e640474 100644 --- a/app/controllers/result_tables_controller.rb +++ b/app/controllers/result_tables_controller.rb @@ -46,7 +46,7 @@ class ResultTablesController < ApplicationController Activity.create( type_of: :add_result, user: current_user, - project: @my_module.project, + project: @my_module.experiment.project, my_module: @my_module, message: t( "activities.add_table_result", @@ -102,7 +102,7 @@ class ResultTablesController < ApplicationController if saved Activity.create( type_of: :archive_result, - project: @my_module.project, + project: @my_module.experiment.project, my_module: @my_module, user: current_user, message: t( @@ -121,7 +121,7 @@ class ResultTablesController < ApplicationController Activity.create( type_of: :edit_result, user: current_user, - project: @my_module.project, + project: @my_module.experiment.project, my_module: @my_module, message: t( "activities.edit_table_result", diff --git a/app/controllers/result_texts_controller.rb b/app/controllers/result_texts_controller.rb index c5bf778eb..d1de9c694 100644 --- a/app/controllers/result_texts_controller.rb +++ b/app/controllers/result_texts_controller.rb @@ -43,7 +43,7 @@ class ResultTextsController < ApplicationController Activity.create( type_of: :add_result, user: current_user, - project: @my_module.project, + project: @my_module.experiment.project, my_module: @my_module, message: t( "activities.add_text_result", @@ -102,7 +102,7 @@ class ResultTextsController < ApplicationController if saved Activity.create( type_of: :archive_result, - project: @my_module.project, + project: @my_module.experiment.project, my_module: @my_module, user: current_user, message: t( @@ -121,7 +121,7 @@ class ResultTextsController < ApplicationController Activity.create( type_of: :edit_result, user: current_user, - project: @my_module.project, + project: @my_module.experiment.project, my_module: @my_module, message: t( "activities.edit_text_result",