From a81510d29a46a814c22607c0db3e274b819695e4 Mon Sep 17 00:00:00 2001 From: Lemon <15040771@qq.com> Date: Wed, 16 Sep 2020 16:16:09 +0800 Subject: [PATCH] =?UTF-8?q?=E5=95=86=E5=93=81=E8=AF=A6=E6=83=85=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E5=B8=82=E5=9C=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Service/v3/Implementations/GoodsService.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/Service/v3/Implementations/GoodsService.php b/app/Service/v3/Implementations/GoodsService.php index bf240f3..56ff073 100644 --- a/app/Service/v3/Implementations/GoodsService.php +++ b/app/Service/v3/Implementations/GoodsService.php @@ -67,7 +67,9 @@ class GoodsService implements GoodsServiceInterface public function detail($goodsId) { - $res = Goods::query()->with('store')->where('id',$goodsId)->first(); + $res = Goods::query()->with(['store' => function($query){ + $query->with('market'); + }])->where('id',$goodsId)->first(); return $res; } } \ No newline at end of file