|
|
|
@ -6,6 +6,7 @@ use App\Controller\BaseController; |
|
|
|
use App\Request\v3\StoreIndexRequest; |
|
|
|
use App\Service\v3\Interfaces\CategoryServiceInterface; |
|
|
|
use App\Service\v3\Interfaces\CollectStoreServiceInterface; |
|
|
|
use App\Service\v3\Interfaces\GoodsServiceInterface; |
|
|
|
use App\Service\v3\Interfaces\StoreServiceInterface; |
|
|
|
use Hyperf\Di\Annotation\Inject; |
|
|
|
use Psr\Http\Message\ResponseInterface; |
|
|
|
@ -38,6 +39,12 @@ class StoreController extends BaseController |
|
|
|
*/ |
|
|
|
protected $businessHoursService; |
|
|
|
|
|
|
|
/** |
|
|
|
* @Inject |
|
|
|
* @var GoodsServiceInterface |
|
|
|
*/ |
|
|
|
protected $goodsService; |
|
|
|
|
|
|
|
/** |
|
|
|
* 商户详情页 |
|
|
|
* 1、商户id用来查询的,还要有user_id |
|
|
|
@ -82,4 +89,14 @@ class StoreController extends BaseController |
|
|
|
$res = $this->businessHoursService->do($storeId,$isRest,$time1,$time2,$time3,$time4); |
|
|
|
return $this->success($res); |
|
|
|
} |
|
|
|
|
|
|
|
public function getGoodsByType() |
|
|
|
{ |
|
|
|
$storeId = $this->request->input('store_id'); |
|
|
|
$typeId = $this->request->input('type_id',''); |
|
|
|
$page = $this->request->input('page',1); |
|
|
|
$pagesize = $this->request->input('pagesize',10); |
|
|
|
$goods = $this->goodsService->getByType($storeId,$typeId,$page,$pagesize); |
|
|
|
return $this->success($goods); |
|
|
|
} |
|
|
|
} |