Class: Harvest::InvoiceCategory
- Inherits:
-
Hashie::Mash
- Object
- Hashie::Mash
- Harvest::InvoiceCategory
- Includes:
- Model
- Defined in:
- lib/harvest/invoice_category.rb
Class Method Summary collapse
Methods included from Model
Class Method Details
.json_root ⇒ Object
6 |
# File 'lib/harvest/invoice_category.rb', line 6 def self.json_root; "invoice_item_category"; end |
.parse(json) ⇒ Object
9 10 11 12 |
# File 'lib/harvest/invoice_category.rb', line 9 def parse(json) parsed = String === json ? JSON.parse(json) : json Array.wrap(parsed).map {|attrs| new(attrs["invoice_category"])} end |