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 Lohnabrechnung|array|mixed the result, formatted by the current formatter
*/
public function findPk($key, $con = null)
{
if ((null !== ($obj = LohnabrechnungPeer::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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByPrimaryKey($key)
{
return $this->addUsingAlias(LohnabrechnungPeer::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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByPrimaryKeys($keys)
{
return $this->addUsingAlias(LohnabrechnungPeer::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 LohnabrechnungQuery 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(LohnabrechnungPeer::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 LohnabrechnungQuery 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(LohnabrechnungPeer::MOD, $mod['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($mod['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::MOD, $mod['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::MOD, $mod, $comparison);
}
/**
* Filter the query on the monat column
*
* @param string $monat 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByMonat($monat = null, $comparison = null)
{
if (null === $comparison) {
if (is_array($monat)) {
$comparison = Criteria::IN;
} elseif (preg_match('/[\%\*]/', $monat)) {
$monat = str_replace('*', '%', $monat);
$comparison = Criteria::LIKE;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::MONAT, $monat, $comparison);
}
/**
* Filter the query on the arbeitsstunden column
*
* @param string|array $arbeitsstunden 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByArbeitsstunden($arbeitsstunden = null, $comparison = null)
{
if (is_array($arbeitsstunden)) {
$useMinMax = false;
if (isset($arbeitsstunden['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::ARBEITSSTUNDEN, $arbeitsstunden['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($arbeitsstunden['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::ARBEITSSTUNDEN, $arbeitsstunden['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::ARBEITSSTUNDEN, $arbeitsstunden, $comparison);
}
/**
* Filter the query on the brutto column
*
* @param string|array $brutto 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByBrutto($brutto = null, $comparison = null)
{
if (is_array($brutto)) {
$useMinMax = false;
if (isset($brutto['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::BRUTTO, $brutto['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($brutto['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::BRUTTO, $brutto['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::BRUTTO, $brutto, $comparison);
}
/**
* Filter the query on the zulage column
*
* @param string|array $zulage 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByZulage($zulage = null, $comparison = null)
{
if (is_array($zulage)) {
$useMinMax = false;
if (isset($zulage['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::ZULAGE, $zulage['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($zulage['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::ZULAGE, $zulage['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::ZULAGE, $zulage, $comparison);
}
/**
* Filter the query on the netto column
*
* @param string|array $netto 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByNetto($netto = null, $comparison = null)
{
if (is_array($netto)) {
$useMinMax = false;
if (isset($netto['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::NETTO, $netto['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($netto['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::NETTO, $netto['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::NETTO, $netto, $comparison);
}
/**
* Filter the query on the lohnsteuer column
*
* @param string|array $lohnsteuer 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByLohnsteuer($lohnsteuer = null, $comparison = null)
{
if (is_array($lohnsteuer)) {
$useMinMax = false;
if (isset($lohnsteuer['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::LOHNSTEUER, $lohnsteuer['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($lohnsteuer['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::LOHNSTEUER, $lohnsteuer['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::LOHNSTEUER, $lohnsteuer, $comparison);
}
/**
* Filter the query on the kirchensteuer_rk column
*
* @param string|array $kirchensteuerRk 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByKirchensteuerRk($kirchensteuerRk = null, $comparison = null)
{
if (is_array($kirchensteuerRk)) {
$useMinMax = false;
if (isset($kirchensteuerRk['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::KIRCHENSTEUER_RK, $kirchensteuerRk['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($kirchensteuerRk['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::KIRCHENSTEUER_RK, $kirchensteuerRk['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::KIRCHENSTEUER_RK, $kirchensteuerRk, $comparison);
}
/**
* Filter the query on the kirchensteuer_ev column
*
* @param string|array $kirchensteuerEv 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByKirchensteuerEv($kirchensteuerEv = null, $comparison = null)
{
if (is_array($kirchensteuerEv)) {
$useMinMax = false;
if (isset($kirchensteuerEv['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::KIRCHENSTEUER_EV, $kirchensteuerEv['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($kirchensteuerEv['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::KIRCHENSTEUER_EV, $kirchensteuerEv['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::KIRCHENSTEUER_EV, $kirchensteuerEv, $comparison);
}
/**
* Filter the query on the soli column
*
* @param string|array $soli 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterBySoli($soli = null, $comparison = null)
{
if (is_array($soli)) {
$useMinMax = false;
if (isset($soli['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::SOLI, $soli['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($soli['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::SOLI, $soli['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::SOLI, $soli, $comparison);
}
/**
* Filter the query on the rentenversicherung column
*
* @param string|array $rentenversicherung 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByRentenversicherung($rentenversicherung = null, $comparison = null)
{
if (is_array($rentenversicherung)) {
$useMinMax = false;
if (isset($rentenversicherung['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::RENTENVERSICHERUNG, $rentenversicherung['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($rentenversicherung['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::RENTENVERSICHERUNG, $rentenversicherung['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::RENTENVERSICHERUNG, $rentenversicherung, $comparison);
}
/**
* Filter the query on the krankenversicherung column
*
* @param string|array $krankenversicherung 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByKrankenversicherung($krankenversicherung = null, $comparison = null)
{
if (is_array($krankenversicherung)) {
$useMinMax = false;
if (isset($krankenversicherung['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::KRANKENVERSICHERUNG, $krankenversicherung['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($krankenversicherung['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::KRANKENVERSICHERUNG, $krankenversicherung['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::KRANKENVERSICHERUNG, $krankenversicherung, $comparison);
}
/**
* Filter the query on the ma_id column
*
* @param int|array $maId 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByMaId($maId = null, $comparison = null)
{
if (is_array($maId)) {
$useMinMax = false;
if (isset($maId['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::MA_ID, $maId['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($maId['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::MA_ID, $maId['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::MA_ID, $maId, $comparison);
}
/**
* Filter the query on the lp_id column
*
* @param int|array $lpId 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByLpId($lpId = null, $comparison = null)
{
if (is_array($lpId)) {
$useMinMax = false;
if (isset($lpId['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::LP_ID, $lpId['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($lpId['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::LP_ID, $lpId['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::LP_ID, $lpId, $comparison);
}
/**
* Filter the query on the class_key column
*
* @param int|array $classKey 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByClassKey($classKey = null, $comparison = null)
{
if (is_array($classKey)) {
$useMinMax = false;
if (isset($classKey['min'])) {
$this->addUsingAlias(LohnabrechnungPeer::CLASS_KEY, $classKey['min'], Criteria::GREATER_EQUAL);
$useMinMax = true;
}
if (isset($classKey['max'])) {
$this->addUsingAlias(LohnabrechnungPeer::CLASS_KEY, $classKey['max'], Criteria::LESS_EQUAL);
$useMinMax = true;
}
if ($useMinMax) {
return $this;
}
if (null === $comparison) {
$comparison = Criteria::IN;
}
}
return $this->addUsingAlias(LohnabrechnungPeer::CLASS_KEY, $classKey, $comparison);
}
/**
* 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 LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByMitarbeiter($mitarbeiter, $comparison = null)
{
return $this
->addUsingAlias(LohnabrechnungPeer::MA_ID, $mitarbeiter->getId(), $comparison);
}
/**
* Adds a JOIN clause to the query using the Mitarbeiter relation
*
* @param string $relationAlias optional alias for the relation
* @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join'
*
* @return LohnabrechnungQuery The current query, for fluid interface
*/
public function joinMitarbeiter($relationAlias = null, $joinType = Criteria::INNER_JOIN)
{
$tableMap = $this->getTableMap();
$relationMap = $tableMap->getRelation('Mitarbeiter');
// 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, 'Mitarbeiter');
}
return $this;
}
/**
* Use the Mitarbeiter 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 useMitarbeiterQuery($relationAlias = null, $joinType = Criteria::INNER_JOIN)
{
return $this
->joinMitarbeiter($relationAlias, $joinType)
->useQuery($relationAlias ? $relationAlias : 'Mitarbeiter', 'MitarbeiterQuery');
}
/**
* Filter the query by a related Lohnprofil object
*
* @param Lohnprofil $lohnprofil the related object to use as filter
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
*
* @return LohnabrechnungQuery The current query, for fluid interface
*/
public function filterByLohnprofil($lohnprofil, $comparison = null)
{
return $this
->addUsingAlias(LohnabrechnungPeer::LP_ID, $lohnprofil->getId(), $comparison);
}
/**
* Adds a JOIN clause to the query using the Lohnprofil relation
*
* @param string $relationAlias optional alias for the relation
* @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join'
*
* @return LohnabrechnungQuery The current query, for fluid interface
*/
public function joinLohnprofil($relationAlias = null, $joinType = Criteria::INNER_JOIN)
{
$tableMap = $this->getTableMap();
$relationMap = $tableMap->getRelation('Lohnprofil');
// 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, 'Lohnprofil');
}
return $this;
}
/**
* Use the Lohnprofil relation Lohnprofil 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 LohnprofilQuery A secondary query class using the current class as primary query
*/
public function useLohnprofilQuery($relationAlias = null, $joinType = Criteria::INNER_JOIN)
{
return $this
->joinLohnprofil($relationAlias, $joinType)
->useQuery($relationAlias ? $relationAlias : 'Lohnprofil', 'LohnprofilQuery');
}
/**
* Exclude object from result
*
* @param Lohnabrechnung $lohnabrechnung Object to remove from the list of results
*
* @return LohnabrechnungQuery The current query, for fluid interface
*/
public function prune($lohnabrechnung = null)
{
if ($lohnabrechnung) {
$this->addUsingAlias(LohnabrechnungPeer::ID, $lohnabrechnung->getId(), Criteria::NOT_EQUAL);
}
return $this;
}
} // BaseLohnabrechnungQuery