mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-07 07:12:47 +08:00
Merge branch 'master' of https://github.com/top-think/framework
This commit is contained in:
@@ -30,7 +30,7 @@ class Config extends Command
|
|||||||
|
|
||||||
protected function execute(Input $input, Output $output)
|
protected function execute(Input $input, Output $output)
|
||||||
{
|
{
|
||||||
if ($input->hasArgument('module')) {
|
if ($input->getArgument('module')) {
|
||||||
$module = $input->getArgument('module') . DS;
|
$module = $input->getArgument('module') . DS;
|
||||||
} else {
|
} else {
|
||||||
$module = '';
|
$module = '';
|
||||||
|
|||||||
@@ -44,7 +44,8 @@ class Schema extends Command
|
|||||||
if ($input->hasOption('module')) {
|
if ($input->hasOption('module')) {
|
||||||
$module = $input->getOption('module');
|
$module = $input->getOption('module');
|
||||||
// 读取模型
|
// 读取模型
|
||||||
$list = scandir(APP_PATH . $module . DS . 'model');
|
$path = APP_PATH . $module . DS . 'model';
|
||||||
|
$list = is_dir($path) ? scandir($path) : [];
|
||||||
$app = App::$namespace;
|
$app = App::$namespace;
|
||||||
foreach ($list as $file) {
|
foreach ($list as $file) {
|
||||||
if (0 === strpos($file, '.')) {
|
if (0 === strpos($file, '.')) {
|
||||||
@@ -66,7 +67,8 @@ class Schema extends Command
|
|||||||
$tables = Db::connect($config)->getTables($dbName);
|
$tables = Db::connect($config)->getTables($dbName);
|
||||||
} elseif (!\think\Config::get('app_multi_module')) {
|
} elseif (!\think\Config::get('app_multi_module')) {
|
||||||
$app = App::$namespace;
|
$app = App::$namespace;
|
||||||
$list = scandir(APP_PATH . 'model');
|
$path = APP_PATH . 'model';
|
||||||
|
$list = is_dir($path) ? scandir($path) : [];
|
||||||
foreach ($list as $file) {
|
foreach ($list as $file) {
|
||||||
if (0 === strpos($file, '.')) {
|
if (0 === strpos($file, '.')) {
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
Reference in New Issue
Block a user