VRBL-INV-DK-OIOUBL-2p0-52
Basic Info
|
Rule
|
If all Invoicing Period Start Date, Invoice Period Start Time, Invoicing Period End Date and Invoice Period End Time are given, then the combination of Invoicing Period End Date and Invoice Period End Time must be later or equal to the Invoicing Period Start Date and Invoice Period Start Time. |
|
Context
|
/ubl:Invoice/cac:InvoicePeriod
|
|
Pattern
|
vrbl-invoice-dk-oioubl-2p0 |
|
Severity
|
fatal |
Used Template: EndDateTimeEqualOrLaterStartDateTime
| Parameter |
|
Value |
| StartDate |
= |
cbc:StartDate
|
| StartTime |
= |
cbc:StartTime
|
| EndDate |
= |
cbc:EndDate
|
| EndTime |
= |
cbc:EndTime
|
Implementation
not(boolean(cbc:StartDate))
or
not(boolean(cbc:StartTime))
or
not(boolean(cbc:EndDate))
or
not(boolean(cbc:EndTime))
or
number(
concat(
substring(cbc:EndDate, 1, 4),
substring(cbc:EndDate, 6, 2),
substring(cbc:EndDate, 9, 2),
substring(cbc:EndTime, 1, 2),
substring(cbc:EndTime, 4, 2),
substring(cbc:EndTime, 7, 2)
)
)
>=
number(
concat(
substring(cbc:StartDate, 1, 4),
substring(cbc:StartDate, 6, 2),
substring(cbc:StartDate, 9, 2),
substring(cbc:StartTime, 1, 2),
substring(cbc:StartTime, 4, 2),
substring(cbc:StartTime, 7, 2)
)
)