enonic / app-guillotine

Apache License 2.0
2 stars 3 forks source link

query on boolean values like hasChildren = false does not work #63

Closed ComLock closed 4 years ago

ComLock commented 6 years ago

@runarmyklebust This might be an issue with our query language, is it possible to query boolean values?

No examples here: https://xp.readthedocs.io/en/stable/reference/query-language.html

{
  guillotine {
    queryConnection(
      contentTypes: "appname:contentType"
      query: "hasChildren = false"
    ) {
      totalCount
      edges {
        node {
          #createdTime
          #modifiedTime
          #type
          displayName
          hasChildren
          language
          #valid
          #dataAsJson
          #pageUrl
        }
      }
      pageInfo {
        startCursor
        endCursor
        hasNext
      }
    }
  }
}

Result

{
  "data": {
    "guillotine": {}
  },
  "errors": [
    {
      "errorType": "DataFetchingException",
      "message": "Exception while fetching data: com.enonic.xp.resource.ResourceProblemException: line 1, column 89:\n( expected, ) encountered.",
      "exception": {
        "name": "com.enonic.xp.resource.ResourceProblemException",
        "message": "line 1, column 89:\n( expected, ) encountered."
      }
    }
  ]
}
GlennRicaud commented 4 years ago

I do not think this is indexed.