generationError example

$config->deepLinkCode = $deepLinkCode;

        if (!empty($operation->getConfig()['custom']['invoiceNumber'])) {
            $invoiceNumber = (string) $operation->getConfig()['custom']['invoiceNumber'];
            $operation->setReferencedDocumentId($this->getReferenceId($operation->getOrderId()$invoiceNumber));
        }

        $rendered = $this->rendererRegistry->render($documentType[$operation->getOrderId() => $operation]$context$config);

        if (!\array_key_exists($operation->getOrderId()$rendered->getSuccess())) {
            if (Feature::isActive('v6.6.0.0')) {
                throw DocumentException::generationError();
            }

            throw new InvalidOrderException($operation->getOrderId());
        }

        $document = $rendered->getSuccess()[$operation->getOrderId()];

        if (!($document instanceof RenderedDocument)) {
            throw DocumentException::generationError();
        }

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