Financials

Generation and Adjustment of Invoice or Bill using Invoice/Bill Rule

Multiple invoice/bills can be generated from a single buy or sell shipment in OTM. Invoice/bill rules are designed for auto generation and adjustment of invoices or bills by grouping the cost lines/allocated cost lines of the shipment based on the invoice/bill rules. For example, you can generate one invoice or bill for each group of lines with same currency, you can generate one invoice or bill for each group of lines with same involved party, etc.

Invoice/bill rule can be specified in one of the following ways to generate an invoice or a bill:

  • Specify an invoice/bill rule ID. The UI action or agent action will use the specified rule to generate the invoice/bill from the shipment.
  • Specify rule in planning parameter 'Invoice Split Rule' or 'Bill Split Rule'. If a rule is used for all the invoices and bills for a planning parameter scope this value can be set here and the user will not have to enter it for all actions.
  • Use the Match Rule check box to look up an invoice/bill rule for the shipment. Here user-specific rules, Incoterms, etc can be used to match the shipment with a rule to be used to generate the invoice/bill.

Invoice/bill rule is used for the following purposes:

  • To specify rule constraint set for matching the rule with shipment.
  • To specify the source (i.e. line origin) for the invoice. Following are the supported line origins:
    • Shipment cost: Shipment cost records will be used as source for generating invoice or bill.
    • Order release allocation: Order release allocated records will be used as source for generating invoice or bill.
    • Order release line allocation: Order release line allocated records will be used as source for generating invoice or bill.
    • Order base line allocation: Order base line allocated records will be used as source for generating invoice or bill.
  • For assignment of Bill To party to each cost.
  • For line grouping. After getting invoice or bill lines based on the line origin, they can be grouped based on certain criteria such as cost type, remarks etc. One invoice or bill will be generated per group.

Matching and Validation of Invoice/Bill Rule

An invoice/bill rule can be identified for the shipment to generate an invoice or a bill using the "Match Rule" setting. The invoice/bill rule will be matched for the shipment based on following criteria:

  • The rule must be active.
  • Start date of the shipment must be in range of the effective and the expiry dates specified on the rule. Blank values in these fields will also be considered as a validate match.
  • If there are multiple rule matches, then the rule will be picked up based on the priority sequence ('1' will be considered as highest priority).
  • If a rule constraint set is present, rule will be matched based on the criteria specified in it. Following is the list of constraint types:
    • Shipment Incoterm
    • Shipment Refnum
    • Shipment Involved party
    • Shipment String flex field
    • Shipment Number flex field

For a valid match, the values (constraint set details) provided on the constraint set must match with the values present on the shipment. For example:

Invoice/Bill Rule: Rule 1

  • Type: Invoice or Bill
  • Active: Yes
  • Priority Sequence: 5
  • Constraint set type: INVOICE - MATCH RULE or BILL - MATCH RULE
  • Constraint type: Values
  • Shipment Incoterm: FCA
  • Shipment Involved party:
    • Qualifier: Shipper 
    • Contact or Party: WAL

Invoice/Bill Rule: Rule 2

  • Type: Invoice or Bill    
  • Active: Yes    
  • Priority Sequence: 1    
  • Constraint set type: INVOICE - MATCH RULE or BILL - MATCH RULE
    • Constraint type: Values
    • Shipment Incoterm: FCA
    • Shipment Involved party: NA (blank) / NA (blank)

Shipment S1

  • Incoterm: FCA
  • Involved parties:
    • Qualifier: Shipper
    • Value: WAL

Invoice/bill rule "Rule 2" and "Rule 2" both are matching with shipment "S1", but Rule 2 will be picked up based on the priority sequence.

If an invoice/bill rule is directly specified on the UI or as a planning parameter to generate invoice or bill, the rule will be validated using the same set of criteria (used for match rule).

Line Grouping

Cost lines fetched based on the line origin can be grouped as per grouping criteria specified in the line grouping constraint set of the invoice/bill rule.

One invoice or bill will be generated per group and the attributes or the constraint set details used for line grouping will be persisted on the generated invoice or bill for that group.

Note: In case of reference number, whether to persist all reference numbers or only the matched reference numbers on the generated invoice or bill will be decided based on the property glog.invoice.lineGrouping.copyAllRefnums. If true, all reference numbers from line items will be copied. If false, only matched reference numbers will be copied, i.e. if reference numbers were used as matching criteria. The default value of the property is true.

Examples to Generate Invoice using Invoice/Bill Rule

Note: This example is for invoice but the same set of invoice/bill rule scenarios would work on bill as well.

Shipment S1 with Shipment Costs

Sequence

Cost Type

Shipment Cost

