Browse Source

Fix 系统参数更新后,未正确重新存储 #138

兔姬桑 5 years ago
parent
commit
c1e235c56d

+ 21 - 9
.github/ISSUE_TEMPLATE/bug-report.md

@@ -1,16 +1,28 @@
 ---
-name: Bug report
-about: BUG反馈
-title: ''
+name: 错误报告 - Bug Report
+about: '创建错误报告以帮助我们改进 '
+title: "[BUG]"
 labels: ''
-assignees: ''
+assignees: ZBrettonYe
 
 ---
 
-**描述你遇到的bug**
-简单的描述一下你遇到的bug
+**确保你已经看过 readme和wiki,也搜索并阅读过和你遇到的情况相关的问题。否则会被认为是重复的并被立刻关闭。**
 
-**如何复现你的BUG**
-为方便找bug,请说明你bug产生的步骤
+**错误描述**
+对错误的清晰简洁描述
 
-**截图**
+**如何复现**
+1. 前往XXX页面
+2. ...
+
+**日志**
+强烈建议附上在 `域名/admin/logs` 中的报错日志。
+
+**错误截图**
+如果适用,请添加屏幕截图以帮助解释您的问题
+
+**信息**
+- 面板版本:[例如 Release 2.5.1]
+
+**额外信息**

+ 7 - 0
.github/ISSUE_TEMPLATE/config.yml.txt

@@ -0,0 +1,7 @@
+contact_links:
+  - name: Telegram Channel
+    url: https://t.me/proxypanel
+    about: Telegram Channel
+  - name: Telegram Group
+    url: https://t.me/joinchat/GUrO5hZsT3FOd79HAa9pcA
+    about: Telegram Group

+ 15 - 0
.github/ISSUE_TEMPLATE/feature-request.md

@@ -0,0 +1,15 @@
+---
+name: 功能请求 - Feature request
+about: 对项目的建议与想法
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+**确保你已经看过 readme,也搜索并阅读过和你遇到的情况相关的问题。否则会被认为是重复的并被立刻关闭。**
+
+**功能描述 | Feature request description**
+简明扼要地描述需要的功能
+
+**相关资料/额外想法 | Related documents**

+ 0 - 12
.github/ISSUE_TEMPLATE/feature_request.md

@@ -1,12 +0,0 @@
----
-name: Feature request
-about: 新功能请求 Feature request
-title: ''
-labels: enhancement
-assignees: ''
-
----
-
-**功能描述 | Feature request description**
-
-**相关资料/想法 | Related documents**

+ 0 - 19
app/Components/Helpers.php

@@ -245,25 +245,6 @@ class Helpers
         return $log->save();
     }
 
-    /**
-     * 添加用户封禁日志.
-     *
-     * @param  int  $userId  用户ID
-     * @param  int  $time  封禁时长,单位分钟
-     * @param  string  $description  封禁理由
-     *
-     * @return bool
-     */
-    public static function addUserBanLog(int $userId, int $time, string $description)
-    {
-        $log = new UserBanedLog();
-        $log->user_id = $userId;
-        $log->time = $time;
-        $log->description = $description;
-
-        return $log->save();
-    }
-
     /**
      * 推销信息推送
      *

+ 2 - 6
app/Observers/ConfigObserver.php

@@ -3,16 +3,12 @@
 namespace App\Observers;
 
 use App\Models\Config;
-use Artisan;
+use Cache;
 
 class ConfigObserver
 {
     public function updated(Config $config) // 更新设定
     {
-        if (config('app.debug')) {
-            Artisan::call('optimize:clear');
-        } else {
-            Artisan::call('optimize');
-        }
+        Cache::forget('settings');
     }
 }