diff --git a/app/Service/Api/Good/OptionalListService.php b/app/Service/Api/Good/OptionalListService.php index 8d36adc..8cc0d10 100644 --- a/app/Service/Api/Good/OptionalListService.php +++ b/app/Service/Api/Good/OptionalListService.php @@ -67,8 +67,9 @@ class OptionalListService extends BaseService if (empty($cycleId)) return $this->return->success('success', ['list' => []]); $this->goodCache->cycleId = (int)$cycleId; - $siteInfo = $this->siteCache->getSiteInfo((int)$this->request->input('site_id')); - + if (!empty($this->request->input('site_id'))){ + $siteInfo = $this->siteCache->getSiteInfo((int)$this->request->input('site_id')); + } if (empty($siteInfo) || empty($siteInfo['kitchen_id'])) $siteInfo['kitchen_id'] = config('system.kitchen_id'); $this->goodCache->kitchenId = (int)$siteInfo['kitchen_id'];