Using Odata and JavaScript in Microsoft Dyanmics 365 Portals.

Hello Guys,

In my previous blog we have explored child sub-grid configuration and have created child entity form. Today we will see how you can use Odata and JavaScript in your portal. But before if you are new to our blog then do follow us to know more about Dynamics and Power Platform. Also if you like our blog then please comment and share this blog with your friends.



We will be working on same child entity form. First of all we will be creating one child activity using portal. Navigate to portal and open an Event and click on Add Activity.



As you can see here we have Parent Event named "Introduction to Asp.Net". You will notice that we have to select the Associated Event in which this activity will be created. Basically this should be auto populated so that we don't have to select it from the lookup. We will achieve this using Odata and JavaScript. Open Portal Management and select Entity List.

Open My Talk List Entity List and select Odata Feed Tab.Configure it as below.



We will use this odata in our JS. Now open My Talk Activity Insert Entity Form. Select Additional Settings Tab and scroll down till you get Custom JavaScript Section.



Copy below code and paste it to the JavaScript section.



Save the changes and refresh the Add Activity Form on portal. you will see Parent Event will be associated automatically.



Hope it helps...

Comments

Popular posts from this blog

Read Only Sub Grid & Editable Sub grid in Dynamics 365

Understanding Sales Process in D365.

Understanding Business Unit in Dynamics 365.