Tip 9: Show Contact Lists in Sales Order to fetch contact emails and name to send email to Contact with cc other contacts in Netsuite

Have you ever got any requirement similar to below and if yes, here is a simple way to achieve it.

Requirement: On creation of a new Sales Order record, Sales Rep wants to have feature, which will allow them to choose a contact from all contact lists(of that particular Customer) to whom email will be sent addressing the Contact Name with some other Contacts as CC instead of sending email to Customer(as a Company) with addressing Company Name.

Current Feature: Currently they are sending to customer(as a company) company email addressing Company name. And there is no option to select other contacts for choosing as CC.

How to achieve it???

Step 1: Create a custom field called Primary Contact which is a List/Record of Type “Contact”. In the field record set the Sourcing as “Parent equals Customer” so that  the Primary Contact List will contain only the contacts belongs to that customer only.

primary contact

Step 2: Create a custom field “Primary Contact Email” of type “Email Address” which will hold the contact email when Primary contact field will be selected with a contact.

Step 3: Create a custom field “Primary Contact Name” of type “Free-from-text” which will hold the contact name when Primary contact field will be selected with a contact.

Step 4: Create a “Multiselect” custom field of type “Contact“called “Secondary Contact List” where user can select multiple Contacts. In the field record set the Sourcing as “Parent equals Customer” so that the Primary Contact List will contain only the contacts belongs to that customer only.

Step 5: Create a “Text Area” custom field called “Secondary Contact Emails” which will hold the email address lists respective to selection of contact for CC list.

contact lists

Step 6: Create a client script for Sales Order and in the field change event, write code for Primary Contact and Secondary Contact List field change, get respective emails and Contact Name(for Primary Contact). Deploy the script and test for any Sales Order, if on selection of Primary Contact and Secondary contact, respective emails and contact name is populated or not.

contact info

Now use the emails and contact name while sending emails.

Hope this small tip will help you 🙂

Thanks,

Asha

Advertisements

2 thoughts on “Tip 9: Show Contact Lists in Sales Order to fetch contact emails and name to send email to Contact with cc other contacts in Netsuite

  1. Simon

    Hey,

    This is exactly what I am looking for!!
    But when I try to complete step 1,
    I get an error message pop-up saying; “Please specify a field to source”

    1. Hello Simon,

      I guess, you will have to click Cancel button after selecting 1st row in Sourcing. Sometimes, even though you haven’t selected anything, it takes it as you have selected next line to enter something. So just click cancel and try to save and let me know, if you still have same issue.

      Regards,
      Asha

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s