Properties

$id_order_detail

$id_order_detail : integer

Type

integer

$id_order

$id_order : integer

Type

integer

$id_order_invoice

$id_order_invoice : integer

Type

integer

$product_id

$product_id : integer

Type

integer

$id_shop

$id_shop : integer

Type

integer

$product_attribute_id

$product_attribute_id : integer

Type

integer

$product_name

$product_name : string

Type

string

$product_quantity

$product_quantity : integer

Type

integer

$product_quantity_in_stock

$product_quantity_in_stock : integer

Type

integer

$product_quantity_return

$product_quantity_return : integer

Type

integer

$product_quantity_refunded

$product_quantity_refunded : integer

Type

integer

$product_quantity_reinjected

$product_quantity_reinjected : integer

Type

integer

$product_price

$product_price : float

Type

float

$original_product_price

$original_product_price : float

Type

float

$unit_price_tax_incl

$unit_price_tax_incl : float

Type

float

$unit_price_tax_excl

$unit_price_tax_excl : float

Type

float

$total_price_tax_incl

$total_price_tax_incl : float

Type

float

$total_price_tax_excl

$total_price_tax_excl : float

Type

float

$reduction_percent

$reduction_percent : float

Type

float

$reduction_amount

$reduction_amount : float

Type

float

$reduction_amount_tax_excl

$reduction_amount_tax_excl : float

Type

float

$reduction_amount_tax_incl

$reduction_amount_tax_incl : float

Type

float

$group_reduction

$group_reduction : float

Type

float

$product_quantity_discount

$product_quantity_discount : float

Type

float

$product_ean13

$product_ean13 : string

Type

string

$product_upc

$product_upc : string

Type

string

$product_reference

$product_reference : string

Type

string

$product_supplier_reference

$product_supplier_reference : string

Type

string

$product_weight

$product_weight : float

Type

float

$ecotax

$ecotax : float

Type

float

$ecotax_tax_rate

$ecotax_tax_rate : float

Type

float

$discount_quantity_applied

$discount_quantity_applied : integer

Type

integer

$download_hash

$download_hash : string

Type

string

$download_nb

$download_nb : integer

Type

integer

$download_deadline

$download_deadline : \date

Type

\date

$tax_name

$tax_name : string

Type

string — *

$tax_rate

$tax_rate : float

Type

float — *

$tax_computation_method

$tax_computation_method : float

Type

float — *

$id_tax_rules_group

$id_tax_rules_group : integer

Type

integer — Id tax rules group

$id_warehouse

$id_warehouse : integer

Type

integer — Id warehouse

$total_shipping_price_tax_excl

$total_shipping_price_tax_excl : float

Type

float — additional shipping price tax excl

$total_shipping_price_tax_incl

$total_shipping_price_tax_incl : float

Type

float — additional shipping price tax incl

$purchase_supplier_price

$purchase_supplier_price : float

Type

float

$definition

$definition : 

Type

$webserviceParameters

$webserviceParameters : 

Type

$outOfStock

$outOfStock : boolean

Type

boolean

$tax_calculator

$tax_calculator : \TaxCalculator

Type

\TaxCalculator — object

$vat_address

$vat_address : \Address

Type

\Address — object

$specificPrice

$specificPrice : \Address

Type

\Address — object

$customer

$customer : \Customer

Type

\Customer — object

$context

$context : \Context

Type

\Context — object

Methods

__construct()

__construct(  $id = null,   $id_lang = null,   $context = null) 

Parameters

$id
$id_lang
$context

delete()

delete() 

getDownloadFromHash()

getDownloadFromHash(  $hash) 

Parameters

$hash

incrementDownload()

incrementDownload(  $id_order_detail,   $increment = 1) 

Parameters

$id_order_detail
$increment

getTaxCalculator()

getTaxCalculator() : \TaxCalculator

Returns the tax calculator associated to this order detail.

Returns

\TaxCalculator

getTaxCalculatorStatic()

getTaxCalculatorStatic(integer  $id_order_detail) : \TaxCalculator

Return the tax calculator associated to this order_detail

Parameters

integer $id_order_detail

Returns

\TaxCalculator

saveTaxCalculator()

saveTaxCalculator(\Order  $order,   $replace = false) : boolean

Save the tax calculator

Parameters

\Order $order
$replace

Returns

boolean

updateTaxAmount()

updateTaxAmount(  $order) 

Parameters

$order

getList()

getList(integer  $id_order) : array

Get a detailed order list of an id_order

Parameters

integer $id_order

Returns

array

createList()

createList(object  $order, object  $cart,   $id_order_state,   $product_list, integer  $id_order_invoice, boolean  $use_taxes = true,   $id_warehouse) 

Create a list of order detail for a specified id_order using cart

Parameters

object $order
object $cart
$id_order_state
$product_list
integer $id_order_invoice
boolean $use_taxes

set to false if you don't want to use taxes

$id_warehouse

getStockState()

getStockState() : array

Get the state of the current stock product

Returns

array

setShippingCost()

setShippingCost(\Order  $order,   $product) 

Set the additional shipping information

Parameters

\Order $order
$product

getWsTaxes()

getWsTaxes() 

getCrossSells()

getCrossSells(  $id_product,   $id_lang,   $limit = 12) 

Parameters

$id_product
$id_lang
$limit

add()

add(  $autodate = true,   $null_values = false) 

Parameters

$autodate
$null_values

setContext()

setContext(  $id_shop) 

Parameters

$id_shop

setVirtualProductInformation()

setVirtualProductInformation(  $product) 

Parameters

$product

checkProductStock()

checkProductStock(array  $product, integer  $id_order_state) 

Check the order status

Parameters

array $product
integer $id_order_state

setProductTax()

setProductTax(object  $order, array  $product) 

Apply tax to the product

Parameters

object $order
array $product

setSpecificPrice()

setSpecificPrice(object  $order,   $product = null) 

Set specific price of the product

Parameters

object $order
$product

setDetailProductPrice()

setDetailProductPrice(object  $order, object  $cart, array  $product) 

Set detailed product price to the order detail

Parameters

object $order
object $cart
array $product

create()

create(object  $order, object  $cart, array  $product,   $id_order_state, integer  $id_order_invoice, boolean  $use_taxes = true,   $id_warehouse) 

Create an order detail liable to an id_order

Parameters

object $order
object $cart
array $product
$id_order_state
integer $id_order_invoice
boolean $use_taxes

set to false if you don't want to use taxes

$id_warehouse