Completed
Pull Request — master (#6)
by Florian
02:37
created
Model/Api/Request/Genericpayment/PayPalExpress.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -48,10 +48,10 @@
 block discarded – undo
48 48
     {
49 49
         $this->addParameter('request', 'genericpayment');
50 50
         $this->addParameter('mode', $oPayment->getOperationMode());
51
-        $this->addParameter('aid', $this->shopHelper->getConfigParam('aid'));// ID of PayOne Sub-Account
51
+        $this->addParameter('aid', $this->shopHelper->getConfigParam('aid')); // ID of PayOne Sub-Account
52 52
         $this->addParameter('clearingtype', 'wlt');
53 53
         $this->addParameter('wallettype', 'PPE');
54
-        $this->addParameter('amount', number_format($oQuote->getGrandTotal(), 2, '.', '')*100);
54
+        $this->addParameter('amount', number_format($oQuote->getGrandTotal(), 2, '.', '') * 100);
55 55
         $this->addParameter('currency', $oQuote->getQuoteCurrencyCode());
56 56
         $this->addParameter('narrative_text', 'Test');
57 57
 
Please login to merge, or discard this patch.
Model/Api/Request/AddressRequest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
     {
78 78
         $sPre = '';
79 79
         if ($blIsShipping === true) {
80
-            $sPre = 'shipping_';// add shipping prefix for shipping addresses
80
+            $sPre = 'shipping_'; // add shipping prefix for shipping addresses
81 81
         }
82 82
         $this->addParameter($sPre.'firstname', $oAddress->getFirstname());
83 83
         $this->addParameter($sPre.'lastname', $oAddress->getLastname());
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
         }
87 87
 
88 88
         $aStreet = $oAddress->getStreet();
89
-        $sStreet = is_array($aStreet) ? implode(' ', $aStreet) : $aStreet;// street may be an array
89
+        $sStreet = is_array($aStreet) ? implode(' ', $aStreet) : $aStreet; // street may be an array
90 90
         $this->addParameter($sPre.'street', trim($sStreet));
91 91
         $this->addParameter($sPre.'zip', $oAddress->getPostcode());
92 92
         $this->addParameter($sPre.'city', $oAddress->getCity());
Please login to merge, or discard this patch.
Model/Api/Request/Managemandate.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -77,8 +77,8 @@
 block discarded – undo
77 77
         $oCustomer = $oQuote->getCustomer();
78 78
 
79 79
         $this->addParameter('request', 'managemandate'); // Request method
80
-        $this->addParameter('mode', $oPayment->getOperationMode());// PayOne Portal Operation Mode (live or test)
81
-        $this->addParameter('aid', $this->shopHelper->getConfigParam('aid'));// ID of PayOne Sub-Account
80
+        $this->addParameter('mode', $oPayment->getOperationMode()); // PayOne Portal Operation Mode (live or test)
81
+        $this->addParameter('aid', $this->shopHelper->getConfigParam('aid')); // ID of PayOne Sub-Account
82 82
         $this->addParameter('clearingtype', 'elv');
83 83
 
84 84
         $this->addParameter('customerid', $oCustomer->getId());
Please login to merge, or discard this patch.
Model/Api/Request/Getfile.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -65,7 +65,7 @@
 block discarded – undo
65 65
                 'content' => http_build_query($this->aParameters),
66 66
             ],
67 67
         ];
68
-        $oContext  = stream_context_create($aOptions);
68
+        $oContext = stream_context_create($aOptions);
69 69
         $sMandate = file_get_contents($this->sApiUrl, false, $oContext);
