2645:
2646:
2647:
2648: --Find out the legal entity where this SO is created
2649: l_so_le_id := INV_MGD_MVT_UTILS_PKG.Get_SO_Legal_Entity
2650: (p_order_line_id => l_movement_transaction.order_line_id);
2651:
2652: --Find out the legal entity where this SO is shipped
2653: l_shipping_le_id := INV_MGD_MVT_UTILS_PKG.Get_Shipping_Legal_Entity
2649: l_so_le_id := INV_MGD_MVT_UTILS_PKG.Get_SO_Legal_Entity
2650: (p_order_line_id => l_movement_transaction.order_line_id);
2651:
2652: --Find out the legal entity where this SO is shipped
2653: l_shipping_le_id := INV_MGD_MVT_UTILS_PKG.Get_Shipping_Legal_Entity
2654: (p_warehouse_id => l_movement_transaction.organization_id);
2655:
2656: --Check if this order line is of CTO item
2657: OPEN l_cto;