Condition Field Reference

The Condition object stores the values of the fields that trigger the discount calculation, discount rates, and data about the calculation type and method.


Object API name: orders__Condition__c


Field API Name Type Description

Active

orders__IsActive__c

Checkbox

If selected, the record is active and applied in business logic.

Advanced Criteria

orders__AdvancedCriteria__c

Long Text Area(32768)

Conditions that affect discount calculation in JSON format (required if the Advanced Calculation Method is selected).

Calculation Method

orders__CalculationMethod__c

Picklist

The method of cost calculation:

  • Basic is based on the selected Order Line Item.

  • Advanced requires adding conditions/criteria for discount calculation in JSON format.

Calculation Type

orders__CalculationTypeId__c

Master-Detail(Calculation Type)

Calculation Type identifier.

Condition Details

orders__ConditionDetails__c

Long Text Area(32768)

Stores fields values that initialize discount calculation or the advance conditions in JSON to check if the discount should be calculated.

Condition Group

orders__ConditionGroupId__c

Lookup(Condition Group)

Condition Group identifier.

Discount Rate (%)

orders__DiscountRatePercent__c

Percent(16, 2)

Discount in percent.

Discount Rate (Amt)

orders__DiscountRateAmount__c

Number(16, 2)

Discount in amount.

Discount Rate Location

orders__DiscountRateLocation__c

Picklist

Specifies where the discount rate value is stored:

  • Condition Record

  • Level record

Discount Rate Source Field (%)

orders__DiscountRateFieldPercent__c

Text(255)

Specify the API name of the fields for discount calculation (inc. manual). Can only contain fields with the type Percent.

If the field is empty, the discount calculation will be based on the Discount Rate (%) value.

Discount Rate Source Field (Amt)

orders__DiscountRateFieldAmount__c

Text(255)

Specify the API name of the fields for discount calculation (inc. manual). Can only contain fields with the type Number.

If the field is empty, the discount calculation will be based on the Discount Rate (Amt) value.

End Date

orders__EndDate__c

Date

After this date, the condition is no longer available. For example, if the End Date is set to 14 Mar 2024, the condition will not be available if the current date is 15 Mar 2024, but remains available on 14 Mar 2024.

Exception Condition

orders__ExceptionCondition__c

Long Text Area(32768)

Condition in JSON format, which makes discount inapplicable for the order if the condition is matched during the price calculation process.

External Id

orders__ExternalId__c

Text(255) (External ID) (Unique Case Insensitive)

External record identifier for ERP/CRM system (if required).

Name

Name

Autonumber

Condition name.

Order

orders__Order__c

Number(18, 0)

Numerical order that used during the search. The system applies a record with the lowest number in this field.

Payment Term

orders__PaymentTermId__c

Lookup(Payment Term)

Applied payment terms.

Promotion Id

orders__PromotionId__c

Lookup (Promotion)

Promo identifier.

Start Date

orders__StartDate__c

Date

Since this date, the condition is available.

If a current date (order creation date) does not fall within the specified condition date range, the discount will not be calculated.

Unique Id

orders__UniqueId__c

Text(255) (External ID) (Unique Case Insensitive)

This field stores the unique identifier for a condition to make sure that the order is not repeated among Calculation Type or Condition Group records.

``