PHP Интерфейс Sonata\Component\Product\ProductManagerInterface

Наследование: extends Sonata\CoreBundle\Model\ManagerInterface, extends Sonata\CoreBundle\Model\PageableManagerInterface
Показать файл Открыть проект Примеры использования интерфейса

Открытые методы

Метод Описание
findEnabledFromIdAndSlug ( integer $id, string $slug ) : Sonata\Component\Product\ProductInterface | null Retrieve an active product from its id and its slug.
findInSameCollections ( mixed $productCollections ) : array Returns the products in the same collections as those specified in $productCollections.
findParentsInSameCollections ( mixed $productCollections ) : array Returns the parent products in the same collections as those specified in $productCollections.
findVariations ( Sonata\Component\Product\ProductInterface $product ) : array
updateStock ( Sonata\Component\Product\ProductInterface | integer $product, integer $diff ) Updated stock value for a given Product.

Описание методов

findEnabledFromIdAndSlug() публичный Метод

Retrieve an active product from its id and its slug.
public findEnabledFromIdAndSlug ( integer $id, string $slug ) : Sonata\Component\Product\ProductInterface | null
$id integer
$slug string
Результат Sonata\Component\Product\ProductInterface | null

findInSameCollections() публичный Метод

Returns the products in the same collections as those specified in $productCollections.
public findInSameCollections ( mixed $productCollections ) : array
$productCollections mixed
Результат array

findParentsInSameCollections() публичный Метод

Returns the parent products in the same collections as those specified in $productCollections.
public findParentsInSameCollections ( mixed $productCollections ) : array
$productCollections mixed
Результат array

findVariations() публичный Метод

public findVariations ( Sonata\Component\Product\ProductInterface $product ) : array
$product Sonata\Component\Product\ProductInterface
Результат array

updateStock() публичный Метод

Updated stock value for a given Product.
public updateStock ( Sonata\Component\Product\ProductInterface | integer $product, integer $diff )
$product Sonata\Component\Product\ProductInterface | integer
$diff integer