IdealMapper::createTransferWithUnencryptedValues()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 13
Code Lines 7

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 7
c 0
b 0
f 0
dl 0
loc 13
rs 10
cc 1
nc 1
nop 1
1
<?php
2
3
/**
4
 * MIT License
5
 * Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file.
6
 */
7
8
namespace SprykerEco\Yves\Computop\Mapper\Init\PostPlace;
9
10
use Generated\Shared\Transfer\ComputopIdealPaymentTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfe...topIdealPaymentTransfer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
11
use Generated\Shared\Transfer\QuoteTransfer;
0 ignored issues
show
Bug introduced by
The type Generated\Shared\Transfer\QuoteTransfer was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
12
use Spryker\Yves\Router\Router\Router;
13
use SprykerEco\Yves\Computop\Mapper\Init\AbstractMapper;
14
use SprykerEco\Yves\Computop\Plugin\Router\ComputopRouteProviderPlugin;
15
16
class IdealMapper extends AbstractMapper
17
{
18
    /**
19
     * @param \Generated\Shared\Transfer\QuoteTransfer $quoteTransfer
20
     *
21
     * @return \Generated\Shared\Transfer\ComputopIdealPaymentTransfer
22
     */
23
    protected function createTransferWithUnencryptedValues(QuoteTransfer $quoteTransfer)
24
    {
25
        $computopPaymentTransfer = new ComputopIdealPaymentTransfer();
26
27
        $computopPaymentTransfer->setTransId($this->generateTransId($quoteTransfer));
28
        $computopPaymentTransfer->setUrlSuccess(
29
            $this->router->generate(ComputopRouteProviderPlugin::IDEAL_SUCCESS, [], Router::ABSOLUTE_URL)
30
        );
31
        $computopPaymentTransfer->setOrderDesc(
32
            $this->computopApiService->getDescriptionValue($quoteTransfer->getItems()->getArrayCopy())
33
        );
34
35
        return $computopPaymentTransfer;
36
    }
37
}
38