Forums

Forums / Developing Portals / MVC Rules Manager - Javascript

MVC Rules Manager - Javascript

Thread is closed for posting
2 posts, 1 answered
  1. David Woof
    David  Woof avatar
    4 posts
    Registered:
    11 Sep 2018
    20 Sep 2018
    Link to this post
    I would like to populate a field with the value from a selected lookup record.
    In javascript how would I extract a field from the lookup record and populate another field on the form?
    I have seen api examples but none does anything like this.  Is it possible to call CRM restful API from within the rules manager?
    Does anyone have any examples?
  2. Sonam Joshi
    Sonam Joshi avatar
    29 posts
    Registered:
    20 Mar 2017
    Answered
    15 Nov 2018
    Link to this post
    Hi David,

    For this requirement you can refer to the following TPC Lookup API dcoumentation, You can use the get_value() and set_value() methods.

    https://www.crmportalconnector.com/developer-network/documentation/portal-connector-widgets/tpc-client-side-api/mvc-based/lookup

    And, for security reasons we do not provide access to the CRM restful API, thus the best approach would be through custom logic using TPC lookup API.

    Thanks,
    Sonam Joshi
2 posts, 1 answered