The ApiTranslator.js needs to be adapted, so that the query which is translated from the ui query to the StructuredQuery accepted by the ui backend adheres to the json schema definition of the StructuredQuery here:
The ApiTranslator.js was for example still sending an empty "exclusionCriteria" Array, when no exclusionCriteria were chosen in the ui, which is not allowed according to the specification of the StructuredQuery schema.
Task:
Ensure that exlusion crtieria are only set in the result query object in the "translateToV1" function if they are non empty.
-- one simple way is to check for the length of the exclusion criteria and set them to undefined:
The ApiTranslator.js needs to be adapted, so that the query which is translated from the ui query to the StructuredQuery accepted by the ui backend adheres to the json schema definition of the StructuredQuery here:
https://github.com/num-codex/codex-structured-query/blob/main/structured-query/json-schema/2021_01_29_StructuredQuerySchema(Draft).json
The ApiTranslator.js was for example still sending an empty "exclusionCriteria" Array, when no exclusionCriteria were chosen in the ui, which is not allowed according to the specification of the StructuredQuery schema.
Task: