Purchase Orders - codbex/codbex-olympus GitHub Wiki

Purchase Order is the official offer documenting the exact requirement of the buyer, upon which an invoice can be created.

PurchaseOrder

Entity Definition

  • Entity Type: Primary Entity
  • Layout Type: Manage Entities
Field Type Length Null? Calc? Ref? Description
Id INTEGER no - -
Number VARCHAR 10 no - -
Date DATE no - -
Due DATE - - -
Supplier INTEGER no - yes Reference to Suppliers
Net DECMIAL - yes - SUM(PurchaseInvoiceItem.Net)
Currency INTEGER - - yes Reference to Currency
Gross DECMIAL - yes - SUM(PurchaseInvoiceItem.Gross)
Discount DECMIAL - - - % Discount
Taxes DECMIAL - - - % Taxes (other than VAT)
VAT DECMIAL - yes - SUM(PurchaseInvoiceItem.Net * %VAT)
Total DECMIAL - yes - Gross - (Gross * Discount / 100) + (Gross * Taxes / 100) + VAT
Conditions VARCHAR 200 - - - Conditions about payment
PaymentMethod INTEGER - - yes Reference to Methods
SentMethod INTEGER - - yes Reference to Methods
Status INTEGER - - yes Reference to Invoice Status
Document VARCHAR 200 - - - Link to the scanned copy of the document
Company INTEGER - - yes Reference to Companies
Name VARCHAR 200 - yes - Supplier.Name/Number/Date/Amount
UUID VARCHAR 36 - yes - Random UUID generated
Reference VARCHAR 36 - - - Reference via UUID to the PurchaseOrder

PurchaseOrderItem

Entity Definition

  • Entity Type: Dependent Entity
  • Layout Type: Manage Details Entities
Field Type Length Null? Calc? Ref? Description
Id INTEGER no - -
Purchase Order INTEGER no - yes Reference to Purchase Order
Name VARCHAR 2000 no - - Free text representing Product/Service
Quantity DOUBLE no - -
UoM INTEGER no - yes Reference to UoM
Price DECMIAL no - -
Net DECMIAL - yes - Quantity * Price
VAT DECMIAL - - - Net * 0.2(depends of the country, for now 20% VAT
Gross DECMIAL - yes - Net + VAT