From 753b1a5f4a43db9cec503d2088be524f8cdb9966 Mon Sep 17 00:00:00 2001 From: XiaoLFeng Date: Fri, 21 Jul 2023 13:49:55 +0800 Subject: [PATCH] =?UTF-8?q?Modify:=20=E6=B7=BB=E5=8A=A0=E5=8F=8B=E9=93=BE?= =?UTF-8?q?=E6=A8=A1=E5=9D=97=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 友链添加Js优化,优化检查模块,添加简单机制 修改: - Index.php - link-console-add.blade.php - make-friend.blade.php Signed-off-by: XiaoLFeng --- app/Http/Controllers/Function/Link.php | 2 + app/Http/Controllers/Index.php | 2 +- .../views/function/make-friend.blade.php | 90 +++++++++++++++---- .../views/mail/link-console-add.blade.php | 2 +- 4 files changed, 77 insertions(+), 19 deletions(-) diff --git a/app/Http/Controllers/Function/Link.php b/app/Http/Controllers/Function/Link.php index 2d79b83..ec89271 100644 --- a/app/Http/Controllers/Function/Link.php +++ b/app/Http/Controllers/Function/Link.php @@ -819,6 +819,8 @@ protected function viewMakeFriend(): Factory|View|Application ->orderBy('sort') ->get() ->toArray(); + $this->data['applicationRule'] = DB::table('info')->find(15)->data; + $this->data['applicationInfo'] = (new Index())->MarkdownToStringReplace(DB::table('info')->find(16)->data); return view('function.make-friend', $this->data); } diff --git a/app/Http/Controllers/Index.php b/app/Http/Controllers/Index.php index fd6aff8..e0c33be 100644 --- a/app/Http/Controllers/Index.php +++ b/app/Http/Controllers/Index.php @@ -76,7 +76,7 @@ protected function viewNoPermission(): Factory|View|Application return view('modules.no-permission', $this->data); } - private function MarkdownToStringReplace(string $dataBase): string + public function MarkdownToStringReplace(string $dataBase): string { $decodeText = MarkdownExtra::defaultTransform($dataBase); $decodeText = str_replace('

', '

', $decodeText); diff --git a/resources/views/function/make-friend.blade.php b/resources/views/function/make-friend.blade.php index f2c6317..c919c52 100644 --- a/resources/views/function/make-friend.blade.php +++ b/resources/views/function/make-friend.blade.php @@ -171,17 +171,29 @@ class="bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg focus:

- +
- + @@ -236,17 +248,50 @@ class="ml-auto -mx-1.5 -my-1.5 bg-white text-gray-400 hover:text-gray-900 rounde - + +