0

I have run into a little roadblock in regards to joining mantle entities. I would like to have a single depicting fields from two mantle entities, but am unsuccessful in joining them. Specifically, I have linked a list of party relationships (as contacts) to a single partyId (vendor), with the goal to make a vendor contacts page. However I am unable to link that form-list with the PartyContactMech and ContactMech entities (in order to display email and phone number in the same form-list). More generally, my question is how can one map lists to each other the same way one can map a list to a single object (using entity-find-one and value-field does not work when tried with entity-find)?

David Browne - Microsoft
  • 80,331
  • 6
  • 39
  • 67

1 Answers1

1

There is no need to make a view-entity (join entities) to do that. Simply do a query on the PartyRelationship entity in the main 'actions' part of your screen specifying the toParty (vendor). Then in your Form-List, use 'row-actions' to query the PartyContactMech and so on for each fromPartyId (contact) entry that the previous query returned. Also have a look at the PartyViewEntities file in Mantle USL. There are some helpful view-enties already defined for you there such as PartyToAndRelationship, PartyFromAndRelationship etc. Also note that entity-find-one returns a single "map" (value-field) as it queries on the PK. Whereas entity-find returns a list of maps (list). They are separate query types. If I understand your question correctly.

Ronan Keane
  • 189
  • 8
  • Thank you, you understood my question perfectly. I had already tried your approach, and i see the logic in it, therefore i must be making a syntax error of some sort. Here are my row actions: However I am unable to display – Alex Bradau Jun 26 '17 at 14:33
  • @AlexBradau it would be great if you share your solution so that other can benefit too. Thanks! – Michael Brohl Jan 06 '18 at 18:56