Ruby/Highrise API - 不保存 phone 号码?
Ruby/Highrise API - Not saving phone number?
所以我已经使用相同的代码块大约 9 个月了,当一个新的 Lead 生成时,它突然停止将 phone 号码保存到 Highrise 中......知道事情进展到哪里了侧身?我从不抛出错误,并愉快地保存了除电话 phone 号码以外的所有内容。
# create a contact Highrise from supplied information
@person = Highrise::Person.new(first_name: @lead.first_name.humanize,
last_name: @lead.last_name.humanize,
background: "automatically created by LSAL app",
contact_data: { email_addresses: [ { address: @lead.email, location: "Home" } ],
phones: [ { number: @lead.phone, location: "Mobile" } ] } )
@person.save # save contact
@person = Highrise::Person.create(:company_name => account.company, :first_name => account.first_name, :last_name => account.last_name, :contact_data => { :email_addresses => [{ :email_address => {:address => account.email, } }], :addresses => [{:address => {:city => account.city, :location =>"Work", :state => account.state, :country => account.country,:street => "#{account.address1} #{account.address2}" , :zip => account.zip} }], :phone_numbers => [{ :phone_number => { :number => number, :location =>"Work"}}] } )
希望对您有所帮助
所以我已经使用相同的代码块大约 9 个月了,当一个新的 Lead 生成时,它突然停止将 phone 号码保存到 Highrise 中......知道事情进展到哪里了侧身?我从不抛出错误,并愉快地保存了除电话 phone 号码以外的所有内容。
# create a contact Highrise from supplied information
@person = Highrise::Person.new(first_name: @lead.first_name.humanize,
last_name: @lead.last_name.humanize,
background: "automatically created by LSAL app",
contact_data: { email_addresses: [ { address: @lead.email, location: "Home" } ],
phones: [ { number: @lead.phone, location: "Mobile" } ] } )
@person.save # save contact
@person = Highrise::Person.create(:company_name => account.company, :first_name => account.first_name, :last_name => account.last_name, :contact_data => { :email_addresses => [{ :email_address => {:address => account.email, } }], :addresses => [{:address => {:city => account.city, :location =>"Work", :state => account.state, :country => account.country,:street => "#{account.address1} #{account.address2}" , :zip => account.zip} }], :phone_numbers => [{ :phone_number => { :number => number, :location =>"Work"}}] } )
希望对您有所帮助