Opportunity item assets
The opportunity item assets object holds information held against opportunity item assets.
When you add a product or service to an opportunity, it creates an opportunity item on that opportunity. Opportunity items have opportunity item assets, which are records for allocations for that item.
An allocation might be a serialized asset or a sub-rent booking.
Generally, the opportunity item asset object is used to print operations documents like Picking Lists, Delivery Notes, and Collection Notes.
Document layouts
The asset object can be accessed in document layouts against the following modules:
Opportunity
{% for asset in order.product_assets %}
{{ asset.asset_number }}
{% endfor %}To print assets against an opportunity item:
{% for item in order.items %}
{% if item.is_item? %}
{% for asset in item.assets %}
{{ asset.asset_number }}
{% endfor %}
{% endif %}
{% endfor %}To print assets inside a container:
{% for asset in order.container_item_asset %}
{{ asset.asset_number }}
{% endfor %}To print assets for a sub-rent supplier:
{% for asset in order.supplier_item_assets %}
{{ asset.asset_number }}
{% endfor %}Member
To print sub-rent allocations for a particular supplier:
{% for sub_rent in member.active_sub_rentals %}
{{ sub_rent.opportunity_item.name }}
{% endfor %}Discussion templates
The asset object can be accessed in document layouts against the following modules:
Opportunity
{% for asset in opportunity.product_assets %}
{{ asset.asset_number }}
{% endfor %}To print assets against an opportunity item:
{% for item in opportunity.items %}
{% if item.is_item? %}
{% for asset in item.assets %}
{{ asset.asset_number }}
{% endfor %}
{% endif %}
{% endfor %}To print assets inside a container:
{% for asset in opportunity.container_item_asset %}
{{ asset.asset_number }}
{% endfor %}To print assets for a sub-rent supplier:
{% for asset in opportunity.supplier_item_assets %}
{{ asset.asset_number }}
{% endfor %}Member
To print sub-rent allocations for a particular supplier:
{% for sub_rent in organisation.active_sub_rentals %}
{{ sub_rent.opportunity_item.name }}
{% endfor %}asset_number
asset_numberWhere serialized, returns an opportunity item asset asset number.
Returns blank for bulk or non-stock.
Input
{{ asset.asset_number }}Output
DB-001barcode_number
barcode_numberWhere bulk or non-stock, returns an opportunity item asset's related product barcode number.
Returns blank for serialized.
Input
{{ asset.barcode_number }}Output
HDMI-000container
containerReturns the opportunity item asset container name.
Returns blank where no container is set.
Input
{{ asset.container }}Output
Box 1cost
costReturns opportunity cost objects for an opportunity item asset.
Input
{% for cost in asset.costs %}
{{ cost.price }}
{% endfor %}Output
100.0depth
depthReturns the depth of an opportunity item asset in the tree. An item’s depth is determined by how it is nested under items.

