Quantcast
Channel: SmartClient Forums
Viewing all articles
Browse latest Browse all 4756

AdvancedCriteria, RelativeDate, "N hours ago"

$
0
0
Hello,

We are having a problem when specifying filters at the hour and minute level for type="datetime" fields.

I have attached a screenshot of the filter builder where we specify the following criteria.

"Created" "greater than or equal to" "N hours ago" "47" -> (2014-06-22 16:38:00 -0400)

The following is the AdvancedCriteria.

Code:

{
    "_constructor":"AdvancedCriteria",
    "operator":"and",
    "criteria":[
        {
            "fieldName":"createdOn",
            "operator":"greaterOrEqual",
            "value":{
                "_constructor":"RelativeDate",
                "value":"-47mn[-0S]"
            }
        }
    ]
}

The following is the DSRequest criteria.

Code:

data:{
        operator:"and",
        criteria:[
            {
                fieldName:"createdOn",
                operator:"greaterOrEqual",
                value:"2014-06-24T04:00:00.000"
            }
        ]
    }

We were expecting the criteria to be exactly 47 hours ago, instead the criteria is sent as "2014-06-24T04:00:00.000".

SmartClient Version: v9.1p_2014-06-17/Pro Deployment (built 2014-06-17)

FF ESR 24.6.0

Thanks

Attached Images
File Type: png screenshot_23.png (15.7 KB)

Viewing all articles
Browse latest Browse all 4756

Trending Articles