Quotes (Conceptual Guide)

At the end of this lesson you will be able to:

  • explain, how to implement the calculation of line items of a Quote

    • explain, how to ask user for inputs (i.e. create input fields)

What is a Quote

Document for negotiation of product prices and other conditions.

Figure 1. Quote Header Sample
Figure 2. Quote Line Items Sample

Data Model

Figure 3. Tables used for Quotes

Quote Life Cycle

Figure 4. Highlevel Quote life cycle overview

Use Cases

Add Line Item

Figure 5. Process of adding new product line item to the Quote
Create new input field
1 2 3 4 if (api.isSyntaxCheck()) { api.userEntry("Quantity") // ❶ api.getParameter("Quantity").setRequired(true) // ❷ }

❶ during Syntax Check mode, this function builds a definition for an input field
❷ retrieve reference to the input field definition and sets additionally to be required

Read value provided by the user in the input field - several examples with the same result
1 2 3 4 5 // all these samples work only in regular execution (i.e. not in Syntax Check mode) input.Quantity input["Quantity"] api.input("Quantity") api.userEntry("Quantity")

Recalculate Line Items

Figure 6. Process of recalculation of the Quote document

Configuration / Implementation of Quote

The configuration/implementation of Quote usually consist of many things. This Handbook focuses only on the simple implementation.

  1. Simple implementation:

    • Line Item Logic

    • Quote Type setup

  2. Common implementation also has:

    • Header Logic

    • System Configuration Options

    • Approval Workflow

    • Price Record Mapping

Line Item Logic

The Quote Line Item logic typically does:

  • create input fields for the line item

    • this is done only once, when the new line item is added. The logic will be executed in Syntax Check mode to collect the input fields for the SKU. And the system will store those input fields definitions on the line item.

  • calculate the results for the SKU on the line item

    • this is called for action each time, when the user re-calculates the Quote.

Quote Type Setup

The Quote Type describes, which logics will be used to perform various operations with the Quote.

You can find the types under Quoting  Quote Types.

It sets:

  • the Line Item logic - which logic will be used for every line of the Quote, to create it’s input fields, and to calculate its results. The only exception is, if the SKU would have a logic setup on the Product level (i.e. in the Product Master table)

  • the Header Logic - which logic is used to prepare header input fields and calculate aggregated overall results of the Quote.

  • the Workflow logic - which logic will prepare the approval Steps for the Quote after Submission.