VRBL-DPA-RS-1p0-16

Basic Info

Rule When the Dispatch Line Item Additional Item Property Name indicates an excisable good (listed in the code list [VRBL-CL-RS-ExcisableGoods]), the Dispatch Line Item Additional Item Property Value, the Dispatch Line Item Additional Item Property Value Quantity or the Dispatch Line Item Additional Item Property Sub Item Property Group must be provided.
Context /ubl:DespatchAdvice/cac:DespatchLine/cac:Item/cac:AdditionalItemProperty
Pattern vrbl-despatchadvice-rs-1p0
Severity fatal

Implementation

not(cbc:Name)
or
not(
	contains($VRBL-CL-RS-ExcisableGoods, concat(' ', substring-after(normalize-space(cbc:Name), $VRBL-RS-Prefix), ' '))
)
or
(
	boolean(cbc:Value)
	or
	boolean(cbc:ValueQuantity)
	or
	boolean(cac:SubItemProperty)
)