Accessorial Code

Special Service Code

Payment Method Code

1.

Base

$100

 

 

FCA

2.

Accessorial

$100

Loading

Loading

 

3.

Accessorial

€100 

Handling

 

FAS

4.

Accessorial

€200

 

 

 

5.

Accessorial

$200

 

 

 

 

Order Releases associated with Shipment S1

 

 

Order Release 1

Order Release 2

Sequence

 

Qualifier

Value

Qualifier

Value

a.

Involved Party

Buyer

WAL

Seller

WOR

 

 

Order Owner

WAL

Order Owner

WOR

b.

Remark

Business Unit  

WAL-WL

Business Unit

 WOR-OR

c.

Refnum

OP_UNIT   

WAL-WL

OP_UNIT

WOR-OR

d.

String Flex Field

Attribute1   

xyz

Attribute1

abc

e.

Number Flex Field

AttributeNumber1

123

AttributeNumber1

456

f.

Date Flex Field

AttributeDate1  

10-NOV-2020

 AttributeDate1

10-DEC-2020

 

Invoice/Bill Rule Used to Generate Invoice

Group by Shipment Cost

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Line grouping constraint set: Not required (Leave this field blank)
Result

OTM will generate one invoice for each group, one group will be created per cost line.

For the above example, five invoices (one for each cost line) will be generated:

Invoice Line Items
Invoice1 Base $100
Invoice2 Accessorial $100
Invoice3 Accessorial €100
Invoice4 Accessorial €200
Invoice5 Accessorial $200

Group by cost type

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – COST TYPE
Result

OTM will generate one invoice for each group of cost lines with same cost type.

or above example, two invoices will be generated:

  1. Invoice with lines of base cost type.
  2.  Invoice with lines of accessorial cost type.
Invoice Line Items
Invoice1 Base $100
Invoice2 Accessorial $100
Accessorial €100
Accessorial €200
Accessorial $200

Group by Accessorial Code

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin:  Shipment cost
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – ACCESSORIAL CODE
 Result

OTM will generate one invoice for each group of cost lines with same set of accessorial cost with accessorial code and special service code.

In above example, four invoices will be generated:

  1. Invoice with lines with non-accessorial cost types i.e. for one base cost line.
  2. Two invoices, one for each distinct combination of accessorial cost with accessorial code and special service code.
  3. Invoice with two accessorial cost lines without any accessorial code or special service code.
Invoice Line Items
Invoice1 Base $100
Invoice2 Accessorial $100
Invoice3 Accessorial €100 
Invoice4 Accessorial €200
Accessorial $200

Group by Payment Method Code

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – PAYMENT METHOD
Result

OTM will generate one invoice for each group of cost lines with same payment method.

In the above example, three invoices will be generated:

  1. Invoice with cost lines with payment method [FCA].
  2. Invoice with cost lines with payment method [FAS].
  3. Invoice with cost lines with payment method [Not available].
Invoice Line Items

Invoice1

Payment Method

FCA

Base $100

Invoice2

Payment Method

FAS

Accessorial €100

Invoice3

Payment Method

Accessorial €100
Accessorial €200
Accessorial $200

Group by Currency

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – CURRENCY
Result

OTM will generate one invoice for each group of cost lines with same currency.

Assuming cost has been allocated equally for order releases., in above example, two invoices will be generated:

  1. Invoice with cost lines with currency [$].
  2. Invoice with cost lines with currency [€].
Invoice Line Items

Invoice1

Currency

$

Base $100
Accessorial $100

Invoice2

Currency

Accessorial €100
Accessorial €200

Group by Reference Numbers

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: order release allocation
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – REFNUMS with qualifier [OP_UNIT]
Result

OTM will generate one invoice for each group of cost lines with same currency.

In above example, two invoices will be generated:

  1. Invoice with cost lines with reference number [OP_UNIT , WAL-WL].
  2. Invoice with cost lines with reference number [OP_UNIT , WOR-OR].
Invoice Line Items

Invoice1

Reference number qualifier: OP_UNIT

Value: WAL-WL

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Invoice2

Reference number qualifier: OP_UNIT

Value: WOR-OR

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Group by Remarks

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: order release allocation
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE –  REMARKS with qualifier [Business Unit]
Result

OTM will generate one invoice for each group of cost lines with same set of remark (qualifier and value).

In above example, two invoices will be generated:

  1. Invoice with cost lines with remark [Business Unit, WAL-WL].
  2. Invoice with cost lines with remark [Business Unit, WOR-OR].
Invoice Line Items

Invoice1

Remark qualifier: Business Unit

Value: WAL-WL

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Invoice2

