code: protected function assignSaleItemRecursively(SaleItemInterface $item)
      {
          $this->stockAssigner->assignSaleItem($item);
  
          foreach ($item->getChildren() as $child) {
              $this->assignSaleItemRecursively($child);
          }
      }
docs: Assigns the sale item to stock units recursively.
  
  @param SaleItemInterface $item