コード例 #1
0
 /**
  * Filter the query by a related \SoColissimo\Model\Thelia\Model\OrderAddress object
  *
  * @param \SoColissimo\Model\Thelia\Model\OrderAddress|ObjectCollection $orderAddress The related object(s) to use as filter
  * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @return ChildOrderAddressSocolissimoQuery The current query, for fluid interface
  */
 public function filterByOrderAddress($orderAddress, $comparison = null)
 {
     if ($orderAddress instanceof \SoColissimo\Model\Thelia\Model\OrderAddress) {
         return $this->addUsingAlias(OrderAddressSocolissimoTableMap::ID, $orderAddress->getId(), $comparison);
     } elseif ($orderAddress instanceof ObjectCollection) {
         if (null === $comparison) {
             $comparison = Criteria::IN;
         }
         return $this->addUsingAlias(OrderAddressSocolissimoTableMap::ID, $orderAddress->toKeyValue('PrimaryKey', 'Id'), $comparison);
     } else {
         throw new PropelException('filterByOrderAddress() only accepts arguments of type \\SoColissimo\\Model\\Thelia\\Model\\OrderAddress or Collection');
     }
 }