CC-3620 : Calendar -> Unresponsive script warning when trying to add 300 ogg files

improving speed of js rendering,
datatables config is loaded from localstorage,
removed aggregate propel behaviour on cc_show_instances time_filled.
This commit is contained in:
Naomi Aro 2012-04-16 16:33:32 +02:00
parent ef908ee894
commit c96c60dc5a
16 changed files with 210 additions and 235 deletions

View file

@ -642,90 +642,4 @@ abstract class BaseCcScheduleQuery extends ModelCriteria
return $this;
}
/**
* Code to execute before every DELETE statement
*
* @param PropelPDO $con The connection object used by the query
*/
protected function basePreDelete(PropelPDO $con)
{
// aggregate_column_relation behavior
$this->findRelatedCcShowInstancess($con);
return $this->preDelete($con);
}
/**
* Code to execute after every DELETE statement
*
* @param int $affectedRows the number of deleted rows
* @param PropelPDO $con The connection object used by the query
*/
protected function basePostDelete($affectedRows, PropelPDO $con)
{
// aggregate_column_relation behavior
$this->updateRelatedCcShowInstancess($con);
return $this->postDelete($affectedRows, $con);
}
/**
* Code to execute before every UPDATE statement
*
* @param array $values The associatiove array of columns and values for the update
* @param PropelPDO $con The connection object used by the query
* @param boolean $forceIndividualSaves If false (default), the resulting call is a BasePeer::doUpdate(), ortherwise it is a series of save() calls on all the found objects
*/
protected function basePreUpdate(&$values, PropelPDO $con, $forceIndividualSaves = false)
{
// aggregate_column_relation behavior
$this->findRelatedCcShowInstancess($con);
return $this->preUpdate($values, $con, $forceIndividualSaves);
}
/**
* Code to execute after every UPDATE statement
*
* @param int $affectedRows the number of udated rows
* @param PropelPDO $con The connection object used by the query
*/
protected function basePostUpdate($affectedRows, PropelPDO $con)
{
// aggregate_column_relation behavior
$this->updateRelatedCcShowInstancess($con);
return $this->postUpdate($affectedRows, $con);
}
// aggregate_column_relation behavior
/**
* Finds the related CcShowInstances objects and keep them for later
*
* @param PropelPDO $con A connection object
*/
protected function findRelatedCcShowInstancess($con)
{
$criteria = clone $this;
if ($this->useAliasInSQL) {
$alias = $this->getModelAlias();
$criteria->removeAlias($alias);
} else {
$alias = '';
}
$this->ccShowInstancess = CcShowInstancesQuery::create()
->joinCcSchedule($alias)
->mergeWith($criteria)
->find($con);
}
protected function updateRelatedCcShowInstancess($con)
{
foreach ($this->ccShowInstancess as $ccShowInstances) {
$ccShowInstances->updateDbTimeFilled($con);
}
$this->ccShowInstancess = array();
}
} // BaseCcScheduleQuery