Beispiel #1
0
 protected function getMigrationHistory($limit)
 {
     $db = $this->getDbConnection();
     $db->schema->refresh();
     // Checking for migration table without throwing an error
     if (!array_key_exists($this->migrationTable, $db->schema->getTables())) {
         echo 'Creating migration history table "' . $this->migrationTable . '"...';
         $db->createCommand()->createTable($this->migrationTable, array('version' => 'string NOT NULL PRIMARY KEY', 'apply_time' => 'integer', 'module' => 'VARCHAR(32)'));
         echo "done.\n";
     }
     return parent::getMigrationHistory($limit);
 }