70 70
         if ($sMandate !== false) {
71 71
             $sReturn = $sMandate;
Please login to merge, or discard this patch.
Model/Api/Request/Base.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -120,14 +120,14 @@  discard block
 block discarded – undo
120 120
      */
121 121
     protected function initRequest()
122 122
     {
123
-        $this->addParameter('mid', $this->shopHelper->getConfigParam('mid'));// PayOne Merchant ID
124
-        $this->addParameter('portalid', $this->shopHelper->getConfigParam('portalid'));// PayOne Portal ID
125
-        $this->addParameter('key', md5($this->shopHelper->getConfigParam('key')));// PayOne Portal Key
126
-        $this->addParameter('encoding', $this->environmentHelper->getEncoding());// Encoding
127
-        $this->addParameter('integrator_name', 'Magento2');// Shop-system
128
-        $this->addParameter('integrator_version', $this->shopHelper->getMagentoVersion());// Shop version
129
-        $this->addParameter('solution_name', 'fatchip');// Company developing the module
130
-        $this->addParameter('solution_version', PayoneConfig::MODULE_VERSION);// Module version
123
+        $this->addParameter('mid', $this->shopHelper->getConfigParam('mid')); // PayOne Merchant ID
124
+        $this->addParameter('portalid', $this->shopHelper->getConfigParam('portalid')); // PayOne Portal ID
125
+        $this->addParameter('key', md5($this->shopHelper->getConfigParam('key'))); // PayOne Portal Key
126
+        $this->addParameter('encoding', $this->environmentHelper->getEncoding()); // Encoding
127
+        $this->addParameter('integrator_name', 'Magento2'); // Shop-system
128
+        $this->addParameter('integrator_version', $this->shopHelper->getMagentoVersion()); // Shop version
129
+        $this->addParameter('solution_name', 'fatchip'); // Company developing the module
130
+        $this->addParameter('solution_version', PayoneConfig::MODULE_VERSION); // Module version
131 131
     }
132 132
 
133 133
     /**
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
     public function addParameter($sKey, $sValue, $blAddAsNullIfEmpty = false)
142 142
     {
143 143
         if ($blAddAsNullIfEmpty === true && empty($sValue)) {
144
-            $sValue = 'NULL';// add value as string NULL - needed in certain situations
144
+            $sValue = 'NULL'; // add value as string NULL - needed in certain situations
145 145
         }
146 146
         $this->aParameters[$sKey] = $sValue;
147 147
     }
@@ -251,8 +251,8 @@  discard block
 block discarded – undo
251 251
             return $sRequestUrl;
252 252
         }
253 253
 
254
-        $aResponse = $this->apiHelper->sendApiRequest($sRequestUrl);// send request to PAYONE
255
-        $this->apiLog->addApiLogEntry($this, $aResponse, $aResponse['status']);// log request to db
254
+        $aResponse = $this->apiHelper->sendApiRequest($sRequestUrl); // send request to PAYONE
255
+        $this->apiLog->addApiLogEntry($this, $aResponse, $aResponse['status']); // log request to db
256 256
         return $aResponse;
257 257
     }
258 258
 }
Please login to merge, or discard this patch.
Model/Entities/TransactionStatus.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -75,7 +75,7 @@
 block discarded – undo
75 75
         $sRequest = $this->getData($sKey);
76 76
         if ($sRequest) {
77 77
             if (Toolkit::isUTF8($sRequest)) {
78
-                $sRequest = utf8_decode($sRequest);// needed for unserializing the array
78
+                $sRequest = utf8_decode($sRequest); // needed for unserializing the array
79 79
             }
80 80
             $aRequest = unserialize($sRequest);
81 81
             if (is_array($aRequest)) {
Please login to merge, or discard this patch.
Model/UiComponent/DataProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
         array $meta = [],
71 71
         array $data = []
72 72
     ) {
73
-        $this->databaseHelper = $databaseHelper;// needs to be in front of constructor, doesnt work otherwise for no apparent reason
73
+        $this->databaseHelper = $databaseHelper; // needs to be in front of constructor, doesnt work otherwise for no apparent reason
74 74
         parent::__construct($name, $primaryFieldName, $requestFieldName, $reporting, $searchCritBuilder, $request, $filterBuilder, $meta, $data);
75 75
     }
76 76
 
Please login to merge, or discard this patch.
Model/PayoneConfig.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -58,8 +58,8 @@
 block discarded – undo
58 58
     const TRANSACTIONSTATUS_REMINDER = 'reminder';
59 59
     const TRANSACTIONSTATUS_VAUTHORIZATION = 'vauthorization';
60 60
     const TRANSACTIONSTATUS_VSETTLEMENT = 'vsettlement';
61
-    const TRANSACTIONSTATUS_TRANSFER= 'transfer';
62
-    const TRANSACTIONSTATUS_INVOICE= 'invoice';
61
+    const TRANSACTIONSTATUS_TRANSFER = 'transfer';
62
+    const TRANSACTIONSTATUS_INVOICE = 'invoice';
63 63
 
64 64
     /* Payment method codes */
65 65
     const METHOD_CREDITCARD = 'payone_creditcard';
Please login to merge, or discard this patch.
Model/ResourceModel/TransactionStatus.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -108,7 +108,7 @@
 block discarded – undo
108 108
         $aRequest = $oContext->getRequest()->getPostValue();
109 109
         $sRawStatus = serialize($aRequest);
110 110
         if (!Toolkit::isUTF8($sRawStatus)) {
111
-            $sRawStatus = utf8_encode($sRawStatus);// needed for serializing the array
111
+            $sRawStatus = utf8_encode($sRawStatus); // needed for serializing the array
112 112
         }
113 113
         $sOrderId = $oOrder !== null ? $oOrder->getIncrementId() : '';
114 114
         $this->getConnection()->insert(
Please login to merge, or discard this patch.