新增stubs
This commit is contained in:
parent
b06a5300cb
commit
ef545b8732
10
extend/catcher/command/MigrateCreateCommand.php
Normal file
10
extend/catcher/command/MigrateCreateCommand.php
Normal file
@ -0,0 +1,10 @@
|
||||
<?php
|
||||
/**
|
||||
* @filename MigrateCreateCommand.php
|
||||
* @createdAt 2020/1/21
|
||||
* @project https://github.com/yanwenwu/catch-admin
|
||||
* @document http://doc.catchadmin.com
|
||||
* @author JaguarJack <njphper@gmail.com>
|
||||
* @copyright By CatchAdmin
|
||||
* @license https://github.com/yanwenwu/catch-admin/blob/master/LICENSE.txt
|
||||
*/
|
10
extend/catcher/command/MigrateRollbackCommand.php
Normal file
10
extend/catcher/command/MigrateRollbackCommand.php
Normal file
@ -0,0 +1,10 @@
|
||||
<?php
|
||||
/**
|
||||
* @filename MigrateRollbackCommand.php
|
||||
* @createdAt 2020/1/20
|
||||
* @project https://github.com/yanwenwu/catch-admin
|
||||
* @document http://doc.catchadmin.com
|
||||
* @author JaguarJack <njphper@gmail.com>
|
||||
* @copyright By CatchAdmin
|
||||
* @license https://github.com/yanwenwu/catch-admin/blob/master/LICENSE.txt
|
||||
*/
|
33
extend/catcher/command/stubs/migrate.stub
Normal file
33
extend/catcher/command/stubs/migrate.stub
Normal file
@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
use think\migration\Migrator;
|
||||
use think\migration\db\Column;
|
||||
|
||||
class MigratorClass extends Migrator
|
||||
{
|
||||
/**
|
||||
* Change Method.
|
||||
*
|
||||
* Write your reversible migrations using this method.
|
||||
*
|
||||
* More information on writing migrations is available here:
|
||||
* http://docs.phinx.org/en/latest/migrations.html#the-abstractmigration-class
|
||||
*
|
||||
* The following commands can be used in this method and Phinx will
|
||||
* automatically reverse them when rolling back:
|
||||
*
|
||||
* createTable
|
||||
* renameTable
|
||||
* addColumn
|
||||
* renameColumn
|
||||
* addIndex
|
||||
* addForeignKey
|
||||
*
|
||||
* Remember to call "create()" or "update()" and NOT "save()" when working
|
||||
* with the Table class.
|
||||
*/
|
||||
public function change()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
19
extend/catcher/command/stubs/seed.stub
Normal file
19
extend/catcher/command/stubs/seed.stub
Normal file
@ -0,0 +1,19 @@
|
||||
<?php
|
||||
|
||||
use think\migration\Seeder;
|
||||
|
||||
class SeederClass extends Seeder
|
||||
{
|
||||
/**
|
||||
* Run Method.
|
||||
*
|
||||
* Write your database seeder using this method.
|
||||
*
|
||||
* More information on writing seeders is available here:
|
||||
* http://docs.phinx.org/en/latest/seeding.html
|
||||
*/
|
||||
public function run()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user