Remark qualifier: Business Unit

Value: WOR-OR

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Group by Involved Parties

Without Bill To Party Assignment
Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – INVOLVED PARTIES with qualifier [Order owner]
Result

OTM will generate one invoice for each group of cost lines with same set of involved party qualifier and its value (party).

In above example, two invoices will be generated:

  1. Invoice with cost lines with involved party [Order owner, WAL].
  2. Invoice with cost lines with involved party [Order owner, WOR].
Invoice Line Items

Invoice1

Involved party qualifier: Order owner

Value: WAL

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Invoice2

Involved party qualifier: Order owner

Value: WOR

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100
With Bill To Party Assignment
Bill to Party Assignment
  • Name: BPA
  • Bill To Party Qualifier: bill-to

 

Seq # Cost type Accessorial Code Cost Identifier Involved Party Qualifier
1. Base     BUYER
2. Accessorial Loading   SELLER
3. Accessorial Handling   SELLER
4. Accessorial     BUYER

Base type or accessorial type cost lines: Involved parties associated with the qualifier "BUYER" for the line origin will be set on these cost lines as party with qualifier (bill-to).

Accessorial type cost lines with accessorial code (Loading or Handling): Involved parties associated with the qualifier "SELLER" for the line origin will be set on these cost lines as party with qualifier (bill-to).

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Bill to Party Assignment: BPA
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – INVOLVED PARTIES with qualifier [ bill-to ]
Result

OTM will generate one invoice for each group of cost lines with same set of involved party qualifier and its value (party).

In above example, two invoices will be generated:

  1. Invoice with cost lines with involved party [bill-to, WAL]
  2. Invoice with cost lines with involved party [bill-to, WOR].
Invoice Line Items

Invoice1

Involved party qualifier: bill-to

Value: WAL

Base $50
Accessorial €100
Accessorial $100
Base $50
Accessorial €100
Accessorial $100

Invoice2

Involved party qualifier: bill-to

Value: WOR

Accessorial $50
Accessorial €50
Accessorial $50
Accessorial

Group by String Flex Fields

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Bill to Party Assignment: BPA
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – STRING FLEX FIELDS with field [attribute1]
Result

OTM will generate one invoice for each group of cost lines with same set of string flex field and its value.

In above example, two invoices will be generated:

  1. Invoice with cost lines with string flex field [attribute1, xyz].
  2. Invoice with cost lines with string flex field [attribute1, abc].
Invoices   Line Items

Invoice1

String flex field: attribute1

Value: xyz

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Invoice2

String flex field: attribute1

Value: abc 

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

 

Group by Number Flex Fields

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Bill to Party Assignment: BPA
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – NUMBER FLEX FIELDS with field [attributeNumber1]
Result

OTM will generate one invoice for each group of cost lines with same set of number flex field and its value.

In above example, two invoices will be generated:

  1. Invoice with cost lines with number flex field [attributeNumber1,123].
  2. Invoice with cost lines with number flex field [attributeNumber1,456].
Invoices Line Items

Invoice1

Number flex field: attributeNumber1

Value: 123

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Invoice2

Number flex field: attributeNumber1

Value: 456

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

 

Group by Date Flex Fields
Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Bill to Party Assignment: BPA
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – DATE FLEX FIELDS with field [attributeDate1]
Result

OTM will generate one invoice for each group of cost lines with same set of date flex field and its value.

In above example, two invoices will be generated:

  1. Invoice with cost lines with date flex field [attributeDate1, 10-NOV-2020].
  2. Invoice with cost lines with date flex field [attributeDate1, 10-DEC-2020].
Invoices Line Items

Invoice1

Date flex field: attributeDate1

Value: 10-NOV-2020 

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Invoice2

Date flex field: attributeDate1

Value: 10-DEC-2020 

Base $50
Accessorial $50
Accessorial €50
Accessorial €100
Accessorial $100

Generate Invoice or Bill without using Invoice/Bill Rule

Run the web or the agent action by leaving the input fields (Invoice/Bill Rule ID and Match Rule check box) and planning parameters 'Invoice Split Rule' or 'Bill Split Rule' as blank.

Adjustment of Invoice/Bill

While adjusting invoices or bills you can use the same inputs, i.e. Invoice/Bill Rule ID and Match Rule check box, to identify respective invoices or bills that have already been generated and adjust the amounts accordingly.

Scenarios of adjustment:

  1. Modification on line origin (Shipment/Order release/Order release line/Order base line) for the fields specified in grouping criteria (line grouping constraint set). For example:
    1. If invoices generated using grouping criteria is ‘Invoice line – Involve parties’ i.e. each invoice will be a group of lines with same set of involved parties.
    2. Later, if the contact/party value for that involved party qualifier is changed on line origin (such as order release,) then all cost lines will be adjusted as per grouping criteria.
  2. Updating/deletion/addition of shipment cost.

