setModelAlias($modelAlias); } if ($criteria instanceof Criteria) { $query->mergeWith($criteria); } return $query; } /** * Find object by primary key * Use instance pooling to avoid a database query if the object exists * * $obj = $c->findPk(12, $con); * * @param mixed $key Primary key to use for the query * @param PropelPDO $con an optional connection object * * @return Lohnprofil|array|mixed the result, formatted by the current formatter */ public function findPk($key, $con = null) { if ((null !== ($obj = LohnprofilPeer::getInstanceFromPool((string) $key))) && $this->getFormatter()->isObjectFormatter()) { // the object is alredy in the instance pool return $obj; } else { // the object has not been requested yet, or the formatter is not an object formatter $criteria = $this->isKeepQuery() ? clone $this : $this; $stmt = $criteria ->filterByPrimaryKey($key) ->getSelectStatement($con); return $criteria->getFormatter()->init($criteria)->formatOne($stmt); } } /** * Find objects by primary key * * $objs = $c->findPks(array(12, 56, 832), $con); * * @param array $keys Primary keys to use for the query * @param PropelPDO $con an optional connection object * * @return PropelObjectCollection|array|mixed the list of results, formatted by the current formatter */ public function findPks($keys, $con = null) { $criteria = $this->isKeepQuery() ? clone $this : $this; return $this ->filterByPrimaryKeys($keys) ->find($con); } /** * Filter the query by primary key * * @param mixed $key Primary key to use for the query * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByPrimaryKey($key) { return $this->addUsingAlias(LohnprofilPeer::ID, $key, Criteria::EQUAL); } /** * Filter the query by a list of primary keys * * @param array $keys The list of primary key to use for the query * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByPrimaryKeys($keys) { return $this->addUsingAlias(LohnprofilPeer::ID, $keys, Criteria::IN); } /** * Filter the query on the id column * * @param int|array $id The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterById($id = null, $comparison = null) { if (is_array($id) && null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(LohnprofilPeer::ID, $id, $comparison); } /** * Filter the query on the mod column * * @param int|array $mod The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByMod($mod = null, $comparison = null) { if (is_array($mod)) { $useMinMax = false; if (isset($mod['min'])) { $this->addUsingAlias(LohnprofilPeer::MOD, $mod['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($mod['max'])) { $this->addUsingAlias(LohnprofilPeer::MOD, $mod['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::MOD, $mod, $comparison); } /** * Filter the query on the name column * * @param string $name The value to use as filter. * Accepts wildcards (* and % trigger a LIKE) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByName($name = null, $comparison = null) { if (null === $comparison) { if (is_array($name)) { $comparison = Criteria::IN; } elseif (preg_match('/[\%\*]/', $name)) { $name = str_replace('*', '%', $name); $comparison = Criteria::LIKE; } } return $this->addUsingAlias(LohnprofilPeer::NAME, $name, $comparison); } /** * Filter the query on the periode column * * @param int|array $periode The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByPeriode($periode = null, $comparison = null) { if (is_array($periode)) { $useMinMax = false; if (isset($periode['min'])) { $this->addUsingAlias(LohnprofilPeer::PERIODE, $periode['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($periode['max'])) { $this->addUsingAlias(LohnprofilPeer::PERIODE, $periode['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::PERIODE, $periode, $comparison); } /** * Filter the query on the lohnsteuer column * * @param boolean|string $lohnsteuer The value to use as filter. * Accepts strings ('false', 'off', '-', 'no', 'n', and '0' are false, the rest is true) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByLohnsteuer($lohnsteuer = null, $comparison = null) { if (is_string($lohnsteuer)) { $lohnsteuer = in_array(strtolower($lohnsteuer), array('false', 'off', '-', 'no', 'n', '0')) ? false : true; } return $this->addUsingAlias(LohnprofilPeer::LOHNSTEUER, $lohnsteuer, $comparison); } /** * Filter the query on the kirchensteuer_rk column * * @param boolean|string $kirchensteuerRk The value to use as filter. * Accepts strings ('false', 'off', '-', 'no', 'n', and '0' are false, the rest is true) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByKirchensteuerRk($kirchensteuerRk = null, $comparison = null) { if (is_string($kirchensteuerRk)) { $kirchensteuer_rk = in_array(strtolower($kirchensteuerRk), array('false', 'off', '-', 'no', 'n', '0')) ? false : true; } return $this->addUsingAlias(LohnprofilPeer::KIRCHENSTEUER_RK, $kirchensteuerRk, $comparison); } /** * Filter the query on the kirchensteuer_ev column * * @param boolean|string $kirchensteuerEv The value to use as filter. * Accepts strings ('false', 'off', '-', 'no', 'n', and '0' are false, the rest is true) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByKirchensteuerEv($kirchensteuerEv = null, $comparison = null) { if (is_string($kirchensteuerEv)) { $kirchensteuer_ev = in_array(strtolower($kirchensteuerEv), array('false', 'off', '-', 'no', 'n', '0')) ? false : true; } return $this->addUsingAlias(LohnprofilPeer::KIRCHENSTEUER_EV, $kirchensteuerEv, $comparison); } /** * Filter the query on the soli column * * @param boolean|string $soli The value to use as filter. * Accepts strings ('false', 'off', '-', 'no', 'n', and '0' are false, the rest is true) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterBySoli($soli = null, $comparison = null) { if (is_string($soli)) { $soli = in_array(strtolower($soli), array('false', 'off', '-', 'no', 'n', '0')) ? false : true; } return $this->addUsingAlias(LohnprofilPeer::SOLI, $soli, $comparison); } /** * Filter the query on the rentenversicherung_an column * * @param double|array $rentenversicherungAn The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByRentenversicherungAn($rentenversicherungAn = null, $comparison = null) { if (is_array($rentenversicherungAn)) { $useMinMax = false; if (isset($rentenversicherungAn['min'])) { $this->addUsingAlias(LohnprofilPeer::RENTENVERSICHERUNG_AN, $rentenversicherungAn['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($rentenversicherungAn['max'])) { $this->addUsingAlias(LohnprofilPeer::RENTENVERSICHERUNG_AN, $rentenversicherungAn['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::RENTENVERSICHERUNG_AN, $rentenversicherungAn, $comparison); } /** * Filter the query on the rentenversicherung_ag column * * @param double|array $rentenversicherungAg The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByRentenversicherungAg($rentenversicherungAg = null, $comparison = null) { if (is_array($rentenversicherungAg)) { $useMinMax = false; if (isset($rentenversicherungAg['min'])) { $this->addUsingAlias(LohnprofilPeer::RENTENVERSICHERUNG_AG, $rentenversicherungAg['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($rentenversicherungAg['max'])) { $this->addUsingAlias(LohnprofilPeer::RENTENVERSICHERUNG_AG, $rentenversicherungAg['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::RENTENVERSICHERUNG_AG, $rentenversicherungAg, $comparison); } /** * Filter the query on the krankenversicherung_an column * * @param double|array $krankenversicherungAn The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByKrankenversicherungAn($krankenversicherungAn = null, $comparison = null) { if (is_array($krankenversicherungAn)) { $useMinMax = false; if (isset($krankenversicherungAn['min'])) { $this->addUsingAlias(LohnprofilPeer::KRANKENVERSICHERUNG_AN, $krankenversicherungAn['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($krankenversicherungAn['max'])) { $this->addUsingAlias(LohnprofilPeer::KRANKENVERSICHERUNG_AN, $krankenversicherungAn['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::KRANKENVERSICHERUNG_AN, $krankenversicherungAn, $comparison); } /** * Filter the query on the krankenversicherung_ag column * * @param double|array $krankenversicherungAg The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByKrankenversicherungAg($krankenversicherungAg = null, $comparison = null) { if (is_array($krankenversicherungAg)) { $useMinMax = false; if (isset($krankenversicherungAg['min'])) { $this->addUsingAlias(LohnprofilPeer::KRANKENVERSICHERUNG_AG, $krankenversicherungAg['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($krankenversicherungAg['max'])) { $this->addUsingAlias(LohnprofilPeer::KRANKENVERSICHERUNG_AG, $krankenversicherungAg['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::KRANKENVERSICHERUNG_AG, $krankenversicherungAg, $comparison); } /** * Filter the query on the u1 column * * @param double|array $u1 The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByU1($u1 = null, $comparison = null) { if (is_array($u1)) { $useMinMax = false; if (isset($u1['min'])) { $this->addUsingAlias(LohnprofilPeer::U1, $u1['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($u1['max'])) { $this->addUsingAlias(LohnprofilPeer::U1, $u1['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::U1, $u1, $comparison); } /** * Filter the query on the u2 column * * @param double|array $u2 The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByU2($u2 = null, $comparison = null) { if (is_array($u2)) { $useMinMax = false; if (isset($u2['min'])) { $this->addUsingAlias(LohnprofilPeer::U2, $u2['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($u2['max'])) { $this->addUsingAlias(LohnprofilPeer::U2, $u2['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::U2, $u2, $comparison); } /** * Filter the query on the inso column * * @param double|array $inso The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByInso($inso = null, $comparison = null) { if (is_array($inso)) { $useMinMax = false; if (isset($inso['min'])) { $this->addUsingAlias(LohnprofilPeer::INSO, $inso['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($inso['max'])) { $this->addUsingAlias(LohnprofilPeer::INSO, $inso['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::INSO, $inso, $comparison); } /** * Filter the query on the pauschalsteuer column * * @param double|array $pauschalsteuer The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByPauschalsteuer($pauschalsteuer = null, $comparison = null) { if (is_array($pauschalsteuer)) { $useMinMax = false; if (isset($pauschalsteuer['min'])) { $this->addUsingAlias(LohnprofilPeer::PAUSCHALSTEUER, $pauschalsteuer['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($pauschalsteuer['max'])) { $this->addUsingAlias(LohnprofilPeer::PAUSCHALSTEUER, $pauschalsteuer['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::PAUSCHALSTEUER, $pauschalsteuer, $comparison); } /** * Filter the query on the la_typ column * * @param int|array $laTyp The value to use as filter. * Accepts an associative array('min' => $minValue, 'max' => $maxValue) * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByLaTyp($laTyp = null, $comparison = null) { if (is_array($laTyp)) { $useMinMax = false; if (isset($laTyp['min'])) { $this->addUsingAlias(LohnprofilPeer::LA_TYP, $laTyp['min'], Criteria::GREATER_EQUAL); $useMinMax = true; } if (isset($laTyp['max'])) { $this->addUsingAlias(LohnprofilPeer::LA_TYP, $laTyp['max'], Criteria::LESS_EQUAL); $useMinMax = true; } if ($useMinMax) { return $this; } if (null === $comparison) { $comparison = Criteria::IN; } } return $this->addUsingAlias(LohnprofilPeer::LA_TYP, $laTyp, $comparison); } /** * Filter the query by a related Lohnabrechnung object * * @param Lohnabrechnung $lohnabrechnung the related object to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByLA($lohnabrechnung, $comparison = null) { return $this ->addUsingAlias(LohnprofilPeer::ID, $lohnabrechnung->getLpId(), $comparison); } /** * Adds a JOIN clause to the query using the LA relation * * @param string $relationAlias optional alias for the relation * @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join' * * @return LohnprofilQuery The current query, for fluid interface */ public function joinLA($relationAlias = null, $joinType = Criteria::INNER_JOIN) { $tableMap = $this->getTableMap(); $relationMap = $tableMap->getRelation('LA'); // create a ModelJoin object for this join $join = new ModelJoin(); $join->setJoinType($joinType); $join->setRelationMap($relationMap, $this->useAliasInSQL ? $this->getModelAlias() : null, $relationAlias); if ($previousJoin = $this->getPreviousJoin()) { $join->setPreviousJoin($previousJoin); } // add the ModelJoin to the current object if($relationAlias) { $this->addAlias($relationAlias, $relationMap->getRightTable()->getName()); $this->addJoinObject($join, $relationAlias); } else { $this->addJoinObject($join, 'LA'); } return $this; } /** * Use the LA relation Lohnabrechnung object * * @see useQuery() * * @param string $relationAlias optional alias for the relation, * to be used as main alias in the secondary query * @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join' * * @return LohnabrechnungQuery A secondary query class using the current class as primary query */ public function useLAQuery($relationAlias = null, $joinType = Criteria::INNER_JOIN) { return $this ->joinLA($relationAlias, $joinType) ->useQuery($relationAlias ? $relationAlias : 'LA', 'LohnabrechnungQuery'); } /** * Filter the query by a related Mitarbeiter object * * @param Mitarbeiter $mitarbeiter the related object to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return LohnprofilQuery The current query, for fluid interface */ public function filterByMA($mitarbeiter, $comparison = null) { return $this ->addUsingAlias(LohnprofilPeer::ID, $mitarbeiter->getLpId(), $comparison); } /** * Adds a JOIN clause to the query using the MA relation * * @param string $relationAlias optional alias for the relation * @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join' * * @return LohnprofilQuery The current query, for fluid interface */ public function joinMA($relationAlias = null, $joinType = Criteria::INNER_JOIN) { $tableMap = $this->getTableMap(); $relationMap = $tableMap->getRelation('MA'); // create a ModelJoin object for this join $join = new ModelJoin(); $join->setJoinType($joinType); $join->setRelationMap($relationMap, $this->useAliasInSQL ? $this->getModelAlias() : null, $relationAlias); if ($previousJoin = $this->getPreviousJoin()) { $join->setPreviousJoin($previousJoin); } // add the ModelJoin to the current object if($relationAlias) { $this->addAlias($relationAlias, $relationMap->getRightTable()->getName()); $this->addJoinObject($join, $relationAlias); } else { $this->addJoinObject($join, 'MA'); } return $this; } /** * Use the MA relation Mitarbeiter object * * @see useQuery() * * @param string $relationAlias optional alias for the relation, * to be used as main alias in the secondary query * @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join' * * @return MitarbeiterQuery A secondary query class using the current class as primary query */ public function useMAQuery($relationAlias = null, $joinType = Criteria::INNER_JOIN) { return $this ->joinMA($relationAlias, $joinType) ->useQuery($relationAlias ? $relationAlias : 'MA', 'MitarbeiterQuery'); } /** * Exclude object from result * * @param Lohnprofil $lohnprofil Object to remove from the list of results * * @return LohnprofilQuery The current query, for fluid interface */ public function prune($lohnprofil = null) { if ($lohnprofil) { $this->addUsingAlias(LohnprofilPeer::ID, $lohnprofil->getId(), Criteria::NOT_EQUAL); } return $this; } } // BaseLohnprofilQuery