User bio
404 bio not found
Member since Jul 30, 2022
Replies:

Just a quick stab but I believe it's because you're extending %Persistent first and not Ens.Response and not specifying inheritance from the right so it's not appropriately applying the message viewer projection.

You normally wouldn't need to extend %persistent if these are going to be transient objects that you want to purge out via normal Ensemble purge (be sure to add in the appropriate logic to cascade delete child objects that are not %serial. Lots of posts on this "cascade delete"

Hey Scott - While the order itself isn't important as long as your %JSONFIELDNAME values are proper, my guess is that the current error you are hitting is one of the sub-class definitions we can't see here is missing this as well:

Parameter %JSONIGNOREINVALIDFIELD As BOOLEAN = 1;

For instance, I bet LastName is a field coming back in the object represented by this property

Property AttendingPhysicians As list Of User.REST.Epic.dt.ArrayOfAttendingPhysician(%JSONFIELDNAME = "AttendingPhysicians");

So you would have to add that class param to that class as well (or wherever appropriate downstream) unless you intend to handle the LastName field appropriately.

Hey Scott; I haven't read through all of this but use

Set tSC = pResponse.%JSONImport(tHTTPResponse.Data)
Quit:$$$ISERR(tSC) tSC

So you can capture perhaps why the import is failing.

Generally speaking as well, for items like:

Property AppointmentSchedules As User.REST.Epic.dt.ArrayOfScheduleProviderReturn(%JSONFIELDNAME = "AppointmentSchedules");

Which I believe is referencing a JSON Array of objects, you would need to do the following at bare minimum;

Property AppointmentSchedules As list Of User.REST.Epic.dt.ArrayOfScheduleProviderReturn(%JSONFIELDNAME = "AppointmentSchedules");
 

Believe you have several of these situations.

Open Exchange applications:
Certifications & Credly badges:
Global Masters badges:
Followers:
Following: