From 8bdaee161a3f6e28ebac3409f714d9c54ebc5207 Mon Sep 17 00:00:00 2001 From: cody <648753004@qq.com> Date: Mon, 7 Jul 2025 14:55:10 +0800 Subject: [PATCH] update --- app/Http/Controllers/Admin/BaseController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Controllers/Admin/BaseController.php b/app/Http/Controllers/Admin/BaseController.php index 0ca5e2a..b2b2918 100755 --- a/app/Http/Controllers/Admin/BaseController.php +++ b/app/Http/Controllers/Admin/BaseController.php @@ -50,7 +50,7 @@ class BaseController extends CommonController public function index() { $all = request()->all(); - $list = $this->model->with(underlineToHump($all['show_relation'] ?? []))->where(function ($query) use ($all) { + $list = $this->model->withCount('emailRecords')->with(underlineToHump($all['show_relation'] ?? []))->where(function ($query) use ($all) { if (isset($all['filter']) && !empty($all['filter'])) { foreach ($all['filter'] as $condition) { $key = $condition['key'] ?? null;