CDbException

Таблица "info", упомянутая в записи active record класса "Info", не найдена в базе данных.

/home/svetnew/web/lumion-svet.ru/public_html/framework/db/ar/CActiveRecord.php(2310)

2298     private $_model;
2299 
2300     /**
2301      * Constructor.
2302      * @param CActiveRecord $model the model instance
2303      */
2304     public function __construct($model)
2305     {
2306         $this->_model=$model;
2307 
2308         $tableName=$model->tableName();
2309         if(($table=$model->getDbConnection()->getSchema()->getTable($tableName))===null)
2310             throw new CDbException(Yii::t('yii','The table "{table}" for active record class "{class}" cannot be found in the database.',
2311                 array('{class}'=>get_class($model),'{table}'=>$tableName)));
2312         if($table->primaryKey===null)
2313         {
2314             $table->primaryKey=$model->primaryKey();
2315             if(is_string($table->primaryKey) && isset($table->columns[$table->primaryKey]))
2316                 $table->columns[$table->primaryKey]->isPrimaryKey=true;
2317             elseif(is_array($table->primaryKey))
2318             {
2319                 foreach($table->primaryKey as $name)
2320                 {
2321                     if(isset($table->columns[$name]))
2322                         $table->columns[$name]->isPrimaryKey=true;

Stack Trace

#1
+
 /home/svetnew/web/lumion-svet.ru/public_html/protected/models/Info.php(7): CActiveRecord::model("Info")
02 
03 class Info extends CActiveRecord
04 {
05     public static function model($className=__CLASS__)
06     {
07         return parent::model($className);
08     }
09 
10     public function tableName()
11     {
12         return 'info';
#2
+
 /home/svetnew/web/lumion-svet.ru/public_html/protected/controllers/CategoriesController.php(96): Info::model()
091         }
092         else
093         {
094             $this->layout = "main";
095 
096             $info = Info::model()->findByAttributes(array("id" => "1"));
097             $this->info = $info;
098 
099             $content = Categories::model()->findByAttributes(array("url" => $url));
100 
101             if (isset($content->id) && $content->disp == 1) {
#17
+
 /home/svetnew/web/lumion-svet.ru/public_html/index.php(9): CApplication->run()
4 $config=dirname(__FILE__).'/protected/config/main.php';
5 
6 defined('YII_DEBUG') or define('YII_DEBUG',true);
7 
8 require_once($yii);
9 Yii::createWebApplication($config)->run();
2024-03-19 02:00:02 Apache/2.4.18 (Ubuntu) mod_fcgid/2.3.9 OpenSSL/1.0.2g Yii Framework/1.1.13