From 3ea9612ae523c76c146bfd53c6e31eadad4cd979 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=9D=99?= Date: Sun, 24 Apr 2022 10:12:58 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=B9=E9=9B=B6=E6=8F=90=E7=8E=B0=E8=AF=A6?= =?UTF-8?q?=E6=83=85,=E6=98=BE=E7=A4=BA=E7=AE=A1=E7=90=86=E8=80=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/DealerWalletToBankLogController.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/app/Admin/Controllers/DealerWalletToBankLogController.php b/app/Admin/Controllers/DealerWalletToBankLogController.php index f037f506..590878f8 100644 --- a/app/Admin/Controllers/DealerWalletToBankLogController.php +++ b/app/Admin/Controllers/DealerWalletToBankLogController.php @@ -83,7 +83,7 @@ class DealerWalletToBankLogController extends AdminController */ protected function detail($id) { - $builder = DealerWalletToBankLog::with(['user']); + $builder = DealerWalletToBankLog::with(['user', 'managerUserInfo']); return Show::make($id, $builder, function (Show $show) { $show->field('id'); $show->field('user.phone'); @@ -91,6 +91,13 @@ class DealerWalletToBankLogController extends AdminController $show->field('rate')->append('%'); $show->field('service_amount')->prepend('¥'); $show->field('account_amount')->prepend('¥'); + $show->field('manager_id')->unescape()->as(function () { + if ($this->managerUserInfo) { + $href = admin_route('dealers.show', ['dealer_user' => $this->manager_id]); + + return "{$this->managerUserInfo->nickname}"; + } + }); $show->field('status')->unescape()->as(function ($v) { $text = $this->status->text(); $background = $this->status->color();