Skip to content

FIX require previous record for cancellations - #39

Open
braito4 wants to merge 1 commit into
garacil:mainfrom
braito4:fix/cancellation-chain-required
Open

FIX require previous record for cancellations#39
braito4 wants to merge 1 commit into
garacil:mainfrom
braito4:fix/cancellation-chain-required

Conversation

@braito4

@braito4 braito4 commented Jul 27, 2026

Copy link
Copy Markdown

Summary

VeriFactu cancellation records must remain linked to the existing billing-record chain. The cancellation model previously allowed PrimerRegistro=S.

This change:

  • requires Encadenamiento/RegistroAnterior during cancellation validation
  • rejects attempts to mark a cancellation as the first chain record
  • keeps normal chained cancellation behavior unchanged

Validation

Focused tests cover missing, first-record, and valid previous-record chains on PHP 8.3, 8.4 and 8.5.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant