Merge remote-tracking branch 'origin/standalone_develop' into standalone_develop

This commit is contained in:
“xxq250” 2022-07-22 10:12:19 +08:00
commit 0b167026f8
1 changed files with 5 additions and 0 deletions

View File

@ -3,6 +3,7 @@ class Traces::ProjectsController < Traces::BaseController
before_action :require_login before_action :require_login
before_action :load_project before_action :load_project
before_action :set_trace_token_to_cookie
before_action :authorizate_user_can_edit_project!, except: [:task_results] before_action :authorizate_user_can_edit_project!, except: [:task_results]
def tasks def tasks
@ -86,4 +87,8 @@ class Traces::ProjectsController < Traces::BaseController
puts exception.message puts exception.message
normal_status(-1, exception.message) normal_status(-1, exception.message)
end end
def set_trace_token_to_cookie
cookies[:vue_admin_template_token] = current_user&.trace_token
end
end end