ShashankInamdar
ServiceNow Employee
ServiceNow Employee

This article gives a tip on closing domain orders if there is no orchestration plan attached to it.

 

Feature: Closing Domain Orders 

Application: Order Management 

Release: All applicable 

 

DYK (Did You Know) is a series of articles that introduces simple and basic concepts of the working of ServiceNow TMT Applications. 

 

 

On receipt and approval of an Order, ServiceNow OMT decomposes the order and creates Domain Orders corresponding to each decomposed domain entity – i.e., Product, Service, Resource – subject to the Catalog model.

 

Against every domain order one may invoke a Subflow for orchestration activities related to that specification. But often, there are such specifications which are only for representation or to create an inventory record but without any specific orchestration activity.

 

It is a good practice to close all the domain orders and, in a bottom-up fashion.

For such domain orders that do not have a specific orchestration plan, this article describes a best practice on closing it with a generic Subflow.

 

The pseudo logic is very simple –

Set the Domain Order in an ‘In Progress’ state.

Look Up for Records in the Domain Order table where the current order is a parent.

For each record found,

       Wait until it is closed.

Set the Domain Order in an ‘Closed Complete’ state.

 

Doing so will avoid any unnecessary system generated fallouts and close the line items and order cleanly.

 

The below is an example of a Subflow set up for a Service Order. The same principal follows for the Product or Resource Domain Order as well.

 

 

Create input for Service Order

 

Select reference.sn_ind_tmt_orm_service_order

 

ShashankInamdar_0-1701960959121.png

 

 

Set State to In Progress and Look up for Child Domain Order records

 

ShashankInamdar_1-1701960959129.png

 

 

Wait for each Child Order (if any) to complete

 

ShashankInamdar_2-1701960959136.png

 

Comments
vijaymusipatla
Tera Contributor

Hi,

how do we know which subflow is invoked for a particular Product's - Domain order creation?

ShashankInamdar
ServiceNow Employee
ServiceNow Employee

Hi @vijaymusipatla , on the Domain Order tables for Product/Service/Resource Orders there is a field 'Flow Context' which indicates the Subflow that was associated with the Domain Order.

vijaymusipatla
Tera Contributor

Awesome, thanks for the details.

Version history
Last update:
‎12-07-2023 07:00 AM
Updated by:
Contributors