From dce7e1daadcfa4215ac99c5dcc063f6b15baffa8 Mon Sep 17 00:00:00 2001 From: Yuka Higashide Date: Thu, 25 Sep 2025 14:11:35 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=9E=E3=82=A4=E3=83=9A=E3=83=BC=E3=82=B8?= =?UTF-8?q?=E3=81=8A=E7=9F=A5=E3=82=89=E3=81=9B=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Http/Controllers/MypageController.php | 8 ++++---- resources/views/mypage/index.blade.php | 11 ++++++++--- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/app/Http/Controllers/MypageController.php b/app/Http/Controllers/MypageController.php index 2fb59c6..a64f0a6 100644 --- a/app/Http/Controllers/MypageController.php +++ b/app/Http/Controllers/MypageController.php @@ -79,11 +79,11 @@ class MypageController extends Controller ->get(); // お知らせ情報を取得 - $informations= DB::table('user_information_history') + $information = DB::table('user_information_history') ->where('user_id', $user_id) ->orderBy('user_information_history_id', 'desc') - ->limit(3) - ->get(); + ->select('entry_date', 'user_information_history') + ->first(); \Log::info('マイページにアクセス', [ 'user_id' => $user_id, @@ -94,7 +94,7 @@ class MypageController extends Controller 'user_name' => $user->user_name, // ユーザー名(ヘッダー用) 'contracts' => $contracts, 'seals' => $seals, - 'informations' => $informations + 'information' => $information ]); } } diff --git a/resources/views/mypage/index.blade.php b/resources/views/mypage/index.blade.php index 2269f75..f31a0b1 100644 --- a/resources/views/mypage/index.blade.php +++ b/resources/views/mypage/index.blade.php @@ -243,9 +243,14 @@ -- 2.47.3