Using Filter Expressions

0

I use the WebService Query to call an API script as datasource.
The datasource is a JSON.
To be able to filter on TransportProperties: CTRTYPE  I use $F{PropertyCode}.equalsIgnoreCase("CTRTYPE") as Filter Expression
I get "20 DV" as result.

{
    "Reference": "T03641955",
    "PublicId": "ZIMU-135721-8",
    "TransportProperties": [
        {
            "PropertyCode": "CUSTDOC",
            "PropertyDescription": "Customs Doc",
            "Value": null,
            "DisplayValue": null,
            "Id": 5197
        },
        {
            "PropertyCode": "DG",
            "PropertyDescription": "Dangerous Goods",
            "Value": null,
            "DisplayValue": null,
            "Id": 5198
        },
        {
            "PropertyCode": "CTRTYPE",
            "PropertyDescription": "Container Type",
            "Value": "20 DV",
            "DisplayValue": "20 DV",
            "Id": 5202
        }
    ],
    "Id": 1065
}

This is working great, but when I want to do something similar for ExtraQuantities, I don't get the desired result
$F{Good.ExtraQuantities.UnitId}.equalsIgnoreCase("2")

[
    {
        "OrderItemId": 275,
        "Good": {
            "StockInfoConfig": {
                "ProductId": 408,
                "OwnerId": 5,
                "LocationId": 2875,
            "ExtraQuantities": [
                {
                    "Quantity": 1000.00,
                    "UnitId": 2,
                    "MeasurementUnitId": 1,
                    "Id": 61308
                },
                {
                    "Quantity": 1092.00,
                    "UnitId": 3,
                    "MeasurementUnitId": 1,
                    "Id": 61309
                }
            ],
            "Id": 15327
        },
        "Id": 15327
    }
]

adrian_32's picture
Joined: Sep 2 2019 - 1:40am
Last seen: 1 day 19 hours ago

1 Answer:

0
swood_1's picture
420
Joined: Nov 15 2012 - 10:47am
Last seen: 11 hours 15 min ago
Feedback
randomness