getRelatedSets() Returns One Result for Multiple Portals
When calling getRelatedSets() for a layout through the FileMaker PHP API, a single result is returned if there are multiple portals based upon the same table on the given layout. This is true even if the portal objects are given different names in Inspector.
This prevents getting different arrays for portals with different filtered results from the same related table.
Create a table of Parents and a table of related Children.
Create a layout based on Parents
Add a portal of Children named "Sons" with a filter of "boys"
Add a second portal of Children named "Daughters" with a filter of "girls"
Use the following PHP code to return the list of portals:
$relatedSetsNames = $result->getRelatedSets();
Here are the portals:";
Two related sets, "Sons" and "Daughters" should be available.
Only the "Sons" portal is available as table "Children"
We could create separate layouts with each portal and build the arrays for display.
We could also create multiple table occurrences for every filtered portal.
But shouldn't the portal object names be available for calling with getRelatedSet()?