nyx-solutions/yii2-nyx-migration
Composer 安装命令:
composer require nyx-solutions/yii2-nyx-migration
包简介
Yii2 Extended Migration Toolkit
README 文档
README
Yii2 NYX Migration is a library with Migrations methods for Yii2.
Installation
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist nyx-solutions/yii2-nyx-migration "*"
or add
"nyx-solutions/yii2-nyx-migration": "*"
to the require section of your composer.json file.
Usage
use nyx\db\Migration; class m150409_195340_site extends Migration { /** * @inheritdoc */ protected $tableName = 'site'; /** * @inheritdoc */ public function safeUp() { $columns = [ 'id' => $this->bigPrimaryKey($this->pkLength), 'name' => $this->string(2000)->notNull() ]; $this->createTable($this->getCurrentTableName(), $columns, $this->getTableOptions()); } }
License
yii2-nyx-migration is released under the BSD 3-Clause License. See the bundled LICENSE.md for details.
统计信息
- 总下载量: 86
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: BSD-3-Clause
- 更新时间: 2022-06-01