Completed
Push — master ( 56a686...736967 )
by Oleksandr
15s queued 11s
created

RefundOmsCommand::execute()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 2
dl 0
loc 4
c 1
b 0
f 0
rs 10
cc 1
nc 1
nop 3
1
<?php
2
3
/**
4
 * MIT License
5
 * For full license information, please view the LICENSE file that was distributed with this source code.
6
 */
7
8
namespace SprykerEco\Zed\Heidelpay\Communication\Oms\Command;
9
10
use Orm\Zed\Sales\Persistence\SpySalesOrder;
1 ignored issue
show
Bug introduced by
The type Orm\Zed\Sales\Persistence\SpySalesOrder 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 Spryker\Zed\Oms\Business\Util\ReadOnlyArrayObject;
12
13
class RefundOmsCommand extends BaseOmsCommand implements HeidelpayOmsCommandByOrderInterface
14
{
15
    /**
16
     * @param \Orm\Zed\Sales\Persistence\SpySalesOrderItem[] $salesOrderItems
17
     * @param \Orm\Zed\Sales\Persistence\SpySalesOrder $salesOrderEntity
18
     * @param \Spryker\Zed\Oms\Business\Util\ReadOnlyArrayObject $data
19
     *
20
     * @return void
21
     */
22
    public function execute(array $salesOrderItems, SpySalesOrder $salesOrderEntity, ReadOnlyArrayObject $data): void
23
    {
24
        $orderTransfer = $this->getOrderWithPaymentTransfer($salesOrderEntity->getIdSalesOrder());
25
        $this->heidelpayFacade->executeRefund($orderTransfer);
26
    }
27
}
28