rake任文静

dev_aliyun
jingquan huang 5 years ago
parent 7218e7b47d
commit c1c210a9f3

@ -24,14 +24,16 @@ namespace :sync do
team_member = TeamMember.find_by_user_id(user_action.try(:user_id))
if team_member
# 即代理之前报名的
if team_member.created_on < ua.created_at
if team_member.created_at < ua.created_at
params = params.merge(:action_status => 1)
else
# 代理之后报名的
params = params.merge(:action_status => 2)
end
end
if ua.action_status != 2 # 代理成功报名的成绩不受影响
ua.update_attributes(params)
end
end
end
end
Loading…
Cancel
Save