issues25489
daiao 5 years ago
parent d416224174
commit cfdb17e24f

@ -49,10 +49,10 @@ class TrustieHacksController < ApplicationController
# 报名入口 # 报名入口
def entry def entry
if @hack.hack_users.exists?(user_id: current_user) if @hack.hack_users.exists?(user_id: current_user.id)
render_error('已经报名,请勿重复操作') render_error('已经报名,请勿重复操作')
else else
@hack.hack_users.create(user_id: current_user) @hack.hack_users.create(user_id: current_user.id)
render_ok render_ok
end end
end end

Loading…
Cancel
Save