Skip to main content

Notifications

Announcements

No record found.

Customer experience | Sales, Customer Insights,...
Suggested answer

Portal help: Using Entity Reference in the Entity Form

(0) ShareShare
ReportReport
Posted on by 38

I'm a bit lost when trying to set up an entity reference on creating an account. I hope somebody can help!

I have a N:N relationship between account and contact, for example a "CEO" relationship.
Now I want the CEO user to add an account, that will be related to him with this N:N relationship.

So I go to the Entity Form tab "Entity reference" and select:
- Logical name -> Contact
- Relationship -> CEO (new_contact_account_CEO)
- Reference Entity Source Type -> At here I only can select "Query string" and "Record linked to current portal user" (translated). So I'm missing "Current portal user" itself. Or did I miss an important previous step?
By the way: the option "Record linked to current portal user" is also not in the MS documentation.

Thanks!
Elowy.

  • Suggested answer
    Elowy GrootCRM Profile Picture
    Elowy GrootCRM 38 on at
    RE: Portal help: Using Entity Reference in the Entity Form

    Just had a third call with Microsoft. They really try to help with this problem. However, the "Current user" option isn't available (anymore) in the portal. They will change the help documentation.

    A suggested workaround is to add a contact lookup field (or use portal contact owner) and add the current user in that field (that is possible in Additional Settings tab of the entity form). And from there create an entity permission for this relationship so the newly created record is shown right away to the user. That works fine!

    However, be aware that the specific user will remain rights to show the record as long as his name is in the contact lookup field.

  • Elowy GrootCRM Profile Picture
    Elowy GrootCRM 38 on at
    RE: Portal help: Using Entity Reference in the Entity Form

    Thanks Nicolas for your suggestion.

    Unfortunately with a flow I don't find the added record right away in the N:N list after adding the record. That is because the N:N relation is defined in async in the flow, so after the page (and cache) are refreshed.

    I've send this question to Microsoft, maybe they have a solution. The "Current user" option is described in there help pages, so it should be there...

    Thanks again!

    Elowy.

  • Suggested answer
    Nicholas Hayduk Profile Picture
    Nicholas Hayduk 2,863 on at
    RE: Portal help: Using Entity Reference in the Entity Form

    You're right, there doesn't seem to be a way to select the current contact using Entity Reference.  Typically that would be done using the Associate Current Portal User on Insert area on the Form Definition tab, but that doesn't work on N:N.

    You might need to create a "CEO" lookup field on the account, and then use a flow to setup the N:N relationship each time that field is updated.

    Nick

  • Vu dinh thang Profile Picture
    Vu dinh thang 25 on at
    RE: Portal help: Using Entity Reference in the Entity Form

    waiting for the answer

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey Pt 2

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,791 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,488 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans