Warning: You are browsing the documentation for PrestaShop 8, which is outdated.

You might want to read an updated version of this page for the current version, PrestaShop 9. Read the updated version of this page

Learn how to update to the latest version.

Hook actionOrderSlipAdd

Informations

Order slip creation This hook is called when a new credit slip is added regarding client order
Hook actionOrderSlipAdd
Locations
BO
Type action
Origin core
Aliases [orderSlip]
Description This hook is called when a new credit slip is added regarding client order

Located in

Origin File
core src/Adapter/Order/Refund/OrderSlipCreator.php

Parameters details

    <?php
    array(
      'order' => Order,
      'productList' => array(
        (int) order detail ID 1 => Order Slip Detail 1,
        (int) order detail ID 2 => Order Slip Detail 2,
        ...,
        (int) order detail ID n => Order Slip Detail n
      ),
      'qtyList' => array(
        (int) order detail ID 1 => (int) quantity 1,
        (int) order detail ID 2 => (int) quantity 2,
        ...,
        (int) order detail ID n => (int) quantity n 
      )
    );

Call of the Hook in the origin file

Hook::exec('actionOrderSlipAdd', [
                'order' => $order,
                'productList' => $orderRefundSummary->getProductRefunds(),
                'qtyList' => $fullQuantityList,
            ], null, false, true, false, $order->id_shop)