Vishnu Gupta
10/31/2019, 4:00 PMvar createCustomer = record.create({
type: record.Type.CUSTOMER,
isDynamic: false,
defaultValue: null
});
log.debug('create customer',createCustomer);
createCustomer.setValue({
fieldId: 'firstname',
value: context.firstname
});
createCustomer.setValue({
fieldId: 'lastname',
value: context.lastname
});
createCustomer.setValue({
fieldId: 'email',
value: context.email
});
createCustomer.setValue({
fieldId: 'phone',
value: context.phone
});
//submit the record
var id = createCustomer.save();
return id;
}
Creating a customer record it's getting created, but can't see First and last name.