CDbException

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

/home/svetnew/web/svet-lussole.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/svet-lussole.ru/public_html/protected/models/Options_text.php(7): CActiveRecord::model("Options_text")
02 
03 class Options_text 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 'options_text';
#2
+
 /home/svetnew/web/svet-lussole.ru/public_html/protected/controllers/OptionsController.php(82): Options_text::model()
77             $info = Info::model()->findByAttributes(array("id" => "1"));
78             $this->info = $info;
79 
80             $error = "ok";
81             $bigurl = $request;
82             $content = Options_text::model()->findAll(array('condition' => '`url` = "' . $request . '" || `new_url` = "' . $request . '"', 'order' => '`id` ASC', 'limit' => 1));
83 
84             if (isset($content['0']->id)) {
85                 if ($request == $content['0']->new_url) {
86                     $bigurl = $content['0']->url;
87                 } else {
#17
+
 /home/svetnew/web/svet-lussole.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:55 Apache/2.4.18 (Ubuntu) mod_fcgid/2.3.9 OpenSSL/1.0.2g Yii Framework/1.1.13