Linked extends Product
in package
Uses ElementTrait

This is the Linked row class.

the Linked rows will be stored in that class and will remain immutable (only get methods are available)

Tags
see
Product
see
ElementTrait

Table of Contents

$backorder  : string
$brandName  : string
$codes  : ProductCodes|null
$customTags  : array<string|int, mixed>
$discounts  : array<string|int, mixed>
$error  : Error|null
$hash  : string
$id Autonumeric element id.  : int
$image  : string
$itemId  : int
$link  : string
$linkedParentId  : int
$name  : string
$noReturn  : bool
$offer  : bool
$onRequest  : bool
$onRequestAffected  : bool
$onRequestDays  : int
$options  : array<string|int, mixed>
$prices  : DocumentRowPrices|null
$quantity  : int
$reserve  : bool
$reverseChargeVat  : bool
$stockManagement  : bool
$stocks  : array<string|int, mixed>
$taxes  : array<string|int, mixed>
$type  : string
$weight  : float
__construct() Elements constructor.  : mixed
__toString() Uses "json_encode" function to return the JSON format of the element.  : string
getBackorder() Returns the product row backorder mode.  : string
getBrandName() Returns the basket item brand name for the website current language.  : string
getCodes() Returns the product row codes.  : ProductCodes|null
getCustomTags() Returns the product row customTags.  : array<string|int, DocumentRowCustomTag>
getDiscounts() Returns the product row discounts.  : array<string|int, DocumentRowDiscount>
getError() Returns the current element error (if there is error).  : Error|null
getHash() Returns the document row hash.  : string
getId() Returns the element id.  : int
getImage() Returns the product row image.  : string
getItemId() Returns the document row product internal identifier.  : int
getLink() Returns the product row link.  : string
getLinkedParentId() Returns the linked parent id.  : int
getName() Returns the element name on the website current language.  : string
getNoReturn() Returns the product row no return.  : bool
getOffer() Returns if the product row was buyed as an offer.  : bool
getOnRequest() Returns the product row on request.  : bool
getOnRequestAffected() Returns the document row on request affected.  : bool
getOnRequestDays() Returns the product row on request days.  : int
getOptions() Returns the product row options.  : array<string|int, DocumentRowOption>
getPrices() Returns the document row prices.  : DocumentRowPrices|null
getQuantity() Returns the document row quantity.  : int
getReserve() Returns the document row reserve.  : bool
getReverseChargeVat() Returns the product row reverse charge vat.  : bool
getStockManagement() Returns if the product row stock management was enabled.  : bool
getStocks() Returns the product row stocks.  : array<string|int, DocumentRowStock>
getTaxes() Returns the document row taxes.  : array<string|int, DocumentRowTax>
getType() Returns the document row type.  : string
getWeight() Returns the product row weight.  : float
jsonSerialize() Allow elements to be serialized.  : array<string|int, mixed>
toArray() Used to allow elements to be serialized.  : array<string|int, mixed>
getFieldItem()  : object|null
getFormattedData()  : mixed
setArrayField() Convert an API array of objects to a PHP array of objects.  : array<string|int, mixed>
setCodes()  : void
setCustomTags()  : void
setDiscounts()  : void
setError()  : void
setOptions()  : void
setPrices()  : void
setStocks()  : void
setTaxes()  : void

Properties

$backorder

protected string $backorder = ''

$brandName

protected string $brandName = ''

$customTags

protected array<string|int, mixed> $customTags = []

$discounts

protected array<string|int, mixed> $discounts = []

$id

Autonumeric element id.

protected int $id = 0

All the given elements by the LogiCommerce API will send it.

$linkedParentId

protected int $linkedParentId = 0

$noReturn

protected bool $noReturn = false

$offer

protected bool $offer = false

$onRequest

protected bool $onRequest = false

$onRequestAffected

protected bool $onRequestAffected = false

$onRequestDays

protected int $onRequestDays = 0

$options

protected array<string|int, mixed> $options = []

$reverseChargeVat

protected bool $reverseChargeVat = false

$stockManagement

protected bool $stockManagement = false

$stocks

protected array<string|int, mixed> $stocks = []

$taxes

protected array<string|int, mixed> $taxes = []

$weight

protected float $weight = 0.0

