README.md in erp_integration-0.3.3 vs README.md in erp_integration-0.4.0
- old
+ new
@@ -35,18 +35,18 @@
### Querying third-party vendors
After configuring the gem, one can easily query all the available ERP resources from the connected third-parties.
```ruby
-$ ErpIntegration::Order.where(reference: 'MT1000SKX')
-=> #<ErpIntegration::Fulfil::Collection @items=[<ErpIntegration::Order @id=100 />] />
+$ ErpIntegration::SalesOrder.where(reference: 'MT1000SKX')
+=> #<ErpIntegration::Fulfil::Collection @items=[<ErpIntegration::SalesOrder @id=100 />] />
```
By default, only the `id` will be added to the found ERP resources. However, one can use the `select` method to include more fields.
```ruby
-$ ErpIntegration::Order.select(:id, :reference).where(reference: 'MT1000SKX')
-=> #<ErpIntegration::Fulfil::Collection @items=[<ErpIntegration::Order @id=100 @reference=MT1000SKX />] />
+$ ErpIntegration::SalesOrder.select(:id, :reference).where(reference: 'MT1000SKX')
+=> #<ErpIntegration::Fulfil::Collection @items=[<ErpIntegration::SalesOrder @id=100 @reference=MT1000SKX />] />
```
There are also other type of `where` queries available:
- `where_like` for case sensitive queries.
- `where_ilike` for case insensitive queries.