Params for rest entity query (java.util.Date)

Hi.

I have a problem with prepare java.util.Date param for rest entity query.

My query config:

    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <queries xmlns="http://schemas.haulmont.com/cuba/rest-queries.xsd">
        <query entity="logistic$Contractor"
               name="createTs"
               view="contractor-browse">
            <jpql>
                <![CDATA[select e from logistic$Contractor e where e.createTs > :createTs]]>
            </jpql>
            <params>
                <param name="createTs"
                       type="java.lang.Date"/>
            </params>
        </query>
    </queries>

For this http request : /logistic/rest/v2/queries/logistic$Contractor/createTs?createTs=2017-01-01 ,

I received error: {"error":"Error on executing the query","details":"java.lang.Date"}

I tried with a different date format, like: 2017-01-01 00:00:00.000 but it did not help.

Regards

Marcin

Probably the problem is that you wrote java.lang.Date instead of java.util.Date in your query config

Thank you. For java.util.Date it’s works.

In “Rest query designer” parameter type selector has java.lang.Date not java.util.Date.

Regards
Marcin

Screenshot_20180118_074849

That’s a bug. Thank you for pointing out. The issue: https://youtrack.cuba-platform.com/issue/STUDIO-4288