This topic contains 2 replies, has 0 voices, and was last updated by dansteg 8 years, 8 months ago.

  • Author
    Posts
  • #2897

    SererraMike

    I want to add the ability of CSRs to choose the customer address on a case form. I can add a custom field with the “address book” list. I can’t seem to figure out how to filter that list to the selected customer though. I have no options to choose from in the “filter using” section. Any suggestions?
    This is a cached copy. Click here to see the original post.

  • #2898

    errol

    You can’t (natively). What I have had to do is create the Address Book list field as you have. Then I also have a combination of beforeLoad, beforeSubmit and client-side fieldChanged scripts that do the sourcing and making it work.

    beforeLoad hides the address field you built in the UI and adds 2 new fields: the custom sourced address select field and a text area that shows the full address when the user selects it

    beforeSubmit (create/edit only), I stamp the original un-sourced address field to be whatever the scripted sourced field value is.

    client-side: this is where I have the actual sourcing and replacing of the sourced address list as well as setting the text area field so the user can see the full address.

    So, to recap.. natively, you can’t. However, it is possible and the outcome works very well and you can’t even tell it wasn’t native. It would be nice if NetSuite added the ability to source/filter the addressbook list like all other list/records.


    dansteg replied on 03/07/2016, 02:43 PM: Thanks a lot errol. I’m going to go ahead and attempt to implement your method. It’s weird that a Ship to isn’t available for Vendor Returns…and even more weird that this type of Address Book Sourcing isn’t available when creating a custom field.

    The only question I have is how are you limiting the results in the Select Field to those of the Address Book + Selected Entity?

    Hopefully it’s something that they’ll roll out soon, but for now, it sounds like your method should work! THANKS!

  • #2899

    dansteg

    For example, I cannot figure out how to get any values to populate with addresses, let alone have them filtered by the selected vendor/entity.

    Code:
    var shipToSelect = form.addField(‘custpage_shiptoselect’, ‘select’, ‘Ship To’, ‘addressbook’);

You must be logged in to reply to this topic.