Commit 42c30bdb authored by Michael Kozono's avatar Michael Kozono
Browse files

Add email opt-in fields

parent 2bfb1143
class User
include FullNameSplitter
attr_accessor :first_name, :last_name, :email
attr_accessor :first_name, :last_name, :email, :email_opted_in,
:email_opted_in_ip, :email_opted_in_source, :email_opted_in_at
def initialize(params)
self.full_name = params['name'] = params['email']
self.full_name = params['name'] = params['email']
self.email_opted_in = params['email_opted_in']
self.email_opted_in_ip = params['email_opted_in_ip']
self.email_opted_in_source = params['email_opted_in_source']
self.email_opted_in_at = params['email_opted_in_at']
def to_param
......@@ -14,7 +19,10 @@ class User
firstName: first_name,
lastName: last_name,
leadSource: '',
leadSource: email_opted_in_source,
optedIn: email_opted_in,
optedInIp: email_opted_in_ip,
optedInAt: email_opted_in_at,
GitLab_com_user__c: true,
GitLab_com_user__c_account: true
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment