Importa i prospect Basket senza email vuote e senza toccare le altre campagne.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -12,6 +12,7 @@ class CampaignImport::MatchlivetvLaunch
|
||||
"LIMITATO" => "limited",
|
||||
"SI / PARZIALE" => "yes_partial",
|
||||
"SI" => "yes",
|
||||
"RILEVATO" => "yes",
|
||||
"SI - SPORTCAM" => "yes_sportcam",
|
||||
"SI SPORTCAM" => "yes_sportcam"
|
||||
}.freeze
|
||||
@@ -53,7 +54,7 @@ class CampaignImport::MatchlivetvLaunch
|
||||
|
||||
rows.each_with_index do |row, idx|
|
||||
name = cell(row, "Società")
|
||||
if duplicate_name?(name)
|
||||
if duplicate_name?(name) || normalize_email(cell(row, "Email verificata")).blank?
|
||||
skipped += 1
|
||||
next
|
||||
end
|
||||
@@ -190,7 +191,7 @@ class CampaignImport::MatchlivetvLaunch
|
||||
end
|
||||
|
||||
def normalize_email(value)
|
||||
email = value.to_s.strip.downcase.gsub(/\s+/, "")
|
||||
email = I18n.transliterate(value.to_s).strip.downcase.gsub(/\s+/, "")
|
||||
email.presence
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user