mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-10 11:33:17 +00:00
Remove calls to dropped orders table
This commit is contained in:
@@ -768,6 +768,11 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
|
||||
$this->app['EM']->remove($export);
|
||||
}
|
||||
|
||||
$repo = $this->app['EM']->getRepository('Entities\Order');
|
||||
foreach ($repo->findByUser($this) as $order) {
|
||||
$this->app['EM']->remove($order);
|
||||
}
|
||||
|
||||
$this->app['EM']->flush();
|
||||
|
||||
$sql = 'UPDATE usr SET usr_login = :usr_login , usr_mail = null
|
||||
@@ -796,11 +801,6 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
|
||||
$stmt->execute(array(':usr_id' => $this->get_id()));
|
||||
$stmt->closeCursor();
|
||||
|
||||
$sql = 'DELETE FROM `order` WHERE usr_id = :usr_id';
|
||||
$stmt = $this->app['phraseanet.appbox']->get_connection()->prepare($sql);
|
||||
$stmt->execute(array(':usr_id' => $this->get_id()));
|
||||
$stmt->closeCursor();
|
||||
|
||||
$sql = 'DELETE FROM sselnew WHERE usr_id = :usr_id';
|
||||
$stmt = $this->app['phraseanet.appbox']->get_connection()->prepare($sql);
|
||||
$stmt->execute(array(':usr_id' => $this->get_id()));
|
||||
|
Reference in New Issue
Block a user