Browse Source

Merge branch 'master' of http://59.57.98.130:3000/jjhc/reservation_admin

王亚超 1 year ago
parent
commit
c9c6556f9f
3 changed files with 15 additions and 6 deletions
  1. 9 0
      app/api/controller/Common.php
  2. 5 5
      app/helper_env.php
  3. 1 1
      app/install/view/index/step2.html

+ 9 - 0
app/api/controller/Common.php

@@ -30,6 +30,15 @@ class Common extends Base
         $this->redirect($url);
     }
 
+    public function loginLw()
+    {
+        $user = User::get(9);
+        //登入成功 ,返回 前端
+        $return_url = 'https://localhost:8080/';
+//        halt(Permissions::createJwt($user->id, $user->login_time, 3600 * 24));
+        $this->redirect($return_url . '?jwt=' . Permissions::createJwt($user->id, $user->login_time, 3600 * 24));
+    }
+
     public function loginNotify()
     {
         $mystate = session('state', '', 'login');

+ 5 - 5
app/helper_env.php

@@ -26,11 +26,11 @@ function temp_clear()
 function systemName()
 {
     if (is_installed()) {
-        $name = \app\common\model\Webconfig::getValue('name', 3600);
-        if ($name) {
-            return $name;
-        }
+    $name = \app\common\model\Webconfig::getValue('name', 3600);
+    if ($name) {
+        return $name;
     }
+}
     return PRODUCT_NAME;
 }
 
@@ -39,7 +39,7 @@ function systemName()
  */
 function check_php_version()
 {
-    if (PHP_VERSION < 7 || PHP_VERSION >= 7.3) {
+    if (PHP_VERSION < 7 || PHP_VERSION >= 7.4) {
         header("Content-type: text/html; charset=utf-8");
         exit("运行环境要求PHP 7.0 ~ 7.2,请修改PHP版本");
     }

+ 1 - 1
app/install/view/index/step2.html

@@ -53,7 +53,7 @@
                     <td><?php echo PHP_VERSION ?></td>
                     <?php $php_version=explode('.', PHP_VERSION); ?>
                     <td>
-                        {if condition="$php_version[0] >=7 && $php_version[1] < 3"}
+                        {if condition="$php_version[0] >=7 && $php_version[1] < 4"}
                         <i class="layui-icon layui-icon-ok yes"></i>
                         {else/}
                         <i class="layui-icon layui-icon-close"></i>