src/Slashworks/BackendBundle/Model/om/BaseSystemSettingsPeer.php
public static function doUpdate($values, PropelPDO $con = null)
    {
        if ($con === null) {
            $con = Propel::getConnection(SystemSettingsPeer::DATABASE_NAME, Propel::CONNECTION_WRITE);
        }

        $selectCriteria = new Criteria(SystemSettingsPeer::DATABASE_NAME);

        if ($values instanceof Criteria) {
            $criteria = clone $values; // rename for clarity

            $comparison = $criteria->getComparison(SystemSettingsPeer::ID);
            $value = $criteria->remove(SystemSettingsPeer::ID);
            if ($value) {
                $selectCriteria->add(SystemSettingsPeer::ID, $value, $comparison);
            } else {
                $selectCriteria->setPrimaryTableName(SystemSettingsPeer::TABLE_NAME);
            }

        } else { // $values is SystemSettings object
            $criteria = $values->buildCriteria(); // gets full criteria
            $selectCriteria = $values->buildPkeyCriteria(); // gets criteria w/ primary key(s)
        }

        // set the correct dbName
        $criteria->setDbName(SystemSettingsPeer::DATABASE_NAME);

        return BasePeer::doUpdate($selectCriteria, $criteria, $con);
    }
public static function doUpdate($values, PropelPDO $con = null)
    {
        if ($con === null) {
            $con = Propel::getConnection(SystemSettingsPeer::DATABASE_NAME, Propel::CONNECTION_WRITE);
        }

        $selectCriteria = new Criteria(SystemSettingsPeer::DATABASE_NAME);

        if ($values instanceof Criteria) {
            $criteria = clone $values; // rename for clarity

            $comparison = $criteria->getComparison(SystemSettingsPeer::ID);
            $value = $criteria->remove(SystemSettingsPeer::ID);
            if ($value) {
                $selectCriteria->add(SystemSettingsPeer::ID, $value, $comparison);
            } else {
                $selectCriteria->setPrimaryTableName(SystemSettingsPeer::TABLE_NAME);
            }

        } else { // $values is SystemSettings object
            $criteria = $values->buildCriteria(); // gets full criteria
            $selectCriteria = $values->buildPkeyCriteria(); // gets criteria w/ primary key(s)
        }

        // set the correct dbName
        $criteria->setDbName(SystemSettingsPeer::DATABASE_NAME);

        return BasePeer::doUpdate($selectCriteria, $criteria, $con);
    }
public static function doUpdate ( $ values , PropelPDO $ con = null ) { if ( $ con === null ) { $ con = Propel :: getConnection ( SystemSettingsPeer :: DATABASE_NAME , Propel :: CONNECTION_WRITE ) ; } $ selectCriteria = new Criteria ( SystemSettingsPeer :: DATABASE_NAME ) ; if ( $ values instanceof Criteria ) { $ criteria = clone $ values ; // rename for clarity $ comparison = $ criteria -> getComparison ( SystemSettingsPeer :: ID ) ; $ value = $ criteria -> remove ( SystemSettingsPeer :: ID ) ; if ( $ value ) { $ selectCriteria -> add ( SystemSettingsPeer :: ID , $ value , $ comparison ) ; } else { $ selectCriteria -> setPrimaryTableName ( SystemSettingsPeer :: TABLE_NAME ) ; } } else { // $values is SystemSettings object $ criteria = $ values -> buildCriteria ( ) ; // gets full criteria $ selectCriteria = $ values -> buildPkeyCriteria ( ) ; // gets criteria w/ primary key(s) } // set the correct dbName $ criteria -> setDbName ( SystemSettingsPeer :: DATABASE_NAME ) ; return BasePeer :: doUpdate ( $ selectCriteria , $ criteria , $ con ) ; }
Performs an UPDATE on the database, given a SystemSettings or Criteria object.

@param      mixed $values Criteria or SystemSettings object containing data that is used to create the UPDATE statement.
@param      PropelPDO $con The connection to use (specify PropelPDO connection object to exert more control over transactions).
@return int             The number of affected rows (if supported by underlying database driver).
@throws PropelException Any exceptions caught during processing will be
rethrown wrapped into a PropelException.
Performs an UPDATE on the database given a SystemSettings or Criteria object .