Consolidated opportunity items
The consolidated opportunity items object holds information about items on an opportunity, consolidated by product name.
Last updated
The consolidated opportunity items object holds information about items on an opportunity, consolidated by product name.
Last updated
An item might appear on an opportunity in multiple places. The consolidated opportunity items object merges all opportunity items related to the same product or service into a single line.
order.consolidated_items
Returns consolidated items
order.consolidated_principal_opportunity_items
Merges only opportunity items that are principal items. This means this doesn't return any accessories.
The consolidated opportunity items object is available anywhere you can access opportunity items.
charge_excluding_tax_total
Returns a consolidated opportunity item charge total excluding tax.
Use the currency filter or a number filter to change the way that the number is formatted.
charge_including_tax_total
Returns a consolidated opportunity item charge total including tax.
charge_total
Returns a consolidated opportunity item charge total.
This may be including or excluding tax depending on the value of the “Catalog Prices” setting in System Preferences.
is_product?
Returns true
if a consolidated opportunity item is linked to a product record; false
otherwise.
is_rental?
Returns true
if a consolidated opportunity item is a rental charge, i.e. its transaction type is "Rental"; false
otherwise.
is_sale?
Returns true
if a consolidated opportunity item is for a sale charge, i.e. its transaction type is "Sale"; false
otherwise.
is_service?
Returns true
if a consolidated opportunity item is for a service charge, i.e. its transaction type is "Service"; false
otherwise.
This doesn't determine necessarily whether an opportunity item is linked to a service record; a text item may have the transaction type "Service".
is_service_item?
Returns true
if an opportunity item is linked to a service record; false
otherwise.
is_text_item?
Returns true
if an opportunity item is a text item; false
otherwise.
name
Returns an opportunity item's name.
opportunity
Returns opportunity objects for the opportunity that an opportunity item is related to.
When working with a document or discussion template on an opportunity record, you may simply wish to access the opportunity object as normal. For example, use {{ order.name }}
to print the opportunity subject.
product_stock_levels
Returns stock level objects for opportunity item's related stock levels where:
the item is a product
it's bulk or serialized
stock levels are in the same store
stock levels have a stock type matching the opportunity item’s stock type (i.e. rental or sale)
Keep in mind that this returns any stock levels that match the criteria above. Use the assets
object to return allocated assets.
quantity
Returns the quantity of an opportunity item.
revenue_group
Returns the revenue group name for an opportunity item.
surcharge_amount
Returns the surcharge amount for an opportunity item.
Surcharges are percentage or fixed fees that are applied to rental items. An opportunity item might have multiple surcharges applied.
Returns blank for groups, sale items, and service items. Returns an error for subtotals.
tax_total
Returns the tax total for an opportunity item. Works for items and groups.
transaction_type_name
Returns the transaction type name for an opportunity item.
Rental
Sale
Service
use_chargeable_days
Returns true
if an opportunity item has overriden chargeable days.
This will be the case where the opportunity has the "Chargeable Days" toggle set to YES.