class CategoryQuery extends CategoryQuery

Skeleton subclass for performing query and update operations on the 'category' table.

You should add additional methods to this class to meet the application requirements. This class will only be generated as long as it does not already exist in the output directory.

Properties

static $isVersioningEnabled Whether the versioning is enabled from  CategoryQuery

Methods

__construct( string $dbName = 'thelia', string $modelName = '\\Thelia\\Model\\Category', string $modelAlias = null)

Initializes internal state of \Thelia\Model\Base\CategoryQuery object.

static  CategoryQuery
create( string $modelAlias = null, Criteria $criteria = null)

Returns a new ChildCategoryQuery object.

Category|array|mixed
findPk( mixed $key, ConnectionInterface $con = null)

Find object by primary key.

ObjectCollection|array|mixed
findPks( array $keys, ConnectionInterface $con = null)

Find objects by primary key $objs = $c->findPks(array(12, 56, 832), $con);

filterByPrimaryKey( mixed $key)

Filter the query by primary key

filterByPrimaryKeys( array $keys)

Filter the query by a list of primary keys

filterById( mixed $id = null, string $comparison = null)

Filter the query on the id column

filterByParent( mixed $parent = null, string $comparison = null)

Filter the query on the parent column

filterByVisible( mixed $visible = null, string $comparison = null)

Filter the query on the visible column

filterByPosition( mixed $position = null, string $comparison = null)

Filter the query on the position column

filterByDefaultTemplateId( mixed $defaultTemplateId = null, string $comparison = null)

Filter the query on the defaulttemplateid column

filterByCreatedAt( mixed $createdAt = null, string $comparison = null)

Filter the query on the created_at column

filterByUpdatedAt( mixed $updatedAt = null, string $comparison = null)

Filter the query on the updated_at column

filterByVersion( mixed $version = null, string $comparison = null)

Filter the query on the version column

filterByVersionCreatedAt( mixed $versionCreatedAt = null, string $comparison = null)

Filter the query on the versioncreatedat column

filterByVersionCreatedBy( string $versionCreatedBy = null, string $comparison = null)

Filter the query on the versioncreatedby column

filterByProductCategory( ProductCategory|ObjectCollection $productCategory, string $comparison = null)

Filter the query by a related \Thelia\Model\ProductCategory object

