Пример #1
0
 /**
  * Filter the query by a related Empleado object
  *
  * @param   Empleado|PropelObjectCollection $empleado  the related object to use as filter
  * @param     string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @return                 RolQuery The current query, for fluid interface
  * @throws PropelException - if the provided filter is invalid.
  */
 public function filterByEmpleado($empleado, $comparison = null)
 {
     if ($empleado instanceof Empleado) {
         return $this->addUsingAlias(RolPeer::IDROL, $empleado->getIdrol(), $comparison);
     } elseif ($empleado instanceof PropelObjectCollection) {
         return $this->useEmpleadoQuery()->filterByPrimaryKeys($empleado->getPrimaryKeys())->endUse();
     } else {
         throw new PropelException('filterByEmpleado() only accepts arguments of type Empleado or PropelCollection');
     }
 }
 /**
  * Filter the query by a related Empleado object
  *
  * @param     Empleado $empleado  the related object to use as filter
  * @param     string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @return    CiudadQuery The current query, for fluid interface
  */
 public function filterByEmpleadoRelatedByIdProv($empleado, $comparison = null)
 {
     if ($empleado instanceof Empleado) {
         return $this->addUsingAlias(CiudadPeer::ID_PROVINCIA, $empleado->getIdProv(), $comparison);
     } elseif ($empleado instanceof PropelCollection) {
         return $this->useEmpleadoRelatedByIdProvQuery()->filterByPrimaryKeys($empleado->getPrimaryKeys())->endUse();
     } else {
         throw new PropelException('filterByEmpleadoRelatedByIdProv() only accepts arguments of type Empleado or PropelCollection');
     }
 }