From d6e965ba1b3492e7ebd38d19ccf4bba75d0af859 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E6=B5=B7=E9=9B=B7?= <330394331@qq.com> Date: Wed, 30 Sep 2026 19:35:07 +0800 Subject: [PATCH] =?UTF-8?q?=E7=B3=BB=E7=BB=9F=E5=AE=89=E8=A3=85=E8=B7=B3?= =?UTF-8?q?=E8=BF=87=E4=BA=91=E7=BC=96=E8=AF=91=E5=92=8C=E6=8F=92=E4=BB=B6?= =?UTF-8?q?=E5=AE=89=E8=A3=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- niucloud/app/install/controller/Index.php | 49 +- niucloud/app/install/view/base.html | 8 +- niucloud/app/install/view/index/step-3.html | 2 +- niucloud/app/install/view/index/step-4.html | 491 +++++--------------- niucloud/app/install/view/index/step-5.html | 143 ------ 5 files changed, 132 insertions(+), 561 deletions(-) delete mode 100644 niucloud/app/install/view/index/step-5.html diff --git a/niucloud/app/install/controller/Index.php b/niucloud/app/install/controller/Index.php index cbaa584fa..cc49b4c6a 100644 --- a/niucloud/app/install/controller/Index.php +++ b/niucloud/app/install/controller/Index.php @@ -113,14 +113,6 @@ class Index extends BaseInstall } } - public function build() - { - $install_user = Cache::get('install_user'); - $token = ( new LoginService() )->login($install_user[ 'username' ], $install_user[ 'password' ]); - $this->assign('token', $token[ 'token' ]); - return $this->fetch('index/step-4'); - } - /** * 安装成功 * @return string @@ -130,7 +122,7 @@ class Index extends BaseInstall Cache::delete('install_data'); Cache::delete('install_status'); $this->assign('is_build', request()->get('is_build', 1)); - return $this->fetch('index/step-5'); + return $this->fetch('index/step-4'); } /** @@ -381,9 +373,6 @@ class Index extends BaseInstall ]); } - // 安装插件 - $this->installAddon(); - $fp = fopen($this->lock_file, 'wb'); if (!$fp) { $this->setSuccessLog([ "写入失败,请检查目录" . dirname(__FILE__, 2) . "是否可写入!'", 'error' ]); @@ -404,42 +393,6 @@ class Index extends BaseInstall } } - /** - * 安装插件 - * @return true - */ - public function installAddon() - { - $root_path = str_replace("\\", DIRECTORY_SEPARATOR, dirname(__FILE__, 4)); - $root_path = str_replace("../", DIRECTORY_SEPARATOR, $root_path); - $addon_path = $root_path . DIRECTORY_SEPARATOR . 'addon'; - - $files = get_files_by_dir($addon_path); - if (!empty($files)) { - $addon = []; - foreach ($files as $path) { - $data = ( new CoreAddonService() )->getAddonConfig($path); - if (isset($data[ 'key' ])) { - if ($data[ 'type' ] == 'app') { - $install_service = ( new CoreAddonInstallService($data[ 'key' ]) ); - $install_service->installCheck(); - $install_service->install(); - } else { - $addon[] = $data; - } - } - } - if (!empty($addon)) { - foreach ($addon as $k => $v) { - $install_service = ( new CoreAddonInstallService($v[ 'key' ]) ); - $install_service->installCheck(); - $install_service->install(); - } - } - } - return true; - } - /** * 安装sql * @param array $data diff --git a/niucloud/app/install/view/base.html b/niucloud/app/install/view/base.html index 33d2856af..18e92fb86 100644 --- a/niucloud/app/install/view/base.html +++ b/niucloud/app/install/view/base.html @@ -59,14 +59,8 @@
-
+ 恭喜您!已成功安装{$install_config.website_name}。
+ {/if} + {if $is_build == 0} +安装过程已结束,您还需要手动编译,才能正常使用!
+如何手动编译请参考如下链接 {$install_config.build_manual}
+ {/if} +建议删除安装目录install后使用
+您现在可以访问:
+
+
+
+
+
- 恭喜您!已成功安装{$install_config.website_name}。
- {/if} - {if $is_build == 0} -安装过程已结束,您还需要手动编译,才能正常使用!
-如何手动编译请参考如下链接 {$install_config.build_manual}
- {/if} -建议删除安装目录install后使用
-您现在可以访问:
-
-
-
-
-