Methods

__construct()

Elements constructor.

public __construct([array<string|int, mixed> $data = [] ]) : mixed
Parameters
$data : array<string|int, mixed> = []

Array that contains all the values to the object to initialize

Return values
mixed

__toString()

Uses "json_encode" function to return the JSON format of the element.

public __toString() : string

Auto-invoked using echo or concatenations.

Return values
string

getBackorder()

Returns the product row backorder mode.

public getBackorder() : string
Return values
string

getBrandName()

Returns the basket item brand name for the website current language.

public getBrandName() : string
Return values
string

getError()

Returns the current element error (if there is error).

public getError() : Error|null
Return values
Error|null

getHash()

Returns the document row hash.

public getHash() : string
Return values
string

getImage()

Returns the product row image.

public getImage() : string
Return values
string

getItemId()

Returns the document row product internal identifier.

public getItemId() : int
Return values
int

Returns the product row link.

public getLink() : string
Return values
string

getLinkedParentId()

Returns the linked parent id.

public getLinkedParentId() : int
Return values
int

getName()

Returns the element name on the website current language.

public getName() : string
Return values
string

getNoReturn()

Returns the product row no return.

public getNoReturn() : bool
Return values
bool

getOffer()

Returns if the product row was buyed as an offer.

public getOffer() : bool
Return values
bool

getOnRequest()

Returns the product row on request.

public getOnRequest() : bool
Return values
bool

getOnRequestAffected()

Returns the document row on request affected.

public getOnRequestAffected() : bool
Return values
bool

getOnRequestDays()

Returns the product row on request days.

public getOnRequestDays() : int
Return values
int

getQuantity()

Returns the document row quantity.

public getQuantity() : int
Return values
int

getReserve()

Returns the document row reserve.

public getReserve() : bool
Return values
bool

getReverseChargeVat()

Returns the product row reverse charge vat.

public getReverseChargeVat() : bool
Return values
bool

getStockManagement()

Returns if the product row stock management was enabled.

public getStockManagement() : bool
Return values
bool

getType()

Returns the document row type.

public getType() : string
Return values
string

getWeight()

Returns the product row weight.

public getWeight() : float
Return values
float

jsonSerialize()

Allow elements to be serialized.

public jsonSerialize() : array<string|int, mixed>

Auto-invoked using "json_encode" function.

Return values
array<string|int, mixed>

toArray()

Used to allow elements to be serialized.

public toArray() : array<string|int, mixed>
Return values
array<string|int, mixed>

getFieldItem()

protected getFieldItem(array<string|int, mixed> $item, string $class) : object|null
Parameters
$item : array<string|int, mixed>
$class : string
Return values
object|null

getFormattedData()

protected getFormattedData(mixed $value) : mixed
Parameters
$value : mixed
Return values
mixed

setArrayField()

Convert an API array of objects to a PHP array of objects.

protected setArrayField(array<string|int, mixed> $data, string $class) : array<string|int, mixed>
Parameters
$data : array<string|int, mixed>

Array that contains all the values to the objects to initialize

$class : string

The PHP class we want the objects to be

Return values
array<string|int, mixed>

setCodes()

protected setCodes(array<string|int, mixed> $codes) : void
Parameters
$codes : array<string|int, mixed>
Return values
void

setCustomTags()

protected setCustomTags(array<string|int, mixed> $customTags) : void
Parameters
$customTags : array<string|int, mixed>
Return values
void

setDiscounts()

protected setDiscounts(array<string|int, mixed> $discounts) : void
Parameters
$discounts : array<string|int, mixed>
Return values
void

setError()

protected setError(mixed $error) : void
Parameters
$error : mixed
Return values
void

setOptions()

protected setOptions(array<string|int, mixed> $options) : void
Parameters
$options : array<string|int, mixed>
Return values
void

setPrices()

protected setPrices(array<string|int, mixed> $prices) : void
Parameters
$prices : array<string|int, mixed>
Return values
void

setStocks()

protected setStocks(array<string|int, mixed> $stocks) : void
Parameters
$stocks : array<string|int, mixed>
Return values
void

setTaxes()

protected setTaxes(array<string|int, mixed> $taxes) : void
Parameters
$taxes : array<string|int, mixed>
Return values
void

Search results