# HR-BR-4

Source: https://xmlvalid.com/rules/HR-BR-4

> U slučaju pozitivnog iznosa koji dospijeva na plaćanje (BT-115), datum dospijeća plaćanja (BT-9) mora biti naveden

- Level: error
- Rule sets: Croatian eRačun rules (UBL) 13.03.2026
- Context: `ubl-creditnote:CreditNote | ubl-invoice:Invoice`
- Test: `($payableAmount > 0) and (exists(cbc:DueDate) or exists(cac:PaymentMeans/cbc:PaymentDueDate)) or (($payableAmount <= 0))`

In English: When the amount due for payment (BT-115) is positive, the payment due date (BT-9) must be given.

## Why it fails

- The amount due (`cbc:PayableAmount`) is positive, and neither `cbc:DueDate` nor `cac:PaymentMeans/cbc:PaymentDueDate` is given.

## How to fix it

- Add `cbc:DueDate` after `cbc:IssueDate` (or `cbc:PaymentDueDate` in `cac:PaymentMeans`).

Validate a document against these rules: https://xmlvalid.com/validate
