/** * Find common attributes * Common attributes are: * - not unique (and not identifier) * - without value AND link to family * - with value * * @param array $productIds * * @return \Pim\Bundle\CatalogBundle\Model\AbstractAttribute[] */ public function findCommonAttributes(array $productIds) { $attributeIds = $this->massActionRepository->findCommonAttributeIds($productIds); return $this->attributeRepository->findWithGroups(array_unique($attributeIds), array('conditions' => ['unique' => 0])); }