Question:
There is a JSON file with the following structure:
{
"person" {
"someElement" : "test",
"operationsList": [
{
"date": 1505980686916,
"sendersLastName": "last",
"sendersFirstName": "first",
"sendersSecondName": "second",
"operationDetailsList" : [
{
"innerKey" : "key1",
"innerValue" : "value1"
},
{
"innerKey" : "key2",
"innerValue" : "value2"
}
],
"operationCurrencyAmount": 456,
"operationCurrencyCode": "TEST"
},
{
"date": 1505980686916,
"sendersLastName": "last",
"sendersFirstName": "first",
"sendersSecondName": "second",
"operationDetailsList" : [
{
"innerKey" : "key1",
"innerValue" : "value1"
},
{
"innerKey" : "key2",
"innerValue" : "value2"
}
],
"operationCurrencyAmount": 456,
"operationCurrencyCode": "TEST"
},
],
"otherField" : "testValue"
},
"booleanFlag" : true
}
Created jr: list with elements of "operationsList": subDataSource ("person.operationsList") .
Inside this (operationsList) sheet there is another jr: list (operationDetailsList): subDataSource ("operationDetailsList")
Question: You need to use the root element "booleanFlag" as the printWhenExpression for one of the fields (for example, "innerKey") inside the child (operationDetailsList) sheet. However, the list of available fields only contains fields from subDataset = "operationDetailsList", i.e. only "innerKey" and "innerValue" are available. Is it possible to access the "booleanFlag" element from sheet in sheet?
Answer:
There is a solution, you can pass this field as a parameter to the sheet and use the parameter in the sheet, and not the field itself.