| @@ 318-340 (lines=23) @@ | ||
| 315 | $page_count = $this->appConfig['default_page_count']; |
|
| 316 | $session = $this->session; |
|
| 317 | ||
| 318 | if ('POST' === $request->getMethod()) { |
|
| 319 | ||
| 320 | $page_no = 1; |
|
| 321 | ||
| 322 | $searchData = array( |
|
| 323 | 'id' => $request->get('id'), |
|
| 324 | ); |
|
| 325 | ||
| 326 | if ($categoryId = $request->get('category_id')) { |
|
| 327 | $Category = $this->categoryRepository->find($categoryId); |
|
| 328 | $searchData['category_id'] = $Category; |
|
| 329 | } |
|
| 330 | ||
| 331 | $session->set('eccube.admin.order.product.search', $searchData); |
|
| 332 | $session->set('eccube.admin.order.product.search.page_no', $page_no); |
|
| 333 | } else { |
|
| 334 | $searchData = (array)$session->get('eccube.admin.order.product.search'); |
|
| 335 | if (is_null($page_no)) { |
|
| 336 | $page_no = intval($session->get('eccube.admin.order.product.search.page_no')); |
|
| 337 | } else { |
|
| 338 | $session->set('eccube.admin.order.product.search.page_no', $page_no); |
|
| 339 | } |
|
| 340 | } |
|
| 341 | // TODO OrderItemRepository に移動 |
|
| 342 | $qb = $this->orderItemRepository->createQueryBuilder('s') |
|
| 343 | ->where('s.Shipping is null AND s.Order is not null') |
|
| @@ 592-614 (lines=23) @@ | ||
| 589 | $page_count = $this->appConfig['default_page_count']; |
|
| 590 | $session = $this->session; |
|
| 591 | ||
| 592 | if ('POST' === $request->getMethod()) { |
|
| 593 | ||
| 594 | $page_no = 1; |
|
| 595 | ||
| 596 | $searchData = array( |
|
| 597 | 'id' => $request->get('id'), |
|
| 598 | ); |
|
| 599 | ||
| 600 | if ($categoryId = $request->get('category_id')) { |
|
| 601 | $Category = $this->categoryRepository->find($categoryId); |
|
| 602 | $searchData['category_id'] = $Category; |
|
| 603 | } |
|
| 604 | ||
| 605 | $session->set('eccube.admin.order.product.search', $searchData); |
|
| 606 | $session->set('eccube.admin.order.product.search.page_no', $page_no); |
|
| 607 | } else { |
|
| 608 | $searchData = (array)$session->get('eccube.admin.order.product.search'); |
|
| 609 | if (is_null($page_no)) { |
|
| 610 | $page_no = intval($session->get('eccube.admin.order.product.search.page_no')); |
|
| 611 | } else { |
|
| 612 | $session->set('eccube.admin.order.product.search.page_no', $page_no); |
|
| 613 | } |
|
| 614 | } |
|
| 615 | ||
| 616 | $qb = $this->productRepository |
|
| 617 | ->getQueryBuilderBySearchDataForAdmin($searchData); |
|