Interface: ReconLine
Defined in: src/server/services/invoice/weeklyRun.ts:147
One per-contractor reconciliation line on the invoice shelf: contracted vs logged hours with the approved/unapproved split, and the cents amount that line will bill.
loggedHours, approvedHours, and unapprovedHours are decimal hours rounded to 2 places;
contractedHours is the raw contracted value from the assignment. hourlyRateCents and amountCents are integer
cents (hourlyRateCents is null when the assignment has no rate, in which case amountCents is 0
and the shelf surfaces a "No rate" warning). amountCents bills the lesser of loggedHours and
contractedHours × the rate — unless the facility approved this week's overage, which lifts the
cap and bills full logged hours (mirrors the generator's computeInvoiceLines). variancePct is
|logged − contracted| / contracted as a percent rounded to 1 decimal; when contractedHours is 0
(or less) it is 100 if any hours were logged, else 0. varianceFlagged is true only when the overage
was NOT approved and variancePct exceeds the facility's threshold.
invoiceLabel is set when any of this line's hours already sit on a SENT invoice (see
invoiceLabelFor) — it drives the ADR-0050 §3 reissue warning on the shelf's hours form.
That invoice is not necessarily this shelf's invoice: an older invoice whose period only partly
overlaps this Mon–Sun week can cover some days while the week's own invoice is still a draft.
Properties
amountCents
amountCents:
number
Defined in: src/server/services/invoice/weeklyRun.ts:157
approvedHours
approvedHours:
number
Defined in: src/server/services/invoice/weeklyRun.ts:154
assignmentId
assignmentId:
string
Defined in: src/server/services/invoice/weeklyRun.ts:149
contractedHours
contractedHours:
number
Defined in: src/server/services/invoice/weeklyRun.ts:152
contractorId
contractorId:
string
Defined in: src/server/services/invoice/weeklyRun.ts:148
contractorName
contractorName:
string
Defined in: src/server/services/invoice/weeklyRun.ts:150
hourlyRateCents
hourlyRateCents:
number|null
Defined in: src/server/services/invoice/weeklyRun.ts:156
invoiceLabel?
optionalinvoiceLabel?:string
Defined in: src/server/services/invoice/weeklyRun.ts:161
Sent invoice(s) already covering some of these hours, e.g. "INV-0007". Absent when none.
loggedHours
loggedHours:
number
Defined in: src/server/services/invoice/weeklyRun.ts:153
serviceType
serviceType:
string|null
Defined in: src/server/services/invoice/weeklyRun.ts:151
unapprovedHours
unapprovedHours:
number
Defined in: src/server/services/invoice/weeklyRun.ts:155
varianceFlagged
varianceFlagged:
boolean
Defined in: src/server/services/invoice/weeklyRun.ts:159
variancePct
variancePct:
number
Defined in: src/server/services/invoice/weeklyRun.ts:158