joinProductCategory( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the ProductCategory relation

useProductCategoryQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the ProductCategory relation ProductCategory object

filterByCategoryImage( CategoryImage|ObjectCollection $categoryImage, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryImage object

joinCategoryImage( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CategoryImage relation

useCategoryImageQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the CategoryImage relation CategoryImage object

filterByCategoryDocument( CategoryDocument|ObjectCollection $categoryDocument, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryDocument object

joinCategoryDocument( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CategoryDocument relation

useCategoryDocumentQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the CategoryDocument relation CategoryDocument object

filterByCategoryAssociatedContent( CategoryAssociatedContent|ObjectCollection $categoryAssociatedContent, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryAssociatedContent object

joinCategoryAssociatedContent( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CategoryAssociatedContent relation

useCategoryAssociatedContentQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the CategoryAssociatedContent relation CategoryAssociatedContent object

filterByCategoryI18n( CategoryI18n|ObjectCollection $categoryI18n, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryI18n object

joinCategoryI18n( string $relationAlias = null, string $joinType = 'LEFT JOIN')

Adds a JOIN clause to the query using the CategoryI18n relation

useCategoryI18nQuery( string $relationAlias = null, string $joinType = 'LEFT JOIN')

Use the CategoryI18n relation CategoryI18n object

filterByCategoryVersion( CategoryVersion|ObjectCollection $categoryVersion, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryVersion object

joinCategoryVersion( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CategoryVersion relation

useCategoryVersionQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the CategoryVersion relation CategoryVersion object

filterByProduct( Product $product, string $comparison = Criteria::EQUAL)

Filter the query by a related Product object using the product_category table as cross reference

prune( Category $category = null)

Exclude object from result

int
doDeleteAll( ConnectionInterface $con = null)

Deletes all rows from the category table.

int
delete( ConnectionInterface $con = null)

Performs a DELETE on the database, given a ChildCategory or Criteria object OR a primary key value.

joinI18n( string $locale = 'en_US', string $relationAlias = null, string $joinType = Criteria::LEFT_JOIN)

Adds a JOIN clause to the query using the i18n relation

joinWithI18n( string $locale = 'en_US', string $joinType = Criteria::LEFT_JOIN)

Adds a JOIN clause to the query and hydrates the related I18n object.

useI18nQuery( string $locale = 'en_US', string $relationAlias = null, string $joinType = Criteria::LEFT_JOIN)

Use the I18n relation query object

static  boolean
isVersioningEnabled()

Checks whether versioning is enabled

static 
enableVersioning()

Enables versioning

static 
disableVersioning()

Disables versioning

recentlyUpdated( int $nbDays = 7)

Filter by the latest updated

recentlyCreated( int $nbDays = 7)

Filter by the latest created

lastUpdatedFirst()

Order by update date desc

firstUpdatedFirst()

Order by update date asc

lastCreatedFirst()

Order by create date desc

firstCreatedFirst()

Order by create date asc

ChildCategoryQuery
orderById($order = Criteria::ASC)

Order by the id column

ChildCategoryQuery
orderByParent($order = Criteria::ASC)

Order by the parent column

ChildCategoryQuery
orderByVisible($order = Criteria::ASC)

Order by the visible column

ChildCategoryQuery
orderByPosition($order = Criteria::ASC)

Order by the position column

ChildCategoryQuery
orderByDefaultTemplateId($order = Criteria::ASC)

Order by the defaulttemplateid column

ChildCategoryQuery
orderByCreatedAt($order = Criteria::ASC)

Order by the created_at column

ChildCategoryQuery
orderByUpdatedAt($order = Criteria::ASC)

Order by the updated_at column

ChildCategoryQuery
orderByVersion($order = Criteria::ASC)

Order by the version column

ChildCategoryQuery
orderByVersionCreatedAt($order = Criteria::ASC)

Order by the versioncreatedat column

ChildCategoryQuery
orderByVersionCreatedBy($order = Criteria::ASC)

Order by the versioncreatedby column

ChildCategoryQuery
groupById()

Group by the id column

ChildCategoryQuery
groupByParent()

Group by the parent column

ChildCategoryQuery
groupByVisible()

Group by the visible column

ChildCategoryQuery
groupByPosition()

Group by the position column

ChildCategoryQuery
groupByDefaultTemplateId()

Group by the defaulttemplateid column

ChildCategoryQuery
groupByCreatedAt()

Group by the created_at column

ChildCategoryQuery
groupByUpdatedAt()

Group by the updated_at column

ChildCategoryQuery
groupByVersion()

Group by the version column

ChildCategoryQuery
groupByVersionCreatedAt()

Group by the versioncreatedat column

ChildCategoryQuery
groupByVersionCreatedBy()

Group by the versioncreatedby column

ChildCategoryQuery
leftJoin($relation)

Adds a LEFT JOIN clause to the query

ChildCategoryQuery
rightJoin($relation)

Adds a RIGHT JOIN clause to the query

ChildCategoryQuery
innerJoin($relation)

Adds a INNER JOIN clause to the query

ChildCategoryQuery
leftJoinProductCategory($relationAlias = null)

Adds a LEFT JOIN clause to the query using the ProductCategory relation

ChildCategoryQuery
rightJoinProductCategory($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the ProductCategory relation

ChildCategoryQuery
innerJoinProductCategory($relationAlias = null)

Adds a INNER JOIN clause to the query using the ProductCategory relation

ChildCategoryQuery
leftJoinCategoryImage($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryImage relation

ChildCategoryQuery
rightJoinCategoryImage($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryImage relation

ChildCategoryQuery
innerJoinCategoryImage($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryImage relation

ChildCategoryQuery
leftJoinCategoryDocument($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryDocument relation

ChildCategoryQuery
rightJoinCategoryDocument($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryDocument relation

ChildCategoryQuery
innerJoinCategoryDocument($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryDocument relation

ChildCategoryQuery
leftJoinCategoryAssociatedContent($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryAssociatedContent relation

ChildCategoryQuery
rightJoinCategoryAssociatedContent($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryAssociatedContent relation

ChildCategoryQuery
innerJoinCategoryAssociatedContent($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryAssociatedContent relation

ChildCategoryQuery
leftJoinCategoryI18n($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryI18n relation

ChildCategoryQuery
rightJoinCategoryI18n($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryI18n relation

ChildCategoryQuery
innerJoinCategoryI18n($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryI18n relation

ChildCategoryQuery
leftJoinCategoryVersion($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryVersion relation

ChildCategoryQuery
rightJoinCategoryVersion($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryVersion relation

ChildCategoryQuery
innerJoinCategoryVersion($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryVersion relation

ChildCategory
findOne( ConnectionInterface $con = null)

Return the first ChildCategory matching the query

ChildCategory
findOneOrCreate( ConnectionInterface $con = null)

Return the first ChildCategory matching the query, or a new ChildCategory object populated from the query conditions when no match is found

ChildCategory
findOneById( int $id)

Return the first ChildCategory filtered by the id column

ChildCategory
findOneByParent( int $parent)

Return the first ChildCategory filtered by the parent column

ChildCategory
findOneByVisible( int $visible)

Return the first ChildCategory filtered by the visible column

ChildCategory
findOneByPosition( int $position)

Return the first ChildCategory filtered by the position column

ChildCategory
findOneByDefaultTemplateId( int $default_template_id)

Return the first ChildCategory filtered by the defaulttemplateid column

ChildCategory
findOneByCreatedAt( string $created_at)

Return the first ChildCategory filtered by the created_at column

ChildCategory
findOneByUpdatedAt( string $updated_at)

Return the first ChildCategory filtered by the updated_at column

ChildCategory
findOneByVersion( int $version)

Return the first ChildCategory filtered by the version column

ChildCategory
findOneByVersionCreatedAt( string $version_created_at)

Return the first ChildCategory filtered by the versioncreatedat column

ChildCategory
findOneByVersionCreatedBy( string $version_created_by)

Return the first ChildCategory filtered by the versioncreatedby column

array
findById( int $id)

Return ChildCategory objects filtered by the id column

array
findByParent( int $parent)

Return ChildCategory objects filtered by the parent column

array
findByVisible( int $visible)

Return ChildCategory objects filtered by the visible column

array
findByPosition( int $position)

Return ChildCategory objects filtered by the position column

array
findByDefaultTemplateId( int $default_template_id)

Return ChildCategory objects filtered by the defaulttemplateid column

array
findByCreatedAt( string $created_at)

Return ChildCategory objects filtered by the created_at column

array
findByUpdatedAt( string $updated_at)

Return ChildCategory objects filtered by the updated_at column

array
findByVersion( int $version)

Return ChildCategory objects filtered by the version column

array
findByVersionCreatedAt( string $version_created_at)

Return ChildCategory objects filtered by the versioncreatedat column

array
findByVersionCreatedBy( string $version_created_by)

Return ChildCategory objects filtered by the versioncreatedby column

static  int
countChild( int $parent)

count how many direct children have a category

static  Category[]
findAllChild($categoryId, int $depth, int $currentPos)

find all category children for a given category. an array of \Thelia\Model\Category is return

static  int[]
getCategoryTreeIds( int|int[] $categoryId, int $depth = 1)

Return all category IDs of a category tree, starting at $categoryId, up to a depth of $depth

static  array
getPathToCategory( integer $categoryId)

Get categories from root to child

Details

in CategoryQuery at line 118
__construct( string $dbName = 'thelia', string $modelName = '\\Thelia\\Model\\Category', string $modelAlias = null)

Initializes internal state of \Thelia\Model\Base\CategoryQuery object.

Parameters

string $dbName The database name
string $modelName The phpName of a model, e.g. 'Book'
string $modelAlias The alias for the model in this query, e.g. 'b'

in CategoryQuery at line 131
static CategoryQuery create( string $modelAlias = null, Criteria $criteria = null)

Returns a new ChildCategoryQuery object.

Parameters

string $modelAlias The alias of a model in the query
Criteria $criteria Optional Criteria to build the query from

Return Value

CategoryQuery

in CategoryQuery at line 161
Category|array|mixed findPk( mixed $key, ConnectionInterface $con = null)

Find object by primary key.

Propel uses the instance pool to skip the database if the object exists. Go fast if the query is untouched.

$obj = $c->findPk(12, $con);

Parameters

mixed $key Primary key to use for the query
ConnectionInterface $con an optional connection object

Return Value

Category|array|mixed the result, formatted by the current formatter

in CategoryQuery at line 243
ObjectCollection|array|mixed findPks( array $keys, ConnectionInterface $con = null)

Find objects by primary key $objs = $c->findPks(array(12, 56, 832), $con);

Parameters

array $keys Primary keys to use for the query
ConnectionInterface $con an optional connection object

Return Value

ObjectCollection|array|mixed the list of results, formatted by the current formatter

in CategoryQuery at line 264
CategoryQuery filterByPrimaryKey( mixed $key)

Filter the query by primary key

Parameters

mixed $key Primary key to use for the query

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 277
CategoryQuery filterByPrimaryKeys( array $keys)

Filter the query by a list of primary keys

Parameters

array $keys The list of primary key to use for the query

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 301
CategoryQuery filterById( mixed $id = null, string $comparison = null)

Filter the query on the id column

Example usage: $query->filterById(1234); // WHERE id = 1234 $query->filterById(array(12, 34)); // WHERE id IN (12, 34) $query->filterById(array('min' => 12)); // WHERE id > 12

Parameters

mixed $id The value to use as filter. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 342
CategoryQuery filterByParent( mixed $parent = null, string $comparison = null)

Filter the query on the parent column

Example usage: $query->filterByParent(1234); // WHERE parent = 1234 $query->filterByParent(array(12, 34)); // WHERE parent IN (12, 34) $query->filterByParent(array('min' => 12)); // WHERE parent > 12

Parameters

mixed $parent The value to use as filter. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 383
CategoryQuery filterByVisible( mixed $visible = null, string $comparison = null)

Filter the query on the visible column

Example usage: $query->filterByVisible(1234); // WHERE visible = 1234 $query->filterByVisible(array(12, 34)); // WHERE visible IN (12, 34) $query->filterByVisible(array('min' => 12)); // WHERE visible > 12

Parameters

mixed $visible The value to use as filter. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 424
CategoryQuery filterByPosition( mixed $position = null, string $comparison = null)

Filter the query on the position column

Example usage: $query->filterByPosition(1234); // WHERE position = 1234 $query->filterByPosition(array(12, 34)); // WHERE position IN (12, 34) $query->filterByPosition(array('min' => 12)); // WHERE position > 12

Parameters

mixed $position The value to use as filter. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 465
CategoryQuery filterByDefaultTemplateId( mixed $defaultTemplateId = null, string $comparison = null)

Filter the query on the defaulttemplateid column

Example usage: $query->filterByDefaultTemplateId(1234); // WHERE defaulttemplateid = 1234 $query->filterByDefaultTemplateId(array(12, 34)); // WHERE defaulttemplateid IN (12, 34) $query->filterByDefaultTemplateId(array('min' => 12)); // WHERE defaulttemplateid > 12

Parameters

mixed $defaultTemplateId The value to use as filter. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 508
CategoryQuery filterByCreatedAt( mixed $createdAt = null, string $comparison = null)

Filter the query on the created_at column

Example usage: $query->filterByCreatedAt('2011-03-14'); // WHERE createdat = '2011-03-14' $query->filterByCreatedAt('now'); // WHERE createdat = '2011-03-14' $query->filterByCreatedAt(array('max' => 'yesterday')); // WHERE created_at > '2011-03-13'

Parameters

mixed $createdAt The value to use as filter. Values can be integers (unix timestamps), DateTime objects, or strings. Empty strings are treated as NULL. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 551
CategoryQuery filterByUpdatedAt( mixed $updatedAt = null, string $comparison = null)

Filter the query on the updated_at column

Example usage: $query->filterByUpdatedAt('2011-03-14'); // WHERE updatedat = '2011-03-14' $query->filterByUpdatedAt('now'); // WHERE updatedat = '2011-03-14' $query->filterByUpdatedAt(array('max' => 'yesterday')); // WHERE updated_at > '2011-03-13'

Parameters

mixed $updatedAt The value to use as filter. Values can be integers (unix timestamps), DateTime objects, or strings. Empty strings are treated as NULL. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 592
CategoryQuery filterByVersion( mixed $version = null, string $comparison = null)

Filter the query on the version column

Example usage: $query->filterByVersion(1234); // WHERE version = 1234 $query->filterByVersion(array(12, 34)); // WHERE version IN (12, 34) $query->filterByVersion(array('min' => 12)); // WHERE version > 12

Parameters

mixed $version The value to use as filter. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 635
CategoryQuery filterByVersionCreatedAt( mixed $versionCreatedAt = null, string $comparison = null)

Filter the query on the versioncreatedat column

Example usage: $query->filterByVersionCreatedAt('2011-03-14'); // WHERE versioncreatedat = '2011-03-14' $query->filterByVersionCreatedAt('now'); // WHERE versioncreatedat = '2011-03-14' $query->filterByVersionCreatedAt(array('max' => 'yesterday')); // WHERE versioncreatedat > '2011-03-13'

Parameters

mixed $versionCreatedAt The value to use as filter. Values can be integers (unix timestamps), DateTime objects, or strings. Empty strings are treated as NULL. Use scalar values for equality. Use array values for in_array() equivalent. Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 673
CategoryQuery filterByVersionCreatedBy( string $versionCreatedBy = null, string $comparison = null)

Filter the query on the versioncreatedby column

Example usage: $query->filterByVersionCreatedBy('fooValue'); // WHERE versioncreatedby = 'fooValue' $query->filterByVersionCreatedBy('%fooValue%'); // WHERE versioncreatedby LIKE '%fooValue%'

Parameters

string $versionCreatedBy The value to use as filter. Accepts wildcards (* and % trigger a LIKE)
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 695
CategoryQuery filterByProductCategory( ProductCategory|ObjectCollection $productCategory, string $comparison = null)

Filter the query by a related \Thelia\Model\ProductCategory object

Parameters

ProductCategory|ObjectCollection $productCategory the related object to use as filter
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 718
CategoryQuery joinProductCategory( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the ProductCategory relation

Parameters

string $relationAlias optional alias for the relation
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 753
ProductCategoryQuery useProductCategoryQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the ProductCategory relation ProductCategory object

Parameters

string $relationAlias optional alias for the relation, to be used as main alias in the secondary query
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

ProductCategoryQuery A secondary query class using the current class as primary query

See also

useQuery()

in CategoryQuery at line 768
CategoryQuery filterByCategoryImage( CategoryImage|ObjectCollection $categoryImage, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryImage object

Parameters

CategoryImage|ObjectCollection $categoryImage the related object to use as filter
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 791
CategoryQuery joinCategoryImage( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CategoryImage relation

Parameters

string $relationAlias optional alias for the relation
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 826
CategoryImageQuery useCategoryImageQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the CategoryImage relation CategoryImage object

Parameters

string $relationAlias optional alias for the relation, to be used as main alias in the secondary query
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryImageQuery A secondary query class using the current class as primary query

See also

useQuery()

in CategoryQuery at line 841
CategoryQuery filterByCategoryDocument( CategoryDocument|ObjectCollection $categoryDocument, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryDocument object

Parameters

CategoryDocument|ObjectCollection $categoryDocument the related object to use as filter
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 864
CategoryQuery joinCategoryDocument( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CategoryDocument relation

Parameters

string $relationAlias optional alias for the relation
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 899
CategoryDocumentQuery useCategoryDocumentQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the CategoryDocument relation CategoryDocument object

Parameters

string $relationAlias optional alias for the relation, to be used as main alias in the secondary query
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryDocumentQuery A secondary query class using the current class as primary query

See also

useQuery()

in CategoryQuery at line 914
CategoryQuery filterByCategoryAssociatedContent( CategoryAssociatedContent|ObjectCollection $categoryAssociatedContent, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryAssociatedContent object

Parameters

CategoryAssociatedContent|ObjectCollection $categoryAssociatedContent the related object to use as filter
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 937
CategoryQuery joinCategoryAssociatedContent( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CategoryAssociatedContent relation

Parameters

string $relationAlias optional alias for the relation
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 972
CategoryAssociatedContentQuery useCategoryAssociatedContentQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the CategoryAssociatedContent relation CategoryAssociatedContent object

Parameters

string $relationAlias optional alias for the relation, to be used as main alias in the secondary query
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryAssociatedContentQuery A secondary query class using the current class as primary query

See also

useQuery()

in CategoryQuery at line 987
CategoryQuery filterByCategoryI18n( CategoryI18n|ObjectCollection $categoryI18n, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryI18n object

Parameters

CategoryI18n|ObjectCollection $categoryI18n the related object to use as filter
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1010
CategoryQuery joinCategoryI18n( string $relationAlias = null, string $joinType = 'LEFT JOIN')

Adds a JOIN clause to the query using the CategoryI18n relation

Parameters

string $relationAlias optional alias for the relation
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1045
CategoryI18nQuery useCategoryI18nQuery( string $relationAlias = null, string $joinType = 'LEFT JOIN')

Use the CategoryI18n relation CategoryI18n object

Parameters

string $relationAlias optional alias for the relation, to be used as main alias in the secondary query
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryI18nQuery A secondary query class using the current class as primary query

See also

useQuery()

in CategoryQuery at line 1060
CategoryQuery filterByCategoryVersion( CategoryVersion|ObjectCollection $categoryVersion, string $comparison = null)

Filter the query by a related \Thelia\Model\CategoryVersion object

Parameters

CategoryVersion|ObjectCollection $categoryVersion the related object to use as filter
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1083
CategoryQuery joinCategoryVersion( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Adds a JOIN clause to the query using the CategoryVersion relation

Parameters

string $relationAlias optional alias for the relation
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1118
CategoryVersionQuery useCategoryVersionQuery( string $relationAlias = null, string $joinType = Criteria::INNER_JOIN)

Use the CategoryVersion relation CategoryVersion object

Parameters

string $relationAlias optional alias for the relation, to be used as main alias in the secondary query
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'

Return Value

CategoryVersionQuery A secondary query class using the current class as primary query

See also

useQuery()

in CategoryQuery at line 1134
CategoryQuery filterByProduct( Product $product, string $comparison = Criteria::EQUAL)

Filter the query by a related Product object using the product_category table as cross reference

Parameters

Product $product the related object to use as filter
string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1149
CategoryQuery prune( Category $category = null)

Exclude object from result

Parameters

Category $category Object to remove from the list of results

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1164
int doDeleteAll( ConnectionInterface $con = null)

Deletes all rows from the category table.

Parameters

ConnectionInterface $con the connection to use

Return Value

int The number of affected rows (if supported by underlying database driver).

in CategoryQuery at line 1201
int delete( ConnectionInterface $con = null)

Performs a DELETE on the database, given a ChildCategory or Criteria object OR a primary key value.

Parameters

ConnectionInterface $con

Return Value

int The number of affected rows (if supported by underlying database driver). This includes CASCADE-related rows if supported by native driver or if emulated using Propel.

Exceptions

PropelException Any exceptions caught during processing will be rethrown wrapped into a PropelException.

in CategoryQuery at line 1244
CategoryQuery joinI18n( string $locale = 'en_US', string $relationAlias = null, string $joinType = Criteria::LEFT_JOIN)

Adds a JOIN clause to the query using the i18n relation

Parameters

string $locale Locale to use for the join condition, e.g. 'fr_FR'
string $relationAlias optional alias for the relation
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'. Defaults to left join.

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1262
CategoryQuery joinWithI18n( string $locale = 'en_US', string $joinType = Criteria::LEFT_JOIN)

Adds a JOIN clause to the query and hydrates the related I18n object.

Shortcut for $c->joinI18n($locale)->with()

Parameters

string $locale Locale to use for the join condition, e.g. 'fr_FR'
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'. Defaults to left join.

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1283
CategoryI18nQuery useI18nQuery( string $locale = 'en_US', string $relationAlias = null, string $joinType = Criteria::LEFT_JOIN)

Use the I18n relation query object

Parameters

string $locale Locale to use for the join condition, e.g. 'fr_FR'
string $relationAlias optional alias for the relation
string $joinType Accepted values are null, 'left join', 'right join', 'inner join'. Defaults to left join.

Return Value

CategoryI18nQuery A secondary query class using the current class as primary query

See also

useQuery()

in CategoryQuery at line 1297
static boolean isVersioningEnabled()

Checks whether versioning is enabled

Return Value

boolean

in CategoryQuery at line 1305
static enableVersioning()

Enables versioning

in CategoryQuery at line 1313
static disableVersioning()

Disables versioning

in CategoryQuery at line 1327
CategoryQuery recentlyUpdated( int $nbDays = 7)

Filter by the latest updated

Parameters

int $nbDays Maximum age of the latest update in days

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1339
CategoryQuery recentlyCreated( int $nbDays = 7)

Filter by the latest created

Parameters

int $nbDays Maximum age of in days

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1349
CategoryQuery lastUpdatedFirst()

Order by update date desc

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1359
CategoryQuery firstUpdatedFirst()

Order by update date asc

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1369
CategoryQuery lastCreatedFirst()

Order by create date desc

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 1379
CategoryQuery firstCreatedFirst()

Order by create date asc

Return Value

CategoryQuery The current query, for fluid interface

in CategoryQuery at line 101
ChildCategoryQuery orderById($order = Criteria::ASC)

Order by the id column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByParent($order = Criteria::ASC)

Order by the parent column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByVisible($order = Criteria::ASC)

Order by the visible column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByPosition($order = Criteria::ASC)

Order by the position column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByDefaultTemplateId($order = Criteria::ASC)

Order by the defaulttemplateid column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByCreatedAt($order = Criteria::ASC)

Order by the created_at column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByUpdatedAt($order = Criteria::ASC)

Order by the updated_at column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByVersion($order = Criteria::ASC)

Order by the version column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByVersionCreatedAt($order = Criteria::ASC)

Order by the versioncreatedat column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery orderByVersionCreatedBy($order = Criteria::ASC)

Order by the versioncreatedby column

Parameters

$order

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupById()

Group by the id column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByParent()

Group by the parent column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByVisible()

Group by the visible column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByPosition()

Group by the position column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByDefaultTemplateId()

Group by the defaulttemplateid column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByCreatedAt()

Group by the created_at column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByUpdatedAt()

Group by the updated_at column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByVersion()

Group by the version column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByVersionCreatedAt()

Group by the versioncreatedat column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery groupByVersionCreatedBy()

Group by the versioncreatedby column

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery leftJoin($relation)

Adds a LEFT JOIN clause to the query

Parameters

$relation

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery rightJoin($relation)

Adds a RIGHT JOIN clause to the query

Parameters

$relation

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery innerJoin($relation)

Adds a INNER JOIN clause to the query

Parameters

$relation

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery leftJoinProductCategory($relationAlias = null)

Adds a LEFT JOIN clause to the query using the ProductCategory relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery rightJoinProductCategory($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the ProductCategory relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery innerJoinProductCategory($relationAlias = null)

Adds a INNER JOIN clause to the query using the ProductCategory relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery leftJoinCategoryImage($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryImage relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery rightJoinCategoryImage($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryImage relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery innerJoinCategoryImage($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryImage relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery leftJoinCategoryDocument($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryDocument relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery rightJoinCategoryDocument($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryDocument relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery innerJoinCategoryDocument($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryDocument relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery leftJoinCategoryAssociatedContent($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryAssociatedContent relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery rightJoinCategoryAssociatedContent($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryAssociatedContent relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery innerJoinCategoryAssociatedContent($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryAssociatedContent relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery leftJoinCategoryI18n($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryI18n relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery rightJoinCategoryI18n($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryI18n relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery innerJoinCategoryI18n($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryI18n relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery leftJoinCategoryVersion($relationAlias = null)

Adds a LEFT JOIN clause to the query using the CategoryVersion relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery rightJoinCategoryVersion($relationAlias = null)

Adds a RIGHT JOIN clause to the query using the CategoryVersion relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategoryQuery innerJoinCategoryVersion($relationAlias = null)

Adds a INNER JOIN clause to the query using the CategoryVersion relation

Parameters

$relationAlias

Return Value

ChildCategoryQuery

in CategoryQuery at line 101
ChildCategory findOne( ConnectionInterface $con = null)

Return the first ChildCategory matching the query

Parameters

ConnectionInterface $con

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneOrCreate( ConnectionInterface $con = null)

Return the first ChildCategory matching the query, or a new ChildCategory object populated from the query conditions when no match is found

Parameters

ConnectionInterface $con

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneById( int $id)

Return the first ChildCategory filtered by the id column

Parameters

int $id

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByParent( int $parent)

Return the first ChildCategory filtered by the parent column

Parameters

int $parent

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByVisible( int $visible)

Return the first ChildCategory filtered by the visible column

Parameters

int $visible

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByPosition( int $position)

Return the first ChildCategory filtered by the position column

Parameters

int $position

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByDefaultTemplateId( int $default_template_id)

Return the first ChildCategory filtered by the defaulttemplateid column

Parameters

int $default_template_id

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByCreatedAt( string $created_at)

Return the first ChildCategory filtered by the created_at column

Parameters

string $created_at

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByUpdatedAt( string $updated_at)

Return the first ChildCategory filtered by the updated_at column

Parameters

string $updated_at

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByVersion( int $version)

Return the first ChildCategory filtered by the version column

Parameters

int $version

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByVersionCreatedAt( string $version_created_at)

Return the first ChildCategory filtered by the versioncreatedat column

Parameters

string $version_created_at

Return Value

ChildCategory

in CategoryQuery at line 101
ChildCategory findOneByVersionCreatedBy( string $version_created_by)

Return the first ChildCategory filtered by the versioncreatedby column

Parameters

string $version_created_by

Return Value

ChildCategory

in CategoryQuery at line 101
array findById( int $id)

Return ChildCategory objects filtered by the id column

Parameters

int $id

Return Value

array

in CategoryQuery at line 101
array findByParent( int $parent)

Return ChildCategory objects filtered by the parent column

Parameters

int $parent

Return Value

array

in CategoryQuery at line 101
array findByVisible( int $visible)

Return ChildCategory objects filtered by the visible column

Parameters

int $visible

Return Value

array

in CategoryQuery at line 101
array findByPosition( int $position)

Return ChildCategory objects filtered by the position column

Parameters

int $position

Return Value

array

in CategoryQuery at line 101
array findByDefaultTemplateId( int $default_template_id)

Return ChildCategory objects filtered by the defaulttemplateid column

Parameters

int $default_template_id

Return Value

array

in CategoryQuery at line 101
array findByCreatedAt( string $created_at)

Return ChildCategory objects filtered by the created_at column

Parameters

string $created_at

Return Value

array

in CategoryQuery at line 101
array findByUpdatedAt( string $updated_at)

Return ChildCategory objects filtered by the updated_at column

Parameters

string $updated_at

Return Value

array

in CategoryQuery at line 101
array findByVersion( int $version)

Return ChildCategory objects filtered by the version column

Parameters

int $version

Return Value

array

in CategoryQuery at line 101
array findByVersionCreatedAt( string $version_created_at)

Return ChildCategory objects filtered by the versioncreatedat column

Parameters

string $version_created_at

Return Value

array

in CategoryQuery at line 101
array findByVersionCreatedBy( string $version_created_by)

Return ChildCategory objects filtered by the versioncreatedby column

Parameters

string $version_created_by

Return Value

array

at line 27
static int countChild( int $parent)

count how many direct children have a category

Parameters

int $parent category parent id

Return Value

int

at line 41
static Category[] findAllChild($categoryId, int $depth, int $currentPos)

find all category children for a given category. an array of \Thelia\Model\Category is return

Parameters

$categoryId the category id or an array of id
int $depth max depth you want to search
int $currentPos don't change this param, it is used for recursion

Return Value

Category[]

at line 77
static int[] getCategoryTreeIds( int|int[] $categoryId, int $depth = 1)

Return all category IDs of a category tree, starting at $categoryId, up to a depth of $depth

Parameters

int|int[] $categoryId the category id or an array of category ids
int $depth max tree traversal depth

Return Value

int[]

at line 108
static array getPathToCategory( integer $categoryId)

Get categories from root to child

Parameters

integer $categoryId Category ID

Return Value

array An array of \Thelia\Model\Category from root to wanted category or an empty array if Category ID doesn't exists