fix #128
This commit is contained in:
@@ -115,6 +115,13 @@ class Category extends BaseCategory
|
||||
*/
|
||||
public function postDelete(ConnectionInterface $con = null)
|
||||
{
|
||||
RewritingUrlQuery::create()
|
||||
->filterByView($this->getRewrittenUrlViewName())
|
||||
->filterByViewId($this->getId())
|
||||
->update(array(
|
||||
"View" => ConfigQuery::getObsoleteRewrittenUrlView()
|
||||
));
|
||||
|
||||
$this->dispatchEvent(TheliaEvents::AFTER_DELETECATEGORY, new CategoryEvent($this));
|
||||
}
|
||||
}
|
||||
@@ -148,6 +148,13 @@ class Content extends BaseContent
|
||||
|
||||
public function postDelete(ConnectionInterface $con = null)
|
||||
{
|
||||
RewritingUrlQuery::create()
|
||||
->filterByView($this->getRewrittenUrlViewName())
|
||||
->filterByViewId($this->getId())
|
||||
->update(array(
|
||||
"View" => ConfigQuery::getObsoleteRewrittenUrlView()
|
||||
));
|
||||
|
||||
$this->dispatchEvent(TheliaEvents::AFTER_DELETECONTENT, new ContentEvent($this));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,6 +100,13 @@ class Folder extends BaseFolder
|
||||
|
||||
public function postDelete(ConnectionInterface $con = null)
|
||||
{
|
||||
RewritingUrlQuery::create()
|
||||
->filterByView($this->getRewrittenUrlViewName())
|
||||
->filterByViewId($this->getId())
|
||||
->update(array(
|
||||
"View" => ConfigQuery::getObsoleteRewrittenUrlView()
|
||||
));
|
||||
|
||||
$this->dispatchEvent(TheliaEvents::AFTER_DELETEFOLDER, new FolderEvent($this));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -269,6 +269,7 @@ class Product extends BaseProduct
|
||||
->update(array(
|
||||
"View" => ConfigQuery::getObsoleteRewrittenUrlView()
|
||||
));
|
||||
|
||||
$this->dispatchEvent(TheliaEvents::AFTER_DELETEPRODUCT, new ProductEvent($this));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user