Operation list All

List TaxClasss

@param  PageRequest $page_request  (optional)

@throws \\ApiException on non-2xx response
@throws \InvalidArgumentException
@return \\Resources\page[TaxClass]
432104
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllTaxClasses(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllTaxClasses();
        }
    }
538084
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllStripeGateways(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllStripeGateways();
        }
    }
74568
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllCategories(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllCategories();
        }
    }
759214
public function indexAction(Request $request)
    {
        $page = $request->get("page", 1);
        $em = $this->getDoctrine()->getManager();

        $filter = [
            'q' => $request->get('q'),
            'category' => $request->get('filter_category'),
            'is_enabled' => $request->get('is_enabled', true),
        ];

        $qb = $em->getRepository(Product::class)->findAllFilteredQB($filter);

        $paginator = $this->get('knp_paginator');
        $pagination = $paginator->paginate($qb, $page, 40);

        return array(
            'pagination' => $pagination,
            'filter' => $filter,
        );
    }
257924
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllCoupons(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllCoupons();
        }
    }
1003458
public function listAction(Request $request)
    {
        $query = $this->addOrganizationFilter($request->query->all());

        return new JsonResponse($this->finder->search(
            $this->getClass(),
            $query,
            []
        ));
    }
826038
public function listAction(Request $request): Response
    {
        $page = $request->query->get('page') ?? 1;

        $pagerfanta = new Pagerfanta(
            new ArrayAdapter($this->roleService->loadRoles())
        );

        $pagerfanta->setMaxPerPage($this->defaultPaginationLimit);
        $pagerfanta->setCurrentPage(min($page, $pagerfanta->getNbPages()));

        /** @var \eZ\Publish\API\Repository\Values\User\Role[] $sectionList */
        $roles = $pagerfanta->getCurrentPageResults();

        $rolesNumbers = array_column($roles, 'id');

        $rolesDeleteData = new RolesDeleteData(
            array_combine($rolesNumbers, array_fill_keys($rolesNumbers, false))
        );

        $rolesDeleteForm = $this->formFactory->deleteRoles($rolesDeleteData);

        return $this->render('@ezdesign/admin/role/list.html.twig', [
            'form_roles_delete' => $rolesDeleteForm->createView(),
            'pager' => $pagerfanta,
            'can_create' => $this->isGranted(new Attribute('role', 'create')),
            'can_delete' => $this->isGranted(new Attribute('role', 'delete')),
            'can_update' => $this->isGranted(new Attribute('role', 'update')),
            'can_assign' => $this->isGranted(new Attribute('role', 'assign')),
        ]);
    }
1136992
private function getRequestedPage(Request $request)
    {
        $pageNumber = $request->query->getInt('page', 1);
        if (!$pageNumber || $pageNumber < 1) {
            $pageNumber = 1;
        }

        return $pageNumber;
    }
1243380
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllGeoZones(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllGeoZones();
        }
    }
806736
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllCountries(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllCountries();
        }
    }
128647
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllGateways(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllGateways();
        }
    }
826109
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllOptionSets(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllOptionSets();
        }
    }
905097
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllShippingMethods(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllShippingMethods();
        }
    }
769789
public function page(Request $request, Application $app, Paginator $paginator)
    {
        return array_merge(
            ['pages' => count($paginator)],
            $this->extractViewParameters($request, ['app', 'paginator'])
        );
    }
1055020
public static function findAll($page_request = null)
    {
        if($page_request != null){
            return self::listAllPaymentCards(['page' => $page_request->getPageNumber(), 'size' => $page_request->getSize() ]);
        }else {
            return self::listAllPaymentCards();
        }
    }
942339
public function listAction(Request $request)
    {
        /** @var ConfiguratorFactory $configuratorFactory */
        $configuratorFactory = $this->getConfiguratorFactory($this->getClassName());
        /** @var CrudConfigurator $crudConfigurator */
        $crudConfigurator = $configuratorFactory->getConfigurator(CrudConfigurator::class);

        $this->isGrantedOr404Error($crudConfigurator, Constants::ACTION_READ);

        /** @var GridConfigurator $gridConfigurator */
        $gridConfigurator = $configuratorFactory->getConfigurator(GridConfigurator::class);
        /* @var PageConfigurator $pageConfigurator */
        $pageConfigurator = $configuratorFactory->getConfigurator(PageConfigurator::class);

        $translator = $this->get('translator');
        $translationDomain = $this->getParameter('symfonyid.admin.translation_domain');

        $template = $crudConfigurator->getTemplate();
        $listTemplate = $request->isXmlHttpRequest() ? $template->getAjaxTemplate() : $template->getList();

        $reflectionModel = new \ReflectionClass($crudConfigurator->getCrud()->getModelClass());
        $filters = $gridConfigurator->getFilters($reflectionModel);

        /** @var View $view */
        $view = $this->get('symfonyid.admin.view.view');
        $view->setParam('page_title', $translator->trans($pageConfigurator->getTitle(), array(), $translationDomain));
        $view->setParam('page_description', $translator->trans($pageConfigurator->getDescription(), array(), $translationDomain));

        /*
         * Translate tentity fields
         */
        $view->setParam('filter_fields', implode(', ', array_map(function ($value) use ($translator, $translationDomain) {
            return $translator->trans(sprintf('entity.fields.%s', $value), array(), $translationDomain);
        }, $filters)));
        $view->setParam('filter_fields_entity', implode(', ', $filters));

        return $this->doList($request, $crudConfigurator, $view, $gridConfigurator->getColumns($reflectionModel), $listTemplate, $gridConfigurator->getGrid()->isFormatNumber());
    }
22376
public function list(
        CustomerFilters $customerFilters = null,
        CustomerRequest $customerRequest = null
    ): PagedCollection {
        $uri = '/v2/customers';
        if ($customerFilters) {
            $params = $customerFilters->getParams();
            if (!empty($params)) {
                $uri .= '?'.http_build_query($params);
            }
        }

        return $this->loadCustomers(
            $uri,
            $customerRequest ?: new CustomerRequest()
        );
    }