Code Duplication    Length = 16-16 lines in 3 locations

src/Eccube/Service/CsvExportService.php 3 locations

@@ 394-409 (lines=16) @@
391
     *
392
     * @return \Doctrine\ORM\QueryBuilder
393
     */
394
    public function getOrderQueryBuilder(Request $request)
395
    {
396
        $session = $request->getSession();
397
        $builder = $this->formFactory
398
            ->createBuilder(SearchOrderType::class);
399
        $searchForm = $builder->getForm();
400
401
        $viewData = $session->get('eccube.admin.order.search', []);
402
        $searchData = FormUtil::submitAndGetData($searchForm, $viewData);
403
404
        // 受注データのクエリビルダを構築.
405
        $qb = $this->orderRepository
406
            ->getQueryBuilderBySearchDataForAdmin($searchData);
407
408
        return $qb;
409
    }
410
411
    /**
412
     * 会員検索用のクエリビルダを返す.
@@ 418-433 (lines=16) @@
415
     *
416
     * @return \Doctrine\ORM\QueryBuilder
417
     */
418
    public function getCustomerQueryBuilder(Request $request)
419
    {
420
        $session = $request->getSession();
421
        $builder = $this->formFactory
422
            ->createBuilder(SearchCustomerType::class);
423
        $searchForm = $builder->getForm();
424
425
        $viewData = $session->get('eccube.admin.customer.search', []);
426
        $searchData = FormUtil::submitAndGetData($searchForm, $viewData);
427
428
        // 会員データのクエリビルダを構築.
429
        $qb = $this->customerRepository
430
            ->getQueryBuilderBySearchData($searchData);
431
432
        return $qb;
433
    }
434
435
    /**
436
     * 商品検索用のクエリビルダを返す.
@@ 442-457 (lines=16) @@
439
     *
440
     * @return \Doctrine\ORM\QueryBuilder
441
     */
442
    public function getProductQueryBuilder(Request $request)
443
    {
444
        $session = $request->getSession();
445
        $builder = $this->formFactory
446
            ->createBuilder(SearchProductType::class);
447
        $searchForm = $builder->getForm();
448
449
        $viewData = $session->get('eccube.admin.product.search', []);
450
        $searchData = FormUtil::submitAndGetData($searchForm, $viewData);
451
452
        // 商品データのクエリビルダを構築.
453
        $qb = $this->productRepository
454
            ->getQueryBuilderBySearchDataForAdmin($searchData);
455
456
        return $qb;
457
    }
458
}
459