mirror of
				https://github.com/elyby/accounts.git
				synced 2025-05-31 14:11:46 +05:30 
			
		
		
		
	В класс миграции добавлено поведение по умолчанию при создании новой таблицы
This commit is contained in:
		@@ -17,6 +17,14 @@ class Migration extends YiiMigration {
 | 
				
			|||||||
        return $tableOptions;
 | 
					        return $tableOptions;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    public function createTable($table, $columns, $options = null) {
 | 
				
			||||||
 | 
					        if ($options === null) {
 | 
				
			||||||
 | 
					            $options = $this->getTableOptions();
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        parent::createTable($table, $columns, $options);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    protected function primary(...$columns) {
 | 
					    protected function primary(...$columns) {
 | 
				
			||||||
        switch (count($columns)) {
 | 
					        switch (count($columns)) {
 | 
				
			||||||
            case 0:
 | 
					            case 0:
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user