Module: NetSuite::Actions::Upsert::Support

Defined in:
lib/netsuite/actions/upsert.rb

Instance Method Summary collapse

Instance Method Details

#upsert(credentials = {}) ⇒ Object



72
73
74
75
76
77
78
79
80
81
82
83
# File 'lib/netsuite/actions/upsert.rb', line 72

def upsert(credentials={})
  response = NetSuite::Actions::Upsert.call([self], credentials)

  @errors = response.errors

  if response.success?
    @internal_id = response.body[:@internal_id]
    true
  else
    false
  end
end