bcgov / bcgov/entity

Tracking financial events outside of the invoice records

Open
#33,234 1 comment 0 reactions 0 assignees View on GitHub
Pay
Dominant language
JavaScript
Stars
23
Forks
62
Avg merge
24m
Merged PRs (30d)
1

Description

### Background:
In order to meet core policy, SBC Finance needs to record and track certain post-payment events. These are best recorded separately from the original invoice(s), so that additional details can be captured and the original invoice can remain intact.

Here are some example events that need to be tracked:
| Event type | Why it must be distinct |
|:---------------------------:|:---------------------------------------------------------:|
| CHARGEBACK | External reversal; may be fraud; may never be collectible |
| PAYMENT_FAILURE / NSF | Similar financially, different authority & recovery rules |
| COLLECTIONS_INITIATED | Evidence of CPPM‑required action |
| COLLECTION_ACTIVITY | Letters, follow‑ups, payments |
| PAYMENT_RECEIVED_POST_EVENT | Partial or full recovery |
| WRITE_OFF | Requires approval & justification |
| MANUAL REFUND | (e.g. cheque issued by SBC Finance) Requires approval & justification |

### Proposal:
Create a separate table to track these financial events.

Here are some draft starting columns (for review/discussion)

- event_id
- invoice_id (FK to immutable invoice)
- event_type (ENUM)
- event_date
- amount_affected
- source_system (CAS / PT / internal)
- external_reference (e.g., bank dispute ID, JV ref)
- created_timestamp
- created_by

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.