class Skr::PoReceipt
Is a record of an inventory receipt A {PurchaseOrder} can have one or more of them
Public Instance Methods
purchase_order=(po)
click to toggle source
Calls superclass method
# File lib/skr/po_receipt.rb, line 26 def purchase_order=(po) super self.location ||= purchase_order.location self.vendor = purchase_order.vendor end
Private Instance Methods
attributes_for_gl_transaction()
click to toggle source
# File lib/skr/po_receipt.rb, line 34 def attributes_for_gl_transaction { location: location, source: self, description: "PO RECPT #{self.visible_id}" } end
logit()
click to toggle source
# File lib/skr/po_receipt.rb, line 39 def logit end
record_freight()
click to toggle source
# File lib/skr/po_receipt.rb, line 42 def record_freight GlTransaction.current.add_posting( amount: self.freight, debit: GlAccount.default_for( :inventory_receipts_clearing ), credit: vendor.gl_freight_account ) end