Accounts Receivable (AR)#

AR tracks what customers owe us. Invoices flow from Ship Bills, credit memos from returns / adjustments, cash comes in via Deposits.

Structure#

  • AR invoices are the customer-facing side of Ship Bills — one AR row per invoiced ship-bill.
  • AR aging snapshots (ARAging/) — imported / computed for AP-side counterparties too.
  • Offsets (ArOffsetHelper) — mutual net-off between AR balance and AP balance for entities that are both customer and supplier.
  • Credits — ArCreditHelper covers customer credit memos and the NSF-view (ArCredit4NSFView).

Flow#

  1. Ship Bill posts (see Ship Bills).
  2. AR liability posts to the customer’s default AR account via ArSetupHelper.
  3. Customer payment lands in a Deposit — see Payments, Deposits & Bank.
  4. Deposit line is applied to one or more AR invoices; short-pays / discounts / write-offs post to the configured GL accounts.

Offsets#

When a supplier is also a customer, ArOffsetHelper nets the AP balance we owe them against the AR balance they owe us — reduces cash movement and reconciles the two ledgers.

Business rules#

  • An AR invoice can be voided only while unpaid; a paid invoice needs a credit memo.
  • Discounts taken past the discount date are blocked unless overridden.
  • Aging buckets are configurable per tenant (typically Current / 30 / 60 / 90 / 120+).
  • NSF (returned payment) reverses the payment application and re-opens the AR balance.

Where it lives#

LayerFile
ControllerAccountReceivableController, ArAgingImportController
HelperArSetupHelper.cs, ArOffsetHelper.cs, ArCreditHelper (via IArCreditHelper), MnxEFModel/Helper/ARAging/
RelatedShip Bills, Payments, Deposits & Bank, GL