CoolCMS API

ProductSetParameterRel extends ProductSetParameterRel
in package

Parameter value on a sellable set, analogous to Bazaar `AdvertParameterRel` but with a surrogate PK (`product_set_parameter_rel_id`) instead of the composite (set, parameter).

Tags
extends
Attributes
#[Entity]
#[Table]
$name: 'cms_mod_eshop_product_set_parameter_rel'
#[TableAlias]
'productSetParameterRel'

Table of Contents

Properties

$id  : int|null
$parameter  : TParameter|null
$parameterId  : int|null
$productSet  : TProductSet|null
$value  : string|null
$value2  : string|null

Methods

__construct()  : mixed
callInitMethods()  : void
Calls `init{TraitName}()` for every used trait that defines such a method.
getAllTraits()  : array<string, string>
Returns all traits the class uses, including those used by parent classes and nested traits.
getId()  : int|null
getParameter()  : TParameter|null
getParameterId()  : int|null
getProductSet()  : TProductSet|null
getValue()  : string|null
getValue2()  : string|null
isPersisted()  : bool
setId()  : $this
setParameter()  : $this
setParameterId()  : $this
setProductSet()  : $this
setValue()  : $this
setValue2()  : $this
getTraitsRecursive()  : array<string, string>
Walks the trait list recursively and collects nested traits too.

Properties

$id

protected int|null $id = null
Attributes
#[Column]
$name: 'product_set_parameter_rel_id'
$type: 'integer'
$options: ['unsigned' => true]
#[GeneratedValue]
#[Id]

$parameter

protected TParameter|null $parameter = null
Attributes
#[JoinColumn]
$name: 'cms_mod_eshop_parameters_parameter_id'
$referencedColumnName: 'parameter_id'
$onDelete: 'CASCADE'
#[ManyToOne]
$targetEntity: \App\UI\Api\Eshop\Models\Entities\Parameter::class
$fetch: 'LAZY'

$parameterId

protected int|null $parameterId = null
Attributes
#[Column]
$name: 'cms_mod_eshop_parameters_parameter_id'
$type: 'integer'
$insertable: false
$updatable: false
$nullable: true

$productSet

protected TProductSet|null $productSet = null
Attributes
#[JoinColumn]
$name: 'cms_mod_eshop_product_sets_product_set_id'
$referencedColumnName: 'product_set_id'
$onDelete: 'CASCADE'
#[ManyToOne]
$targetEntity: \App\UI\Api\Eshop\Models\Entities\ProductSet::class
$inversedBy: 'parameterRels'
$fetch: 'LAZY'

$value

protected string|null $value = null
Attributes
#[Column]
$name: 'value'
$type: 'text'
$nullable: true

$value2

protected string|null $value2 = null
Attributes
#[Column]
$name: 'value2'
$type: 'text'
$nullable: true

Methods

__construct()

public __construct([int|null $id = null ][, mixed $productSet = null ][, mixed $parameter = null ][, string|null $value = null ][, string|null $value2 = null ][, int|null $parameterId = null ]) : mixed
Parameters
$id : int|null = null
$productSet : mixed = null
$parameter : mixed = null
$value : string|null = null
$value2 : string|null = null
$parameterId : int|null = null

callInitMethods()

Calls `init{TraitName}()` for every used trait that defines such a method.

public callInitMethods() : void

getAllTraits()

Returns all traits the class uses, including those used by parent classes and nested traits.

public getAllTraits() : array<string, string>
Return values
array<string, string>

setId()

public setId(int|null $id) : $this
Parameters
$id : int|null
Return values
$this

setParameter()

public setParameter(TParameter|null $parameter) : $this
Parameters
$parameter : TParameter|null
Return values
$this

setParameterId()

public setParameterId(int|null $parameterId) : $this
Parameters
$parameterId : int|null
Return values
$this

setProductSet()

public setProductSet(TProductSet|null $productSet) : $this
Parameters
$productSet : TProductSet|null
Return values
$this

setValue()

public setValue(string|null $value) : $this
Parameters
$value : string|null
Return values
$this

setValue2()

public setValue2(string|null $value2) : $this
Parameters
$value2 : string|null
Return values
$this

getTraitsRecursive()

Walks the trait list recursively and collects nested traits too.

private static getTraitsRecursive(array<string, string> $traits) : array<string, string>
Parameters
$traits : array<string, string>
Return values
array<string, string>
On this page

Search results