Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Prefilling from MS Dynamics for AEM Adaptive

Avatar

Avatar
Establish
Level 2
manu-gupta
Level 2

Likes

4 likes

Total Posts

33 posts

Correct Reply

1 solution
Top badges earned
Establish
View profile

Avatar
Establish
Level 2
manu-gupta
Level 2

Likes

4 likes

Total Posts

33 posts

Correct Reply

1 solution
Top badges earned
Establish
View profile
manu-gupta
Level 2

31-08-2020

Hi Techies,

I am working on getting Data from MS Dynamics, it is interacting with lead entity and I am able to get request and response using GET/POST/PUT operations using rule editor when any panel or field is initialized or changed.

Now I need to prefill the form using http://localhost:4502/editor.html/content/forms/af/we-finance/cc-app.html?new_applicationid=1234

I tried adding below code in /libs/fd/af/components/page2/aftemplatedpage/aftemplatedpage.jsp but unable to get values in form. I dont know what to do next for form to make request to FDM model for get method based on new_applicationid

if(request.getParameter("new_applicationid")!=null)
    {
      System.out.println("Adobe !!!There is a applicationid parameter in the request "+request.getParameter("applicationid"));
      java.util.Map paraMap = new java.util.HashMap();
      paraMap.put("new_applicationid",request.getParameter("new_applicationid"));
      slingRequest.setAttribute("paramMap",paraMap);
    }

 Am I missing anything?

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Springboard
Level 10
Mayank_Gandhi
Level 10

Likes

327 likes

Total Posts

1,150 posts

Correct Reply

185 solutions
Top badges earned
Springboard
Establish
Validate 1
Contributor 2
Ignite 5
View profile

Avatar
Springboard
Level 10
Mayank_Gandhi
Level 10

Likes

327 likes

Total Posts

1,150 posts

Correct Reply

185 solutions
Top badges earned
Springboard
Establish
Validate 1
Contributor 2
Ignite 5
View profile
Mayank_Gandhi
Level 10

01-09-2020

@manu-gupta Why don't you read the URL context in the form using Rule editor itself and make a call to FDM after that.

 

Ref :https://www.w3schools.com/js/tryit.asp?filename=tryjs_loc_host

Answers (0)