learninglocker icon indicating copy to clipboard operation
learninglocker copied to clipboard

Aggregate calls forcing [] bracket wrapping on the response. This unfortunately interferes with some 3rd party charting libraries.

Open robertgardunia opened this issue 1 year ago • 0 comments

My aggregate call is returning an array:

[ { "data" : [ { "name": "Statements", "data": [ 4 ] } ], "category": [ "Abandoned" ] } ]

Instead of an object: { "data" : [ { "name": "Statements", "data": [ 4 ] } ], "category": [ "Abandoned" ] }

I can test with the absolutely simplest aggregate call and I still get the brackets. This seems to be 'built in' to the aggregate API in Learning Locker. Is there way to flag this so that it returns an object when we know it's a single item and not an array? We are doing a call from a 3rd party charting plug-in so there's no easy way to manipulate the response before it gets consumed.

robertgardunia avatar Mar 05 '24 06:03 robertgardunia