Magidoc

OpenPayable
Object

Fields

#

workspaceId

ID !
Non-null

The books this row was read out of. Every stage of the aggregation behind it matches on this workspace, in both halves of its union, so a page is one workspace by construction.

sourceType

Non-null

sourceId

ID !
Non-null

sourceDocumentNumber

vendorAccountId

vendorAccountName

The vendor's name, joined from the CRM account vendorAccountId points at. Null when the payable names no vendor — an expense report never does, being owed to the employee who filed it — or names one this workspace cannot resolve.

employeeUserId

The employee this payable reimburses — an expense report's filer. Null on the two vendor arms, which name vendorAccountId instead.

employeeName

The name of the person employeeUserId points at, joined by the list read, so the payee column reads as a person rather than as the category the row belongs to. Null on a vendor row, and on an employee row whose user this workspace cannot resolve.

glCompanyId

The GL company whose books this row's document was numbered in. Numbers are allocated per company, so two rows in a multi-company workspace can legitimately carry the same one and this is what tells them apart. Null on the expense-report arm, which stores no company and is therefore the default company's.

projectId

projectName

Name of the project this document is filed against, resolved at read time and scoped to what the requesting member may see. Null when the project no longer exists or is not visible to them — clients render their unlinked fallback for both, and must never assume the name of a project the reader cannot open.

status

Non-null

paymentState

Non-null

dueDate

documentDate

Non-null

The date the document itself carries — a bill's issue date, and the date an expense report or purchase order was raised. Always present, unlike dueDate, which a payable only earns at approval: the register's Date column reads this when there is no due date yet, so a submitted payable can still be aged and ordered.

ageDays

Non-null

amount

Non-null

What this row still owes. The column it fills is headed Open amount, and the header totals it as open A/P.

originalAmount

Non-null

What the row was raised for, before any payment relieved it — equal to amount plus paidAmount on every arm.

paidAmount

Non-null

What payments have settled against this row so far. Zero and the original amount are what tell an untouched payable from a part-paid one, which the open balance alone cannot.

purchaseOrderId

vendorBillId

vendorInvoiceLink

Usages

#

References

#

  • Field getOpenPayables from Query