slayer911/yii2-dbcast

Auto migration

Installs: 422

Dependents: 0

Suggesters: 0

Security: 0

Stars: 2

Watchers: 3

Forks: 0

Open Issues: 1

Type:yii2-extension

1.0.3 2017-08-30 18:18 UTC

This package is not auto-updated.

Last update: 2024-04-19 21:50:43 UTC


README

Auto generate migration by your changes DB schema. Module create cast of previous DB schema, and current.

Currently supports only MySql

Install

composer require --dev "slayer911/yii2-dbcast:*"

After vendor was installed - create first DBCast.

 php yii migrate/cast-save

If in this step you have an error - add to console config (main-local.php) next data:

<?php
return [
    ...
    'controllerMap' => [
        'migrate' => [
            'class'   => \DBCast\controllers\MigrateController::class,
            'develop' => true
        ]
    ]
    ...
];

Using

Default Yii controller was extended by DbCast Migrate controller. Now you have next commands: newcommands

  • migrate/cast-commit

castcommit