PHP Class Smalot\Magento\Catalog\ProductLink

Inheritance: extends Smalot\Magento\MagentoModuleAbstract
Show file Open project: smalot/magento-client

Public Methods

Method Description
assign ( string $type, string $productId, string $linkedProductId, array $data, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to assign a product link (related, cross-sell, up-sell, or grouped) to another product.
getAttributes ( string $type ) : Smalot\Magento\ActionInterface Allows you to retrieve the product link type attributes.
getList ( string $type, string $productId, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to retrieve the list of linked products for a specific product.
getTypes ( ) : Smalot\Magento\ActionInterface Allows you to retrieve the list of product link types.
remove ( string $type, string $productId, string $linkedProductId, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to remove the product link from a specific product.
update ( string $type, string $productId, string $linkedProductId, array $data, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to update the product link.

Method Details

assign() public method

Allows you to assign a product link (related, cross-sell, up-sell, or grouped) to another product.
public assign ( string $type, string $productId, string $linkedProductId, array $data, string $identifierType = null ) : Smalot\Magento\ActionInterface
$type string
$productId string
$linkedProductId string
$data array
$identifierType string
return Smalot\Magento\ActionInterface

getAttributes() public method

Allows you to retrieve the product link type attributes.
public getAttributes ( string $type ) : Smalot\Magento\ActionInterface
$type string
return Smalot\Magento\ActionInterface

getList() public method

Allows you to retrieve the list of linked products for a specific product.
public getList ( string $type, string $productId, string $identifierType = null ) : Smalot\Magento\ActionInterface
$type string
$productId string
$identifierType string
return Smalot\Magento\ActionInterface

getTypes() public method

Allows you to retrieve the list of product link types.
public getTypes ( ) : Smalot\Magento\ActionInterface
return Smalot\Magento\ActionInterface

remove() public method

Allows you to remove the product link from a specific product.
public remove ( string $type, string $productId, string $linkedProductId, string $identifierType = null ) : Smalot\Magento\ActionInterface
$type string
$productId string
$linkedProductId string
$identifierType string
return Smalot\Magento\ActionInterface

update() public method

Allows you to update the product link.
public update ( string $type, string $productId, string $linkedProductId, array $data, string $identifierType = null ) : Smalot\Magento\ActionInterface
$type string
$productId string
$linkedProductId string
$data array
$identifierType string
return Smalot\Magento\ActionInterface