t('Decrement stock of products on the order with tracking activated.'), 'group' => t('Stock'), 'base' => 'uc_stock_action_decrement_stock', 'parameter' => array( 'order' => array( 'type' => 'uc_order', 'label' => t('Order'), ), ), ); return $actions; } /** * Decreases the stock of ordered products. */ function uc_stock_action_decrement_stock($order) { if (is_array($order->products)) { array_walk($order->products, 'uc_stock_adjust_product_stock', $order); } }