Class: DearInventory::Resource
- Inherits:
-
Object
- Object
- DearInventory::Resource
- Extended by:
- IsASubclass, T::Sig
- Defined in:
- lib/dear_inventory/resource.rb
Direct Known Subclasses
AdvancedPurchase, Customer, Product, ProductAvailability, Purchase, Sale
Instance Method Summary collapse
Methods included from IsASubclass
Instance Method Details
#request(action, model:, endpoint: nil, params: {}) ⇒ Object
17 18 19 20 21 22 23 24 25 |
# File 'lib/dear_inventory/resource.rb', line 17 def request(action, model:, endpoint: nil, params: {}) request = DearInventory::Models::Request.new( action: action, model: model, params: DearInventory::Parameters.convert(self.class, endpoint, params), uri: resource_uri(endpoint) ) DearInventory::Request.(request) end |