request = $request; $this->companyCountService = $companyCountService; } /** * 列表. * * @return \Illuminate\Http\Response */ public function index() { $conditions = $this->request->all(); $res = $this->companyCountService->index($conditions); return res($res, '企业统计', 201); } /** * 导出. * * @return \Illuminate\Http\Response */ public function export() { $conditions = $this->request->all(); $conditions['limit'] = 0; try { $export = new CompanyCountExport($conditions); $url = ExportService::store($export, $this->disk); } catch (\Exception $e) { return err('导出失败,请稍后重试'); } return res($url, '导出成功', 201); } }