Hello
I see a design issue using JsonDataSource and possible nested objects/arrays and providing data in runtime.
Setting up a "root" JsonDataSource is no problem. Also the way setting the json trough parameters.
The issue begins when I want to use a nested array AND the root object.
Example Json{
"InvoiceDate" : "2024-01-01",
"InvoiceNo":"IN2024-001",
"Positions" : [
{
"Product":"Product 1",
"Price" : 5.25
},
{
"Product":"Product 2",
"Price" : 10.5
}
]
}
The approach using JsonPath for accessing the "Positions" is ok but I have to set up another JsonDataSource with the same json and so that I can access the nested array.
And now I don't now how to set the Source of the second JsonDataSource in runtime. Setting it using parameters is only possible with one DataSource.
A nice approach would be binding the Source of the second JsonDataSource to the first JsonDataSource with a JsonPath. So we could avoid duplication of data.
Or let us bind to a nested object in a table.