示例#1
0
 /**
  * Обновляет топик
  *
  * @param ModuleTopic_EntityContentType $oContentType    Объект типа контента
  *
  * @return bool
  */
 public function DeleteContentType($oContentType)
 {
     $aFilter = array('topic_type' => $oContentType->getContentUrl());
     $iCount = $this->GetCountTopicsByFilter($aFilter);
     if (!$iCount && $this->oMapper->DeleteContentType($oContentType->getId())) {
         //чистим зависимые кеши
         E::ModuleCache()->CleanByTags(array('content_new', 'content_update', 'topic_update'));
         E::ModuleCache()->Delete("content_type_{$oContentType->getId()}");
         return true;
     }
     return false;
 }