Overview: Barcode should be quoted and masked when building the CQL query. Steps to Reproduce:
Open Checkout app
Select an active user
Enter one of these barcodes into the barcode slot:
Press enter or click the enter button
Expected Result: Back-end call with properly quoted and masked CQL query:
query urldecoded:
Actual Result:
Query urldecoded:
The first two queries cause an error popup saying: "org.folio.cql2pgjson.exception.QueryValidationException: org.z3950.zing.cql.CQLParseException: expected boolean, got '/'" or "... got '('" The third query incorrectly searches for abc\def because the first backslash masks the second one.
Overview:
Barcode should be quoted and masked when building the CQL query.
Steps to Reproduce:
Open Checkout app
Select an active user
Enter one of these barcodes into the barcode slot:
Press enter or click the enter button
Expected Result:
Back-end call with properly quoted and masked CQL query:
query urldecoded:
Actual Result:
Query urldecoded:
The first two queries cause an error popup saying: "
org.folio.cql2pgjson.exception.QueryValidationException: org.z3950.zing.cql.CQLParseException: expected boolean, got '/'
" or "...got '('
"The third query incorrectly searches for abc\def because the first backslash masks the second one.
Additional Information:
mask \ and " using https://github.com/folio-org/stripes-util/blob/v3.0.0/lib/escapeCqlValue.js
put string into double quotes:
barcode=="abc(2)"