Set Default Values for Shipping Methods

You can specify the default value that Order Management uses to set the Shipping Method attribute when the Order Entry Specialist creates a sales order.

Assume you must set the default value for the Shipping Method attribute according to the Sold-to Party attribute.

Here's pseudocode for the rule.

If the Sold-to Party is Computer Service and Rentals, then set the Shipping Method to USPS Air Express.

For details, see Import Shipping Method.

Summary of the Setup

  1. Get values for your attributes.

  2. Create a posttransformation rule.

  3. Test your setup.

Get Values for Your Attributes

  1. Go to the Order Management work area and create a sales order.

    Attribute

    Value

    Customer

    Computer Service and Rentals

  2. On the catalog line, search for, then add the AS54888 item.

  3. Click Shipment Details > General, then set the values.

    Attribute

    Value

    Shipping Method

    USPS Air Express

  4. Click Save, then notice the order number. In this example, assume its 521495.

  5. Do an SQL.

    SELECT SOLD_TO_PARTY_ID ,
    source_order_number ,
    order_number ,
    CARRIER_ID ,
    SHIP_MODE_OF_TRANSPORT,
    SHIP_CLASS_OF_SERVICE
    FROM doo_headers_all
    & ORDER_NUMBER='521495'
    ORDER BY creation_Date DESC;
    

    For details, see Use SQL to Query Order Management Data.

    Assume the query returns these values.

    Attribute

    Value

    SHIP_MODE_OF_TRANSPORT

    119

    SHIP_CLASS_OF_SERVICE

    145

    CARRIER_ID

    43061

    SOLD_TO_PARTY_ID

    300000001469001

Create a Posttransformation Rule

the posttransformation rule uses the Assign actions that you specify to set the Shipping Method attribute to USPS Air Express

At run time, if you create a sales order and set the Customer attribute to Computer Service and Rentals, then the posttransformation rule uses the Assign actions that you specify to set the Shipping Method attribute to USPS Air Express.

Try it.

  1. Open another browser.

    Use two browsers. One for end-user tasks and the other for administrative tasks. This way, you can toggle back and forth during setup and testing.

  2. Go to the Setup and Maintenance work area, then go to the task.

    • Offering: Order Management

    • Functional Area: Orders

    • Task: Manage Posttransformation Defaulting Rules

  3. On the Manage Posttransformation Defaulting Rules page, create a new rule.

  4. In the If area, set the conditions.

    Code

    Description

    Header is a PosttransformationRules.HeaderVO

    Declare the Header variable into the PosttransformationRules dictionary.

    Get values for attributes of the order header that the orchestration process is currently processing from the header virtual object (VO), then store them in the Header variable.

    Header.SoldToPartyId isn't null

    Make sure the value of the SoldToPartyId attribute on the order header contains a value.

    You do this to avoid the null pointer exception.

    Header.SoldToPartyId is 300000001469001

    Make sure the value of the SoldToPartyId attribute on the order header contains the value 300000001469001.

    This value identifies the Computer Service and Rentals customer that you identified when you ran the SQL.

    Note

    • Add a check mark to the Advanced Mode option when you create the rule.

    • Add the two conditions.

    • Add a check mark to the square box on each condition, then, above Header.SoldToPartyId, click Surround, and verify that the rule adds a pair of parentheses ( ) that surrounds the conditions.

      This set up makes sure the rule evaluates the conditions with AND logic. If both conditions evaluate to true, then the rule will assign the values that you specify in the Then section. If you don't add the parentheses, then the rule evaluates the conditions with OR logic, which you don't want.

  5. In the Then area, add three Assign actions.

    Code

    Description

    Header.ShipModeOfTransport = 119

    Set the mode of transport to the value you identified from the SQL query. In this example, 119 means Air.

    Header.ShipClassOfService = 145

    Set the mode of transport to the value you identified from the SQL query. In this example, 145 Express.

    Header.CarrierId = 43061

    Set the mode of transport to the value you identified from the SQL query. In this example, 43061 means USPS.

  6. Click Save > Release.

    For details, see Overview of Using Business Rules With Order Management.

Test Your Setup

  1. Go back to your other browser and create a sales order.

    Attribute

    Value

    Customer

    Computer Service and Rentals

  2. Click Shipment Details > General, then verify that Order Management automatically set the value.

    Attribute

    Value

    Shipping Method

    USPS Air Express

Consider the Request Type

Promising attempts to fulfill the sales order within the requested date or with minimal delay when it promises the order according to the attributes that you set.

If You Set the Request Type Attribute on the Order Line To

Then Promising Tries to Match The

Ship On, or if you set the PromisingType attribute to Ship in a web service payload

Scheduled ship date with the requested ship date.

Promising uses the default shipping method because the method doesn't affect whether Promising can promise the order on time or with minimal delay.

Arrive On, or if you set the PromisingType attribute to Arrival in a web service payload

Scheduled arrival date with the requested arrival date.

If Promising can't meet the requested arrival date or can't promise with minimal delay, then it uses the fastest shipping method.

Note

If you specify the shipping method on the order line, then Promising uses that method.

You must manage the transit time for each shipping method that you create between a source and a destination.

  1. Go to the Setup and Maintenance work area, then go to the task.
    • Offering: Manufacturing and Supply Chain Materials Management
    • Functional Area: Carriers and Transit Times
    • Task: Manage Transit Times
  2. Collect your changes. For details, see Collect Planning Data for Order Management.

For details, see Set Default Values for Shipping Methods. For details about the Global Order Promising web service, go to REST API for Oracle Supply Chain Management Cloud, expand Order Management > Global Order Promising.