|
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\Easycredit\Persistence\Mapper; |
|
9
|
|
|
|
|
10
|
|
|
use Generated\Shared\Transfer\PaymentEasycreditApiLogTransfer; |
|
|
|
|
|
|
11
|
|
|
use Generated\Shared\Transfer\PaymentEasycreditOrderIdentifierTransfer; |
|
|
|
|
|
|
12
|
|
|
use Orm\Zed\Easycredit\Persistence\SpyPaymentEasycreditApiLog; |
|
|
|
|
|
|
13
|
|
|
use Orm\Zed\Easycredit\Persistence\SpyPaymentEasycreditOrderIdentifier; |
|
|
|
|
|
|
14
|
|
|
|
|
15
|
|
|
class EasycreditPersistenceMapper implements EasycreditPersistenceMapperInterface |
|
16
|
|
|
{ |
|
17
|
|
|
/** |
|
18
|
|
|
* @param \Generated\Shared\Transfer\PaymentEasycreditApiLogTransfer $easycreditApiLogTransfer |
|
19
|
|
|
* @param \Orm\Zed\Easycredit\Persistence\SpyPaymentEasycreditApiLog $paymentEasycreditApiLogEntity |
|
20
|
|
|
* |
|
21
|
|
|
* @return \Orm\Zed\Easycredit\Persistence\SpyPaymentEasycreditApiLog |
|
22
|
|
|
*/ |
|
23
|
|
|
public function mapPaymentEasycreditApiLogTransferToEntity( |
|
24
|
|
|
PaymentEasycreditApiLogTransfer $easycreditApiLogTransfer, |
|
25
|
|
|
SpyPaymentEasycreditApiLog $paymentEasycreditApiLogEntity |
|
26
|
|
|
): SpyPaymentEasycreditApiLog { |
|
27
|
|
|
$paymentEasycreditApiLogEntity->fromArray($easycreditApiLogTransfer->modifiedToArray()); |
|
28
|
|
|
$paymentEasycreditApiLogEntity->setNew($easycreditApiLogTransfer->getIdPaymentEasycreditApiLog() === null); |
|
29
|
|
|
|
|
30
|
|
|
return $paymentEasycreditApiLogEntity; |
|
31
|
|
|
} |
|
32
|
|
|
|
|
33
|
|
|
/** |
|
34
|
|
|
* @param \Orm\Zed\Easycredit\Persistence\SpyPaymentEasycreditApiLog $paymentEasycreditApiLogEntity |
|
35
|
|
|
* @param \Generated\Shared\Transfer\PaymentEasycreditApiLogTransfer $easycreditApiLogTransfer |
|
36
|
|
|
* |
|
37
|
|
|
* @return \Generated\Shared\Transfer\PaymentEasycreditApiLogTransfer |
|
38
|
|
|
*/ |
|
39
|
|
|
public function mapEntityToPaymentEasycreditApiLogTransfer( |
|
40
|
|
|
SpyPaymentEasycreditApiLog $paymentEasycreditApiLogEntity, |
|
41
|
|
|
PaymentEasycreditApiLogTransfer $easycreditApiLogTransfer |
|
42
|
|
|
): PaymentEasycreditApiLogTransfer { |
|
43
|
|
|
return $easycreditApiLogTransfer->fromArray($paymentEasycreditApiLogEntity->toArray(), true); |
|
44
|
|
|
} |
|
45
|
|
|
|
|
46
|
|
|
/** |
|
47
|
|
|
* @param \Generated\Shared\Transfer\PaymentEasycreditOrderIdentifierTransfer $paymentEasycreditOrderIdentifierTransfer |
|
48
|
|
|
* @param \Orm\Zed\Easycredit\Persistence\SpyPaymentEasycreditOrderIdentifier $paymentEasycreditOrderIdentifierEntity |
|
49
|
|
|
* |
|
50
|
|
|
* @return \Orm\Zed\Easycredit\Persistence\SpyPaymentEasycreditOrderIdentifier |
|
51
|
|
|
*/ |
|
52
|
|
|
public function mapEasycreditOrderIdentifierTransferToEntity( |
|
53
|
|
|
PaymentEasycreditOrderIdentifierTransfer $paymentEasycreditOrderIdentifierTransfer, |
|
54
|
|
|
SpyPaymentEasycreditOrderIdentifier $paymentEasycreditOrderIdentifierEntity |
|
55
|
|
|
): SpyPaymentEasycreditOrderIdentifier { |
|
56
|
|
|
$paymentEasycreditOrderIdentifierEntity->fromArray($paymentEasycreditOrderIdentifierTransfer->modifiedToArray()); |
|
57
|
|
|
$paymentEasycreditOrderIdentifierEntity->setNew($paymentEasycreditOrderIdentifierTransfer->getIdPaymentEasycreditOrderIdentifier() === null); |
|
58
|
|
|
|
|
59
|
|
|
return $paymentEasycreditOrderIdentifierEntity; |
|
60
|
|
|
} |
|
61
|
|
|
|
|
62
|
|
|
/** |
|
63
|
|
|
* @param \Orm\Zed\Easycredit\Persistence\SpyPaymentEasycreditOrderIdentifier $paymentEasycreditOrderIdentifierEntity |
|
64
|
|
|
* @param \Generated\Shared\Transfer\PaymentEasycreditOrderIdentifierTransfer $paymentEasycreditOrderIdentifierTransfer |
|
65
|
|
|
* |
|
66
|
|
|
* @return \Generated\Shared\Transfer\PaymentEasycreditOrderIdentifierTransfer |
|
67
|
|
|
*/ |
|
68
|
|
|
public function mapEntityToSpyPaymentEasycreditOrderIdentifierTransfer( |
|
69
|
|
|
SpyPaymentEasycreditOrderIdentifier $paymentEasycreditOrderIdentifierEntity, |
|
70
|
|
|
PaymentEasycreditOrderIdentifierTransfer $paymentEasycreditOrderIdentifierTransfer |
|
71
|
|
|
): PaymentEasycreditOrderIdentifierTransfer { |
|
72
|
|
|
return $paymentEasycreditOrderIdentifierTransfer->fromArray($paymentEasycreditOrderIdentifierEntity->toArray(), true); |
|
73
|
|
|
} |
|
74
|
|
|
} |
|
75
|
|
|
|
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:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths