Skip to main content

PurchaseReceiving

The PurchaseReceiving entity, mapped to the purchase_receiving table.

Tablepurchase_receiving
Tenant-scopedYes — extends TenantOwned
Columns6
Relationships3
Sourcebackend/src/main/java/com/motorph/payroll/model/PurchaseReceiving.java

Columns​

FieldTypeColumnNullNotes
receivingIdIntegerreceiving_id—primary key, generated
referenceNoStringreference_noYes—
receivedDateLocalDatereceived_date——
notesStringnotesYes—
statusStringstatus——
createdAtLocalDateTimecreated_at——

Plus tenant_id, inherited from TenantOwned. Hibernate stamps it on insert and adds where tenant_id = ? to every query, so it is never written or read by application code.

Relationships​

FieldKindTargetJoin columnRequired
supplier@ManyToOneSuppliersupplier_idYes
receivedBy@ManyToOneUserreceived_by—
items@OneToManyPurchaseReceivingItemmapped by receiving—

Referenced by​

EntityFieldKind
PurchaseReceivingItemreceiving@ManyToOne

Neighbourhood​

Repository​

PurchaseReceivingRepository​

Declared over PurchaseReceiving with id type Integer, with JpaSpecificationExecutor for dynamic filtering. Source: backend/src/main/java/com/motorph/payroll/repository/PurchaseReceivingRepository.java

MethodReturnsNotes
findAllByOrderByCreatedAtDesc(Pageable pageable)Page<PurchaseReceiving>derived
findAllBySupplier_SupplierId(Integer supplierId, Pageable pageable)Page<PurchaseReceiving>derived
existsBySupplier_SupplierId(Integer supplierId)booleanderived

Reached by​

These controllers hold — directly or through a service they depend on — a repository over PurchaseReceiving.

ControllerBase pathEndpointsModule
InventoryController/api/inventory38Inventory & Portal

Generated page

This page is rebuilt from the source on every docs build by docs-site/scripts/gen-code-wiki.mjs. Editing it has no effect — change the code, or, if what you want to say is prose, write it in docs/.