修复:传递参数为数组

This commit is contained in:
yystopf 2026-04-02 09:23:17 +08:00
parent 8962cebd3a
commit e6c61050db
1 changed files with 2 additions and 2 deletions

View File

@ -25,7 +25,7 @@ class Admins::ResidentExpertsController < Admins::BaseController
@expert.resident_expert_actions.where.not(action_type: ResidentExpertAction::action_types[:approved]).destroy_all
@expert.resident_expert_actions.create(action_type: ResidentExpertAction::action_types[:approved], action_name: '管理员审核通过' )
@expert.resident_expert_actions.create(action_type: ResidentExpertAction::action_types[:approved], action_name: '专家主页上线' )
SendTemplateMessageJob.perform_later('ResidentExpertApproved', @expert.user_id, @expert.id)
SendTemplateMessageJob.perform_later('ResidentExpertApproved', [@expert.user_id], @expert.id)
redirect_to admins_resident_experts_path
flash[:success] = "入驻通过成功"
else
@ -39,7 +39,7 @@ class Admins::ResidentExpertsController < Admins::BaseController
@expert.resident_expert_actions.where.not(action_type: ResidentExpertAction::action_types[:approved]).destroy_all
@expert.resident_expert_actions.create(action_type: ResidentExpertAction::action_types[:rejected], action_name: '管理员驳回', action_description: params[:rejection_reason] )
@expert.resident_expert_actions.create(action_type: ResidentExpertAction::action_types[:todo], action_name: '展示上线', action_description: "待重新申请并通过审核" )
SendTemplateMessageJob.perform_later('ResidentExpertRejected', @expert.user_id, @expert.id)
SendTemplateMessageJob.perform_later('ResidentExpertRejected', [@expert.user_id], @expert.id)
redirect_to admins_resident_experts_path
flash[:success] = "入驻驳回成功"
else