PHP Class ProductRepository

Inheritance: extends RepositoryBase
Afficher le fichier Open project: yupe/yupe Class Usage Examples

Protected Properties

Свойство Type Description
$attributeFilter

Méthodes publiques

Méthode Description
getByBrandProvider ( Producer $producer ) : CActiveDataProvider Get products by brand
getByFilter ( array $mainSearchAttributes, array $typeSearchAttributes ) : CActiveDataProvider
getById ( $id, array $with = ['producer', 'type.typeAttributes', 'images', 'category', 'variants'] ) : mixed
getByIds ( array $ids ) : CActiveDataProvider
getBySlug ( $slug, array $with = ['producer', 'type.typeAttributes', 'images', 'category', 'variants', 'attributesValues'] ) : mixed
getListForCategory ( StoreCategory $category, boolean $withChild = true, null $limit = null ) : CActiveDataProvider
getListForIndexPage ( ) : CActiveDataProvider
init ( )
search ( $query ) : array
searchByName ( $name ) : array | mixed | null

Méthodes protégées

Méthode Description
buildCriteriaForTypeAttributes ( array $typeSearchAttributes ) : CDbCriteria

Method Details

buildCriteriaForTypeAttributes() protected méthode

protected buildCriteriaForTypeAttributes ( array $typeSearchAttributes ) : CDbCriteria
$typeSearchAttributes array
Résultat CDbCriteria

getByBrandProvider() public méthode

Get products by brand
public getByBrandProvider ( Producer $producer ) : CActiveDataProvider
$producer Producer
Résultat CActiveDataProvider

getByFilter() public méthode

public getByFilter ( array $mainSearchAttributes, array $typeSearchAttributes ) : CActiveDataProvider
$mainSearchAttributes array
$typeSearchAttributes array
Résultat CActiveDataProvider

getById() public méthode

public getById ( $id, array $with = ['producer', 'type.typeAttributes', 'images', 'category', 'variants'] ) : mixed
$id
$with array
Résultat mixed

getByIds() public méthode

public getByIds ( array $ids ) : CActiveDataProvider
$ids array
Résultat CActiveDataProvider

getBySlug() public méthode

public getBySlug ( $slug, array $with = ['producer', 'type.typeAttributes', 'images', 'category', 'variants', 'attributesValues'] ) : mixed
$slug
$with array
Résultat mixed

getListForCategory() public méthode

public getListForCategory ( StoreCategory $category, boolean $withChild = true, null $limit = null ) : CActiveDataProvider
$category StoreCategory
$withChild boolean
$limit null
Résultat CActiveDataProvider

getListForIndexPage() public méthode

public getListForIndexPage ( ) : CActiveDataProvider
Résultat CActiveDataProvider

init() public méthode

public init ( )

searchByName() public méthode

public searchByName ( $name ) : array | mixed | null
$name
Résultat array | mixed | null

Property Details

$attributeFilter protected_oe property

protected $attributeFilter