XV-PL-22
A simplified invoice (UPR) may be issued up to PLN 450 or EUR 100 due; P_15 is … … (VAT Act, art. 106e ust. 5 pkt 3).
error: the document is invalid
What the rule checks
As the rule set's publisher wrote it. The rule runs on every element the context matches, and fails where the test is false; the validator reports the line of that element
Context
/fa:Faktura/fa:Fa
Test
$kind != 'UPR' or not(normalize-space(fa:KodWaluty) = ('PLN', 'EUR')) or pl:dec(fa:P_15) le (if ($pln) then 450 else 100)
Checked with KSeF FA(3)