Note: Whenever shipment costs are modified and the line origin is allocated cost, then you will have to reallocate the shipment costs. This can be performed with the UI action or configured as an automation agent.

The high level steps involved in this process are:

  1. Select adjust invoice or bill web or agent action on shipment.
  2. Invoice/bill rule can be specified in one of the following ways to run adjustment:
    1. Specify an invoice/bill rule ID.
    2. Specify rule in planning parameter ‘Invoice Split Rule’ or ‘Bill Split Rule’.
    3. Use Match Rule check box to look up a rule for shipment.
  3. Steps for identifying adjusted costs:
    1. Fetch the cost lines based on line origin.
    2. Create cost group for all cost lines based on grouping criteria (line grouping constraint set).
    3. Find matching invoice or bill for each cost group based on grouping criteria.
      • If matching invoice or bill is found, the cost lines present on that group will be compared with the existing invoice lines present on the matched invoice. The adjustments are found by comparing each group of cost lines and existing invoice lines. The cost lines and existing invoices lines are grouped by cost type, accessorial code, payment method code and general ledger code. The difference or adjusted lines will be added to the same matched invoice. If it is approved or rejected, then a new invoice or bill for the adjusted lines will be created.
    1. If no matching invoice or bill is found for a cost group, then a new invoice or bill will be generated with all the cost lines present in that cost group.
    2. For invoices or bills which did not match to any cost groups, negative lines for each of the existing invoice or bill lines will be added to the same invoice or bill. If the invoice or bill is approved or rejected then a new invoice or bill will be generated with negative lines.
  4. For adjustment without using an invoice/bill rule, run the web/agent action by leaving the input fields (Invoice/Bill Rule ID and Match Rule check box) and planning parameters ‘Invoice Split Rule’ or ‘Bill Split Rule’ blank.

Example of Adjustment using Invoice/Bill Rule

Shipment S1 with shipment costs

Sequence

Cost Type

Shipment Cost

Accessorial Code

Special Service Code

Payment Method Code

1.

Base

$100

 

 

FCA

2.

Accessorial

$100

Loading

Loading

 

3.

Accessorial

€100

Handling

 

FAS

4.

Accessorial

€200

 

 

 

5.

Accessorial

$200

 

 

 

 

Payment method on Shipment

Payment Method Code: FAS

Invoice/bill rule used to generate invoice/bill

Invoice/Bill Rule Detail
  • Type: Invoice
  • Line origin: Shipment cost
  • Line grouping constraint set:
    • Constraint set type: Invoice line - grouping
    • Constraint type: INVOICE LINE – CURRENCY and INVOICE LINE – PAYMENT METHOD
Result

OTM will generate one invoice for each group of cost lines with same set of currency and payment method.

For above example, four invoices will be generated:

  1. Invoice with 1 cost line (Currency $ , Payment method FCA)
  2. Invoice with 2 cost lines (Currency $ , Payment method - null )
  3. Invoice with 1 cost line (Currency € , Payment method FAS)
  4. Invoice with 1 cost line (Currency € , Payment method - null )
Invoice   Line Items

Invoice1

Payment method: FCA

Base $100

Invoice2

Payment method: Null 

Accessorial $100
Accessorial $200

Invoice3

Payment method: FAS 

Accessorial €100

Invoice4

Payment method: Null 

Accessorial €200

Modify Shipment Cost

 Update base cost to $200, add new base cost €50 and remove one accessorial cost $200.

Sequence

Cost Type

Shipment Cost

Accessorial Code

Special Service Code

Payment Method Code

1.

Base

$200

 

 

FCA

2.

Accessorial

$100

Loading

Loading

 

3.

Accessorial

€100

Handling

 

FAS

4.

Accessorial

€200

 

 

 

5.

Base

€50

 

 

 

 

On running the adjustment web/agent action on the shipment with the same rule

For above example, three invoices will be adjusted :

  1. Invoice1 :  Adjusted with new line of base cost 100$
  2. Invoice2 :  Adjusted with negative amount of removed accessorial (200$)
  3. Invoice4 : Adjusted with new line of base cost(Currency € , Payment method null)
Invoice   Line Items

Invoice1

Payment method: FCA 

Base $100
Base $100

Invoice2

Payment method: null 

Accessorial $100
Accessorial $200
Accessorial -$200

Invoice3

Payment method: FAS 

Accessorial €100

Invoice4

Payment method: null 

Accessorial €200
Base €50

Related Topics