PHP Class Sylius\Bundle\ProductBundle\Form\DataTransformer\ProductsToProductAssociationsTransformer

Author: Grzegorz Sadowski ([email protected])
Inheritance: implements Symfony\Component\Form\DataTransformerInterface
ファイルを表示 Open project: sylius/sylius

Protected Properties

Property Type Description
$productAssociationFactory Sylius\Component\Resource\Factory\FactoryInterface
$productAssociationTypeRepository Sylius\Component\Resource\Repository\RepositoryInterface
$productRepository Sylius\Component\Product\Repository\ProductRepositoryInterface

Public Methods

Method Description
__construct ( Sylius\Component\Resource\Factory\FactoryInterface $productAssociationFactory, Sylius\Component\Product\Repository\ProductRepositoryInterface $productRepository, Sylius\Component\Resource\Repository\RepositoryInterface $productAssociationTypeRepository )
reverseTransform ( $values )
transform ( $productAssociations )

Private Methods

Method Description
getIdsAsStringFromProducts ( Doctrine\Common\Collections\Collection $products ) : string
getProductAssociationByTypeCode ( string $productAssociationTypeCode ) : Sylius\Component\Product\Model\ProductAssociationInterface
setAssociatedProductsByProductIds ( Sylius\Component\Product\Model\ProductAssociationInterface $productAssociation, string $productIds )
setProductAssociations ( Doctrine\Common\Collections\Collection | null $productAssociations )

Method Details

__construct() public method

public __construct ( Sylius\Component\Resource\Factory\FactoryInterface $productAssociationFactory, Sylius\Component\Product\Repository\ProductRepositoryInterface $productRepository, Sylius\Component\Resource\Repository\RepositoryInterface $productAssociationTypeRepository )
$productAssociationFactory Sylius\Component\Resource\Factory\FactoryInterface
$productRepository Sylius\Component\Product\Repository\ProductRepositoryInterface
$productAssociationTypeRepository Sylius\Component\Resource\Repository\RepositoryInterface

reverseTransform() public method

public reverseTransform ( $values )

transform() public method

public transform ( $productAssociations )

Property Details

$productAssociationFactory protected_oe property

protected FactoryInterface,Sylius\Component\Resource\Factory $productAssociationFactory
return Sylius\Component\Resource\Factory\FactoryInterface

$productAssociationTypeRepository protected_oe property

protected RepositoryInterface,Sylius\Component\Resource\Repository $productAssociationTypeRepository
return Sylius\Component\Resource\Repository\RepositoryInterface

$productRepository protected_oe property

protected ProductRepositoryInterface,Sylius\Component\Product\Repository $productRepository
return Sylius\Component\Product\Repository\ProductRepositoryInterface