Class: Toolhound::PurchaseOrderItem
- Defined in:
- lib/toolhound-ruby/purchase_order_item.rb
Overview
Class to parse GitHub repository owner and name from URLs and to generate URLs
Constant Summary
Constants inherited from Base
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods inherited from Base
#_build_joins, #_build_selects, #_build_where, #all, #build_and_query, #build_joins, #build_selects, #build_sql, #build_where, #default_wheres, #find, #formatted_table_and_column, #formatted_table_name, #formmatted_column_name, #get_operator, #initialize, #insert, #locale, #merge_options, primary_key, #primary_key, primary_key=, #procedure, #query, rename_attributes, renamed_attributes, #table_name, table_name, table_name=, #transform_attribute_key, #transform_attributes, #transform_procedure_key, #transform_procedure_value, #transform_procedure_variables
Methods included from Util
#acronym_regex, #acronyms, #camelize, #demodulize, #underscore
Constructor Details
This class inherits a constructor from Toolhound::Base
Instance Method Details
#default_joins ⇒ Object
31 32 33 34 35 36 37 |
# File 'lib/toolhound-ruby/purchase_order_item.rb', line 31 def default_joins arr = [] arr << "INNER JOIN tblPurchaseOrderText ON (tblPurchaseOrderText.intPOID = tblPurchaseOrder.intPOID AND varLocaleID = '#{locale}')" # arr << "INNER JOIN tblRentalDetail ON (tblRentalDetail.intRentalDetailID = tblRentalItem.intRentalDetailID)" arr end |
#default_selects ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/toolhound-ruby/purchase_order_item.rb', line 11 def default_selects { purchase_order_detail: [ "intPOID", :int_inventory_id, :dec_cost, :int_qty_ordered, :int_qty_received, :int_qty_rejected, :int_manufacturer_id, :bol_rent, :int_purchase_uof_m, :int_qty_required, :int_qty_returned, :dte_expected ] } # { # purchase_order: [ # "intPOID", "varPONO", :int_vendor_id, :int_location_id, :int_payment_term_id, :bol_closed, :bol_approved, # :dte_created_date, :dte_modified_date, :dte_cancelled_date, :bol_cancelled, :var_revision_no # ], # purchase_order_text: [:txt_notes] # rental_item_detail: [:var_status, :status_date, ], # rental_detail: [:int_rental_id, :int_inventory_id, :int_quantity, :dec_daily, :dec_weekly, :dec_monthly, :dec_selling_price], # } end |
#for_po(po_id) ⇒ Object
39 40 41 |
# File 'lib/toolhound-ruby/purchase_order_item.rb', line 39 def for_po(po_id) end |