/** * Filter the query by a related \App\Propel\User object * * @param \App\Propel\User|ObjectCollection $user The related object(s) to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @throws \Propel\Runtime\Exception\PropelException * * @return ChildSocialRecommendationQuery The current query, for fluid interface */ public function filterByUserRelatedBySocialRecommendationTo($user, $comparison = null) { if ($user instanceof \App\Propel\User) { return $this->addUsingAlias(SocialRecommendationTableMap::COL_SOCIAL_RECOMMENDATION_TO, $user->getUserId(), $comparison); } elseif ($user instanceof ObjectCollection) { if (null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(SocialRecommendationTableMap::COL_SOCIAL_RECOMMENDATION_TO, $user->toKeyValue('PrimaryKey', 'UserId'), $comparison); } else { throw new PropelException('filterByUserRelatedBySocialRecommendationTo() only accepts arguments of type \\App\\Propel\\User or Collection'); } }
/** * Filter the query by a related \App\Propel\User object * * @param \App\Propel\User|ObjectCollection $user The related object(s) to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @throws \Propel\Runtime\Exception\PropelException * * @return ChildWishlistQuery The current query, for fluid interface */ public function filterByUser($user, $comparison = null) { if ($user instanceof \App\Propel\User) { return $this->addUsingAlias(WishlistTableMap::COL_USER_ID, $user->getUserId(), $comparison); } elseif ($user instanceof ObjectCollection) { if (null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(WishlistTableMap::COL_USER_ID, $user->toKeyValue('PrimaryKey', 'UserId'), $comparison); } else { throw new PropelException('filterByUser() only accepts arguments of type \\App\\Propel\\User or Collection'); } }