diff --git a/app/Controllers/AdminController.php b/app/Controllers/AdminController.php index dbd1e2ef..1a126eef 100644 --- a/app/Controllers/AdminController.php +++ b/app/Controllers/AdminController.php @@ -24,6 +24,11 @@ class AdminController extends BaseController View::show('admin.customize'); } + public function score() + { + View::show('admin.score'); + } + public function options() { View::show('admin.options'); diff --git a/config/menu.php b/config/menu.php index 8eaa6a82..88226415 100644 --- a/config/menu.php +++ b/config/menu.php @@ -18,10 +18,11 @@ $menu['user'] = array( $menu['admin'] = array( 1 => ['title' => '仪表盘', 'link' => '/admin', 'icon' => 'fa-dashboard'], - 2 => ['title' => '用户管理', 'link' => '/admin/users', 'icon' => 'fa-users'], - 3 => ['title' => '角色管理', 'link' => '/admin/players', 'icon' => 'fa-gamepad'], + 2 => ['title' => '用户管理', 'link' => '/admin/users', 'icon' => 'fa-users'], + 3 => ['title' => '角色管理', 'link' => '/admin/players', 'icon' => 'fa-gamepad'], 4 => ['title' => '个性化', 'link' => '/admin/customize', 'icon' => 'fa-paint-brush'], - 5 => ['title' => '站点配置', 'link' => '/admin/options', 'icon' => 'fa-cog'] + 5 => ['title' => '积分配置', 'link' => '/admin/score', 'icon' => 'fa-credit-card'], + 6 => ['title' => '站点配置', 'link' => '/admin/options', 'icon' => 'fa-cog'] ); return $menu; diff --git a/config/routes.php b/config/routes.php index f83f5022..ebdebfb0 100644 --- a/config/routes.php +++ b/config/routes.php @@ -98,6 +98,7 @@ Route::group(['middleware' => 'App\Middlewares\CheckAdminMiddl Route::get('/', 'AdminController@index'); Route::all('/customize', 'AdminController@customize'); + Route::all('/score', 'AdminController@score'); Route::all('/options', 'AdminController@options'); Route::get('/users', 'AdminController@users'); diff --git a/resources/views/admin/options.tpl b/resources/views/admin/options.tpl index 00267488..1215fc4b 100644 --- a/resources/views/admin/options.tpl +++ b/resources/views/admin/options.tpl @@ -4,9 +4,7 @@ @section('style') @endsection @@ -89,15 +87,6 @@ - - 新用户默认积分 - -
- -
- - - 角色名 @@ -125,17 +114,6 @@ - - - 签到间隔时间 - -
- - 小时 -
- - - diff --git a/resources/views/admin/score.tpl b/resources/views/admin/score.tpl new file mode 100644 index 00000000..128d7f62 --- /dev/null +++ b/resources/views/admin/score.tpl @@ -0,0 +1,128 @@ +@extends('admin.master') + +@section('title', '积分配置') + +@section('content') + + +
+ +
+

+ 积分配置 + Score Options +

+
+ + +
+
+
+
+
+

积分换算

+
+
+ +
+ 设置已保存。
'; + } ?> + + + + + + + + + + + + + + + + + +
存储 +
+ + 积分 = 1 KB +
+ +
角色 +
+ + 积分 = 一个角色 +
+
新用户默认积分 + +
+
+ + +
+
+ +
+
+
+

签到配置

+
+
+ +
+ 设置已保存。
'; + } ?> + + + + + + + + + + + + +
签到获得积分 +
+ + 积分 ~ + + 积分 +
+ +
签到间隔时间 +
+ + 小时 +
+ +
+
+ + +
+
+ + + + + +@endsection diff --git a/resources/views/user/index.tpl b/resources/views/user/index.tpl index 18415ea2..aac57f87 100644 --- a/resources/views/user/index.tpl +++ b/resources/views/user/index.tpl @@ -105,17 +105,18 @@

为了不出现用户一个劲上传材质导致存储空间爆满,我们决定启用积分系统。

添加角色以及上传材质都会消耗积分,而删除已经添加的角色和已上传的材质时积分将会被返还。

-

本站用户初始积分为 {{ \Option::get('user_initial_score') }},每日签到可以随机获得 10~100 积分

+ +

本站用户初始积分为 {{ \Option::get('user_initial_score') }},每日签到可以随机获得 {{ $sign_score[0] }} ~ {{ $sign_score[1] }} 积分

添加皮肤库里的材质到衣柜不消耗积分。


-

1 积分 = 1 KB 存储空间

+

{{ Option::get('score_per_storage') }} 积分 = 1 KB 存储空间

-

100 积分 = 1 个角色

+

{{ Option::get('score_per_player') }} 积分 = 1 个角色