Format attribute for the referenced document's issue date

Error FX-SCH-A-000637 Factur-X

Attribute '@format' is required in this context.

Mandatory rule: As long as it is violated, the invoice is invalid and will be rejected by validators.
What is wrong

For a referenced document with ram:TypeCode 130, the format attribute is missing from qdt:DateTimeString in the issue date.

What the rule means

The required format attribute indicates how to interpret the issue date of the referenced document.

Please add the format for the referenced document's issue date

The issue date is missing the format attribute for the referenced document with ram:TypeCode 130. Add the format attribute so the date value can be interpreted.

What to do
  1. Find the affected ram:AdditionalReferencedDocument with ram:TypeCode 130.
  2. Add format to qdt:DateTimeString under ram:FormattedIssueDateTime.
  3. Generate the invoice again and validate it.
What it looks like
✗ Triggers the message
<ram:AdditionalReferencedDocument>
  <ram:TypeCode>130</ram:TypeCode>
  <ram:FormattedIssueDateTime>
    <qdt:DateTimeString>20240115</qdt:DateTimeString>
  </ram:FormattedIssueDateTime>
</ram:AdditionalReferencedDocument>
✓ Correct
<ram:AdditionalReferencedDocument>
  <ram:TypeCode>130</ram:TypeCode>
  <ram:FormattedIssueDateTime>
    <qdt:DateTimeString format="102">20240115</qdt:DateTimeString>
  </ram:FormattedIssueDateTime>
</ram:AdditionalReferencedDocument>
Technical details

In the context of a ram:AdditionalReferencedDocument with ram:TypeCode 130, the existence of the format attribute on qdt:DateTimeString is checked.

Where the rule applies

The rule applies to qdt:DateTimeString under ram:FormattedIssueDateTime of a ram:AdditionalReferencedDocument with ram:TypeCode 130.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeAgreement/ ram:AdditionalReferencedDocument[ram:TypeCode="130"]/ram:FormattedIssueDateTime/ qdt:DateTimeString
Test expression (assert/@test)
@format