/var/www/u1669848/data/www/dsb0058.ru/protected/models/Catalog.php(167)
155 return $result; 156 } 157 158 /** 159 * Gets the parent category of a given category 160 * 161 * @param $categoryId if of starting category 162 * @return DbTable_Catalog_CategoryRow 163 */ 164 public function getParentById($categoryId) 165 { 166 $model = self::model(); 167 $categoryRow = $model->findbyPk($categoryId)->getAttributes(); 168 $query = array('order'=>'lft DESC'); 169 $criteria=new CDbCriteria($query); 170 $criteria->addCondition('lft<=' . $categoryRow['lft']); 171 $criteria->addCondition('rgt>=' . $categoryRow['rgt']); 172 $model->setDbCriteria($criteria); 173 $result = $model->findAll(); 174 if(count($result) == 1) { 175 return $result[0]; 176 } 177 return $result[1]; 178 } 179
#0 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/protected/controllers/CatalogController.php(24): Catalog->getParentById("99") 19 //$this->layout='column_detail'; 20 $id = intval($id); 21 $model = Product::model()->getProduct($id); 22 if($model===null) 23 throw new CHttpException(404,I18n::t('The requested page does not exist.')); 24 $cata = Catalog::model()->getParentById($model->typeid); 25 $thiscat = Catalog::model()->getById($model->typeid); 26 $model->typename = $thiscat['name']; 27 28 //���µ������ 29 $arc = Archives::model()->findByPk($id); |
#1 |
unknown(0): CatalogController->actionDetail(1502)
|
#2 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/framework/web/actions/CAction.php(107): ReflectionMethod->invokeArgs(CatalogController, array("1502")) 102 else if($param->isDefaultValueAvailable()) 103 $ps[]=$param->getDefaultValue(); 104 else 105 return false; 106 } 107 $method->invokeArgs($object,$ps); 108 return true; 109 } 110 } |
#3 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/framework/web/actions/CInlineAction.php(48): CAction->runWithParamsInternal(CatalogController, ReflectionMethod, array("id" => "1502")) 43 { 44 $methodName='action'.$this->getId(); 45 $controller=$this->getController(); 46 $method=new ReflectionMethod($controller, $methodName); 47 if($method->getNumberOfParameters()>0) 48 return $this->runWithParamsInternal($controller, $method, $params); 49 else 50 return $controller->$methodName(); 51 } 52 53 } |
#4 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/framework/web/CController.php(309): CInlineAction->runWithParams(array("id" => "1502")) 304 { 305 $priorAction=$this->_action; 306 $this->_action=$action; 307 if($this->beforeAction($action)) 308 { 309 if($action->runWithParams($this->getActionParams())===false) 310 $this->invalidActionParams($action); 311 else 312 $this->afterAction($action); 313 } 314 $this->_action=$priorAction; |
#5 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/framework/web/CController.php(287): CController->runAction(CInlineAction) 282 * @see runAction 283 */ 284 public function runActionWithFilters($action,$filters) 285 { 286 if(empty($filters)) 287 $this->runAction($action); 288 else 289 { 290 $priorAction=$this->_action; 291 $this->_action=$action; 292 CFilterChain::create($this,$action,$filters)->run(); |
#6 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/framework/web/CController.php(266): CController->runActionWithFilters(CInlineAction, array()) 261 { 262 if(($parent=$this->getModule())===null) 263 $parent=Yii::app(); 264 if($parent->beforeControllerAction($this,$action)) 265 { 266 $this->runActionWithFilters($action,$this->filters()); 267 $parent->afterControllerAction($this,$action); 268 } 269 } 270 else 271 $this->missingAction($actionID); |
#7 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/framework/web/CWebApplication.php(276): CController->run("detail") 271 { 272 list($controller,$actionID)=$ca; 273 $oldController=$this->_controller; 274 $this->_controller=$controller; 275 $controller->init(); 276 $controller->run($actionID); 277 $this->_controller=$oldController; 278 } 279 else 280 throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".', 281 array('{route}'=>$route===''?$this->defaultController:$route))); |
#8 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/framework/web/CWebApplication.php(135): CWebApplication->runController("catalog/detail") 130 foreach(array_splice($this->catchAllRequest,1) as $name=>$value) 131 $_GET[$name]=$value; 132 } 133 else 134 $route=$this->getUrlManager()->parseUrl($this->getRequest()); 135 $this->runController($route); 136 } 137 138 /** 139 * Registers the core application components. 140 * This method overrides the parent implementation by registering additional core components. |
#9 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/framework/base/CApplication.php(162): CWebApplication->processRequest() 157 */ 158 public function run() 159 { 160 if($this->hasEventHandler('onBeginRequest')) 161 $this->onBeginRequest(new CEvent($this)); 162 $this->processRequest(); 163 if($this->hasEventHandler('onEndRequest')) 164 $this->onEndRequest(new CEvent($this)); 165 } 166 167 /** |
#10 |
+
–
/var/www/u1669848/data/www/dsb0058.ru/index.php(13): CApplication->run() 08 09 // remove the following line when in production mode 10 defined('YII_DEBUG') or define('YII_DEBUG',true); 11 12 require_once($yii); 13 Yii::createWebApplication($config)->run(); |