update:导出数据

This commit is contained in:
JaguarJack 2020-09-05 17:18:31 +08:00
parent da9aa45036
commit 96751d6974
5 changed files with 9 additions and 5 deletions

View File

@ -2,7 +2,7 @@
use think\migration\Seeder; use think\migration\Seeder;
class PermissionSeed extends Seeder class PermissionsMenusSeed extends Seeder
{ {
/** /**
* Run Method. * Run Method.

View File

@ -2,7 +2,7 @@
use think\migration\Seeder; use think\migration\Seeder;
class PermissionSeed extends Seeder class SystemMenusSeed extends Seeder
{ {
/** /**
* Run Method. * Run Method.

View File

@ -2,7 +2,7 @@
use think\migration\Seeder; use think\migration\Seeder;
class PermissionSeed extends Seeder class WechatMenusSeed extends Seeder
{ {
/** /**
* Run Method. * Run Method.

View File

@ -64,7 +64,11 @@ class ExportDataCommand extends Command
{ {
$stub = file_get_contents(dirname(__DIR__) . DIRECTORY_SEPARATOR . 'stubs' . DIRECTORY_SEPARATOR . 'permissionSeed.stub'); $stub = file_get_contents(dirname(__DIR__) . DIRECTORY_SEPARATOR . 'stubs' . DIRECTORY_SEPARATOR . 'permissionSeed.stub');
file_put_contents(CatchAdmin::moduleSeedsDirectory($module) . ucfirst($module) . 'PermissionSeed.php', str_replace('{DATA}', $data, $stub)); $class = ucfirst($module) . 'MenusSeed';
$stub = str_replace('{CLASS}', $class, $stub);
file_put_contents(CatchAdmin::moduleSeedsDirectory($module) . $class .'.php', str_replace('{DATA}', $data, $stub));
} }
} }

View File

@ -2,7 +2,7 @@
use think\migration\Seeder; use think\migration\Seeder;
class PermissionSeed extends Seeder class {CLASS} extends Seeder
{ {
/** /**
* Run Method. * Run Method.