cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Ruud
Level: Powered On

Collection structure not updated with nested collection

I am trying to create an app based on a rest API. Got most things working an I understand, thanks to @v-xida-msft , what I can and can't do with the REST Api.

 

So I am using collections to store some data, but one of the collection won't show the nested objects. I updated the connector and the response part, it shows the nested fields and also the test of the custom connector is showing the correct results.

 

But in the app I don't get nested data in the collection, and I can't find the reason why.

 

The json data:

 

{
    "id": "mfnVHOTn",
    "company_id": "2fuihMjF",
    "firstname": "John",
    "lastname": "Doe",
    "street": "Street 22",
    "housenumber": null,
    "postalcode": "1111AP",
    "city": "Amsterdam",
    "birthdate": "1980-01-1 00:00:00",
    "nationality_id": 92,
    "picture": "",
    "ic_type": "ID-bewijs",
    "ic_country": 92,
    "bsn_number": "123456789",
    "ic_number": "AAAA322222",
    "ic_date": "2025-01-1 00:00:00",
    "ic_copy": "",
    "ic_copy_back": "",
    "non_eu_citizen": 0,
    "residence_permit": null,
    "work_permit": null,
    "permit_number": null,
    "permit_date": null,
    "permit_copy_front": "",
    "permit_copy_back": "",
    "vca_certified": 1,
    "vca_date": "2020-01-01 00:00:00",
    "gpi_certified": 0,
    "gpi_date": null,
    "signature": "employee_Images/mfnVHOTn.signature.074744.png",
    "created_by": {
        "id": "lficbkrg",
        "firstname": "Jane",
        "lastname": "Doe",
        "email": "janedoe@contoso.com",
        "company_id": "FA5P4xYo",
        "name": null,
        "updated_at": "2019-08-30 05:06:33",
        "created_at": null,
        "profile_img": "/user/1567141593.jpeg"
    },
    "created_date": "2019-08-23 07:44:17",
    "changed_by": "lficbkrg",
    "changed_date": "2019-08-23 07:44:27",
    "deleted_at": null,
    "company": {
        "id": "2fuihMjF",
        "app_heading": "",
        "name": "Janse",
        "created_by": "inedpmyu",
        "created_at": "2019-02-04 00:00:00",
        "updated_at": "2019-02-04 09:10:52",
        "owner": null
    },
    "nationality": {
        "id": 92,
        "description": "Nederlands"
    }
}

 

In the response you can see for example the Created_by Lastname object

Connector Response.JPG

 

This is the onVisible update function for the collection:

If(Connection.Connected;
      ClearCollect(localEmployee; ThappAPI.GetEmployee({id:ProjectEmployeeGallery.Selected.id}));
      UpdateContext({statusText: "Online data"})
      ;
      LoadData(localEmployee; "localEmployee"; true);
      UpdateContext({statusText: "Local data"})
  );;
  SaveData(localEmployee; "localEmployee");;

Collection result:

 

Collection result.JPG

 

1 REPLY 1
TopShelf-MSFT
Level 10

Re: Collection structure not updated with nested collection

Bumping for visibility 

 

@TopShelf-MSFT 

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors (Last 30 Days)
Users online (4,834)