PHP Class Smalot\Magento\Catalog\ProductMedia

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

Public Methods

Method Description
create ( string $product, array $data, string $storeView = null, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to upload a new product image.
getInfo ( string $productId, string $file, string $storeView = null, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to retrieve information about the specified product image.
getList ( string $productId, string $storeView = null, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to retrieve the list of product images.
getTypes ( string $setId ) : Smalot\Magento\ActionInterface Allows you to retrieve product image types including standard image, small_image, thumbnail, etc.
remove ( string $productId, string $file, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to remove the image from a product.
setCurrentStore ( string $storeView ) : Smalot\Magento\ActionInterface Allows you to set/get the current store view.
update ( string $productId, string $file, array $data, string $storeView = null, string $identifierType = null ) : Smalot\Magento\ActionInterface Allows you to update the product image.

Method Details

create() public method

Allows you to upload a new product image.
public create ( string $product, array $data, string $storeView = null, string $identifierType = null ) : Smalot\Magento\ActionInterface
$product string
$data array
$storeView string
$identifierType string
return Smalot\Magento\ActionInterface

getInfo() public method

Allows you to retrieve information about the specified product image.
public getInfo ( string $productId, string $file, string $storeView = null, string $identifierType = null ) : Smalot\Magento\ActionInterface
$productId string
$file string
$storeView string
$identifierType string
return Smalot\Magento\ActionInterface

getList() public method

Allows you to retrieve the list of product images.
public getList ( string $productId, string $storeView = null, string $identifierType = null ) : Smalot\Magento\ActionInterface
$productId string
$storeView string
$identifierType string
return Smalot\Magento\ActionInterface

getTypes() public method

Note that if the product attribute set contains attributes of the Media Image type (Catalog Input Type for Store Owner > Media Image), it will also be returned in the response.
public getTypes ( string $setId ) : Smalot\Magento\ActionInterface
$setId string
return Smalot\Magento\ActionInterface

remove() public method

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

setCurrentStore() public method

Allows you to set/get the current store view.
public setCurrentStore ( string $storeView ) : Smalot\Magento\ActionInterface
$storeView string
return Smalot\Magento\ActionInterface

update() public method

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