Exemplo n.º 1
0
	/**
	 * Filter the query by a related EdtCreneau object
	 *
	 * @param     EdtCreneau|PropelCollection $edtCreneau The related object(s) to use as filter
	 * @param     string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
	 *
	 * @return    AbsenceEleveSaisieQuery The current query, for fluid interface
	 */
	public function filterByEdtCreneau($edtCreneau, $comparison = null)
	{
		if ($edtCreneau instanceof EdtCreneau) {
			return $this
				->addUsingAlias(AbsenceEleveSaisiePeer::ID_EDT_CRENEAU, $edtCreneau->getIdDefiniePeriode(), $comparison);
		} elseif ($edtCreneau instanceof PropelCollection) {
			if (null === $comparison) {
				$comparison = Criteria::IN;
			}
			return $this
				->addUsingAlias(AbsenceEleveSaisiePeer::ID_EDT_CRENEAU, $edtCreneau->toKeyValue('PrimaryKey', 'IdDefiniePeriode'), $comparison);
		} else {
			throw new PropelException('filterByEdtCreneau() only accepts arguments of type EdtCreneau or PropelCollection');
		}
	}