Input
{{ asset.depth }}Output
1depth_padding
depth_paddingReturns the depth padding for an opportunity item asset. Generally used to apply an inline style to a table cell in HTML so that items appear nested.
Increments in multiples of 16.
Input
<td style="padding-left: {{ asset.depth_padding }}px;">
{{ asset.name }}
</td>Output
<td style="padding-left: 16px;">
Leica R-Series 180mm f/2.8
</td>description
descriptionReturns an opportunity item asset’s related opportunity item description.
Input
{{ asset.description }}Output
Supplied with power cable.group_depth_padding
group_depth_paddingReturns the depth padding for an opportunity item asset's related opportunity group.
Used in our default documents where the order.product_assets is looped, which doesn't include groups.
Input
<td style="padding-left: {{ asset.group_depth_padding }}px;">
{{ asset.group_name }}
</td>Output
<td style="padding-left: 0px;">
Cameras
</td>group_description
group_descriptionReturns the description for an opportunity item asset's related opportunity group.
Used in our default documents where the order.product_assets is looped, which doesn't include groups.
Input
{{ asset.group_description }}Output
This kit goes in the main area.group_name
group_name Returns the name for an opportunity item asset's related opportunity group.
Used in our default documents where the order.product_assets is looped, which doesn't include groups.
Input
{{ asset.group_name }}Output
Camerashas_shortage?
has_shortage?Returns true where an opportunity item asset has a shortage; false otherwise.
Shortages are highlighted in red and have an ⚠️ exclamation icon next to them in the list.
Input
{{ asset.has_shortage? }}Output
trueid
idReturns an opportunity item asset ID.
Input
{{ asset.id }}Output
1 is_bulk_stock?
is_bulk_stock?Returns true if an opportunity item asset is for bulk stock; false otherwise.
Input
{{ asset.is_bulk_stock? }}Output
trueis_non_stock_booking?
is_non_stock_booking?Returns true if an opportunity item asset is a non-stock allocation; false otherwise.
Text items are considered non-stock allocations.
Input
{{ asset.is_non_stock_booking? }}Output
trueis_resource_stock?
is_resource_stock?Returns true if an opportunity item asset is a service with bookable resource, i.e. a bookable resource has been allocated; false otherwise.
Input
{{ asset.is_resource_stock? }}Output
trueis_serialised_component?
Returns true if an opportunity item asset is a serialized component, i.e. it is part of a serialized container; false otherwise.
is_serialised_container?
Returns true if an opportunity item asset is a serialized container; false otherwise.
is_serialised_stock?
is_serialised_stock?Returns true if an opportunity item asset is a serialized stock allocation, i.e. a serialized asset has been allocated; false otherwise.
Input
{{ asset.is_serialised_stock? }}Output
truelocation
locationReturns the stock level location for an opportunity item asset.
Input
{{ asset.location }}Output
Bay A2 Shelf G4name
nameReturns an opportunity item asset's name. This will always be the name of the opportunity item.
Input
{{ asset.name }}Output
D&B E3 Speakeropportunity_item
Returns opportunity item objects for an opportunity item asset.
Generally used to access information like the opportunity item charge total or description.
Input
{{ asset.opportunity_item.charge_total }}Output
180.0outer_container
Returns the container attribute of a serialised component's serialised container. Otherwise returns the same as the container method.
product
productReturns product objects for an opportunity item asset, where related to a product.
Input
{{ asset.product.description }}Output
The E3 is an extremely small and versatile high performance system with astonishing sound and excellent headroom. The horn, which may be rotated to give either 90° x 60° or 60° x 90° coverage, has the necessary flexibility in directivity to enable a variety of applications such as delay, infill or distributed sound reinforcement applications. quantity
quantityReturns the quantity against an opportunity item asset.
Input
{{ asset.quantity }}Output
2replacement_value
replacement_valueReturns the replacement charge for an opportunity item asset. This may differ from the opportunity item replacement charge depending on the quantity.
Input
{{ asset.replacement_value }}Output
20.0resource
resourceReturns contact, user, or vehicle objects for a bookable resource allocation.
Input
{{ asset.resource.name }}Output
Jo Swansonresource_name
resource_nameReturns the name of the contact, user, or vehicle for a bookable resource allocation.
Input
{{ asset.resource_name }}Output
Jo Swansonreturn_assets
return_assetsReturns opportunity item return assets for an opportunity item asset.
Input
{% for return in asset.return_assets %}
{{ return.return_at }}
{% endfor %}Output
2021-07-28 10:00:00 +0000serial_number
serial_numberReturns the stock level serial number for an opportunity item asset.
Input
{{ asset.serial_number }}Output
D03VGP9CNHT20service
serviceReturns service objects for an opportunity item asset, where related to a service.
Input
{{ asset.service.description }}Output
Let us take care of all of the setup for you!service_name
service_nameReturns the name of the related service for an opportunity item asset.
Input
{{ asset.service_name }}Output
Installstatus
statusReturns the opportunity item asset status ID.
ID
Status name
1
Provisional
2
(Allocated)
5
Reserved
10
Allocated
15
Prepared
20
Booked Out
30
Checked In
40
Completed
45
Moved
Input
{{ asset.status }}Output
5status_name
status_nameReturns the opportunity item asset status name.
Status names are in the language set against your user profile.
Provisional
(Allocated)
Reserved
Allocated
Prepared
Booked Out
Checked In
Completed
Moved
Input
{{ asset.status_name }}Output
Reservedstock_level
stock_levelReturns stock level objects for the related stock level of an opportunity item asset.
Input
{{ asset.stock_level.location }}Output
Bay A2 Shelf G4supplier
supplierReturns organization objects for a sub-rent or sub-contract supplier related to an opportunity item asset.
Input
{{ asset.supplier.address }}Output
3934 Giraffe Hill Drive, Farmers Branch, TX 75234supplier_name
supplier_name Returns the name of the organization set as a sub-rent or sub-contract supplier for an opportunity item asset.
Input
{{ asset.supplier_name }}Output
Vita Soundweight
weightReturns the weight for an opportunity item asset's related opportunity item.
Input
{{ asset.weight }}Output
10.0weight_total
weight_totalReturns the weight total for an opportunity item asset. This may differ from the opportunity item replacement charge depending on the quantity.
Input
{{ asset.weight_total }}Output
20.0Last updated
Was this helpful?