导入邮箱为空报错

ecloud_sso
daiao 5 years ago
parent 47202869e7
commit 3a8395f906

@ -157,7 +157,7 @@ namespace :tfxy do
2.upto(student_data_last_row) do |r|
# 邮箱存在
if student_data.cell(r, 9).strip.present?
if student_data.cell(r, 9)&.strip.present?
old_user = User.where("phone = '#{student_data.cell(r, 8)}' OR mail = '#{student_data.cell(r, 9).strip}' OR login = 'tfxy#{student_data.cell(r, 1)}' " ).first
else
old_user = User.where("phone = '#{student_data.cell(r, 8)}' OR login = 'tfxy#{student_data.cell(r, 1)}' " ).first

Loading…
Cancel
Save