Graphql: Fix geometry type in arguments (#15050)

* Handle matrixes as args
This was the less intrusive way I figure out.
We may need to refactor this parseArgs properly in order to handle this types

* App/Graphql: Send filter query as proper JSON instead of escaped string

* Make panel variables readonly when no-editing
Prevents Geometry type mismatch error

* Fix proper way to parse args
This commit is contained in:
José Varela
2022-08-15 14:58:43 +01:00
committed by GitHub
parent 1514b0c204
commit 5087fcd1e4
3 changed files with 34 additions and 38 deletions

View File

@@ -59,5 +59,14 @@ export function formatQuery({ collection, query }: QueryInfo): Record<string, an
// TBD @TODO
}
if (query.filter) {
try {
const json = String(query.filter);
formattedQuery.__args.filter = JSON.parse(json);
} catch {
// Keep current value there
}
}
return formattedQuery;
}