Open aschi opened 4 years ago
@aschi thank you for your submission. I am afraid that you are trying to use 11/11/200727
as the voucher number (element /10/
) but that you forgot to escape the /
, which can't appear as such in the value of an element. If you want to do this right, you should use this string instead:
//S1/10/11\/11\/200727
or else the string will be interpreted as :
/10/
with value 11
/11/
with value 200727
Thank you for your reply. This is correct. The way we would like it to be interpreted is:
/10/
with value 11
/11/
with value 200727
(which is 2020-07-27 in the yyMMdd format)As far as I have seen in the validator source code, it searches for /10/
, /11/
, ... in the input string and checks if the following value is valid for the given type:
In our example: //S1/10/11/11/200727
/10/
with value 11
(OK)/11/
with value 11
(the voucher number 11
was interpreted as "key" and it is not followed by a valid date -> NOK)/11/
with value 200727
(would be OK but the 2nd check already threw an exception)Sorry, I misunderstood what you were trying to do. You are right. There seems to be an issue in the validator!
A customer of ours was testing a few qr bills with your validator. At the 11th bill they encountered an error that worried them (I recreated the issue with meaningless "test data"):
According to the six specification (https://www.paymentstandards.ch/dam/downloads/ig-qr-bill-en.pdf page 52) "free text" is allowed as voucher number (e.g. "11" should be valid). Will this lead to any further inconveniences or is this just a minor issue with your validator?