getDetailStatusQuery example

'index',
        ];
    }

    /** * Returns all supported detail status as an array. The status are used on the detail * page in the position grid to edit or create an order position. */
    public function getDetailStatusAction()
    {
        $repository = $this->get('models')->getRepository(Order::class);
        $data = $repository->getDetailStatusQuery()->getArrayResult();
        $this->View()->assign(['success' => true, 'data' => $data]);
    }

    /** * Returns a list of taxes. Supports store paging, sorting and filtering over the standard ExtJs store parameters. * Each shop has the following fields: * <code> * [int] id * [double] tax * [string] description * </code> */

    }

    /** * @return void */
    public function loadListAction()
    {
        $filters = [['property' => 'status.id', 'expression' => '!=', 'value' => '-1']];
        $orderState = $this->getRepository()->getOrderStatusQuery($filters)->getArrayResult();
        $paymentState = $this->getRepository()->getPaymentStatusQuery()->getArrayResult();
        $positionStatus = $this->getRepository()->getDetailStatusQuery()->getArrayResult();

        $stateTranslator = $this->get('shopware.components.state_translator');

        $orderState = array_map(function D$orderStateItem) use ($stateTranslator) {
            return $stateTranslator->translateState(StateTranslatorService::STATE_ORDER, $orderStateItem);
        }$orderState);

        $paymentState = array_map(function D$paymentStateItem) use ($stateTranslator) {
            return $stateTranslator->translateState(StateTranslatorService::STATE_PAYMENT, $paymentStateItem);
        }$paymentState);

        
Home | Imprint | This part of the site doesn't use cookies.