Deal pricing
When you set a deal price, opportunity and invoice item objects behave differently.
Set a deal price against opportunities or opportunity groups to override the charge total with a figure that you specify.
When you set a deal price, opportunity item charge totals are hidden in the web interface. Current RMS intelligently apportions revenue to your products, services, and assets based on their share of the deal price, but there's no accessible figure for the opportunity item charge total after deal price. This is because:
the figure isn't relevant: you've told the system that you're doing a deal.
revenue is apportioned to many decimal places: when rounding to two decimal places, there may be rounding issues.
Our default documents mirror the web interface and won't show opportunity item or group charge totals where they're part of a deal.
If you like, you may display the value before a deal price was applied in your document layouts and discussion templates.
Deal pricing impacts:
Detect a deal on an opportunity
Deal exists
Where an opportunity is deal priced or includes a deal priced group, we say that a “deal exists” on it.
Use order.deal_exists?
to detect whether a deal exists. It will return true
or false
.
Opportunity “has deal”
When an opportunity is deal priced, we say that it “has deal”.
Use order.opportunity_has_deal?
to detect whether an opportunity has a deal. It will return true
or false
.
Where
is opportunity_has_deal?true
, deal_exists?
will also be true
. However, deal_exists?
will be true
when opportunity_has_deal?
is false
when the opportunity contains a deal priced group.
Opportunity group “has deal”
When an opportunity group is deal priced, we say that it “has deal”.
Use item.group_has_deal?
in the order.items
loop to detect whether a group has a deal. It will return true
or false
.
Opportunity items “in a deal”
When opportunity items are deal priced, we say that they're “in a deal”.
Use item.is_in_deal?
to in the order.items
loop to detect whether an item is in a deal. It will return true
or false
.
If a deal is set on an opportunity, item.is_in_deal?
will return true
for all items on the opportunity. This includes group items.
If a deal is set on a group, item.is_in_deal?
will return true
for all items inside that group. This includes sub-groups. item.is_in_deal?
will not return true for the group that has a deal.
Detect a deal on an invoice
When you create an invoice from an opportunity with a deal price, the invoice is created slightly differently to an invoice created otherwise.
When you invoice by item, Current will create an invoice item for each tax class within a deal. These deal price line items will have a red “Deal Price” label and are styled as group items in the web interface, but are actually standard invoice items in the backend. We call these ”deal items”.
Keep in mind that, because deal items are standard invoice items, they will not be returned when iterating through group items in the invoice.items
loop.
You could use {% if item.is_group? or item.is_deal_item? %}
to display deal items as groups on your invoices.
Use item.is_deal_item?
in the invoice.items
loop to detect whether an item is a deal item. This will return true
or false
.
Nested underneath a deal item, Current creates informational lines for items that are part of the deal. We say that these are “in a deal”.
Use item.is_in_deal?
in the invoice.items
loop to detect whether an item is an informational line for items that are part of a deal.
You cannot use has_deal
or deal_exists
on an invoice. These are opportunity objects.
Objects that return nil
nil
When part of a deal, opportunity item objects that display pricing information now return nil
. This means that they won't display anything on document layouts or discussion templates.
To return the value of the object before it was part of a deal, prefix with original_
.
Opportunity item
Object that returns | Equivalent object |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Opportunity item surcharge
Object that returns | Equivalent object |
|
|
Opportunity charge totals before deal
You may also prefix opportunity charge totals with original_
to return the value before a deal price.
Object | Equivalent object |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Percentage discounts
When you set a deal price, you may still set a percentage discount on opportunity items -- including discounting items that are deal priced.
Our default documents don't show the saving from deal pricing. This is because discount_total
returns the total discount obtained using percentage discounting of items not in a deal.
On opportunity and invoice documents or discussion templates:
discount_total
shows the total discount using percentage discounting of items not in a deal.deal_discount_total
shows the total discount from items that are part of a deal.combined_discount_total
shows the total discount from both percentage and deal discounting.
Last updated