Payson - Version 1.2.2

Version Notes

Added a check to make sure that a product options array existed before trying to read from it

Download this release

Release Info

Developer Oscar Villegas
Extension Payson
Version 1.2.2
Comparing to
See all releases


Code changes from version 1.2.1 to 1.2.2

app/code/community/Payson/Payson/Helper/Api.php CHANGED
@@ -13,7 +13,7 @@ class Payson_Payson_Helper_Api {
13
  const PAY_FORWARD_URL = '%s://%s%s.payson.%s/paySecure/';
14
  const APPLICATION_ID = 'Magento';
15
  const MODULE_NAME = 'payson_magento';
16
- const MODULE_VERSION = '1.2.1';
17
  const DEBUG_MODE_MAIL = 'testagent-1@payson.se';
18
  const DEBUG_MODE_AGENT_ID = '1';
19
  const DEBUG_MODE_MD5 = 'fddb19ac-7470-42b6-a91d-072cb1495f0a';
@@ -125,12 +125,15 @@ class Payson_Payson_Helper_Api {
125
  }
126
 
127
  $productOptions = $item->getProductOptions();
128
- foreach ($productOptions['attributes_info'] as $attribute) {
129
- $attributesString .= $attribute['label'] . ": " . $attribute['value'] . ", ";
130
- }
 
 
131
 
132
- if ($attributesString != "") {
133
- $attributesString = substr($attributesString, 0, strlen($attributesString) - 2);
 
134
  }
135
 
136
  $name = $item->getName() . ($attributesString != "" ? " - " . $attributesString : "");
13
  const PAY_FORWARD_URL = '%s://%s%s.payson.%s/paySecure/';
14
  const APPLICATION_ID = 'Magento';
15
  const MODULE_NAME = 'payson_magento';
16
+ const MODULE_VERSION = '1.2.2';
17
  const DEBUG_MODE_MAIL = 'testagent-1@payson.se';
18
  const DEBUG_MODE_AGENT_ID = '1';
19
  const DEBUG_MODE_MD5 = 'fddb19ac-7470-42b6-a91d-072cb1495f0a';
125
  }
126
 
127
  $productOptions = $item->getProductOptions();
128
+
129
+ if (array_key_exists('attributes_info', $productOptions)) {
130
+ foreach ($productOptions['attributes_info'] as $attribute) {
131
+ $attributesString .= $attribute['label'] . ": " . $attribute['value'] . ", ";
132
+ }
133
 
134
+ if ($attributesString != "") {
135
+ $attributesString = substr($attributesString, 0, strlen($attributesString) - 2);
136
+ }
137
  }
138
 
139
  $name = $item->getName() . ($attributesString != "" ? " - " . $attributesString : "");
app/code/community/Payson/Payson/etc/config.xml CHANGED
@@ -2,7 +2,7 @@
2
  <config>
3
  <modules>
4
  <Payson_Payson>
5
- <version>1.2.1</version>
6
  </Payson_Payson>
7
  </modules>
8
  <admin>
2
  <config>
3
  <modules>
4
  <Payson_Payson>
5
+ <version>1.2.2</version>
6
  </Payson_Payson>
7
  </modules>
8
  <admin>
app/etc/modules/Payson_Payson.xml CHANGED
@@ -4,7 +4,7 @@
4
  <Payson_Payson>
5
  <active>true</active>
6
  <codePool>community</codePool>
7
- <version>1.2.1</version>
8
  <depends>
9
  <Mage_Payment />
10
  </depends>
4
  <Payson_Payson>
5
  <active>true</active>
6
  <codePool>community</codePool>
7
+ <version>1.2.2</version>
8
  <depends>
9
  <Mage_Payment />
10
  </depends>
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Payson</name>
4
- <version>1.2.1</version>
5
  <stability>stable</stability>
6
  <license>BSD</license>
7
  <channel>community</channel>
@@ -12,11 +12,11 @@
12
  <description>Make it easy to charge your customers. Chose Payson.&#xD;
13
  &#xD;
14
  This module integrates with Payson and allows you to charge your customers via Invoice, Card and direct bank transfers.</description>
15
- <notes>Fixed an issue with a variable that was not initialized</notes>
16
  <authors><author><name>Daniel Hansen</name><user>PaysonAB</user><email>integration@payson.se</email></author></authors>
17
- <date>2013-11-01</date>
18
- <time>09:17:14</time>
19
- <contents><target name="mage"><dir name="app"><dir name="code"><dir name="community"><dir name="Payson"><dir name="Payson"><dir name="Block"><file name="Form.php" hash="74a8967879fbb6af999f0e513bc91323"/><dir name="Invoice"><file name="Form.php" hash="0d16d91e26b31691267c0a7bdc2a516d"/></dir><dir name="Order"><dir name="Totals"><file name="Fee.php" hash="3e8566e634d68d8df9bb70f597916980"/></dir></dir><dir name="Standard"><file name="Form.php" hash="c715cbec95494a9a26d261992429dff0"/></dir></dir><dir name="Helper"><dir name="Api"><dir name="Response"><file name="Interface.php" hash="51d0ffe7eefaa12eb9b4f2551e9f4259"/><dir name="Standard"><file name="Parameters.php" hash="6965b8259867c23a5e1e682e14491eb2"/></dir><file name="Standard.php" hash="cef827896629364fee49671af879adc3"/><file name="Validate.php" hash="34fb6626af3a6ac06e987c9e10a95796"/></dir></dir><file name="Api.php" hash="bf5d70e2ad93c4916860296b880a50f9"/><file name="Data.php" hash="83ff59b1588c0b0ff8d2f7341589ea59"/></dir><dir name="Model"><file name="Config.php" hash="2886124eac6b444fce7944e06ebf9faf"/><dir name="Method"><file name="Abstract.php" hash="6ea3385160ce437933da158b5d3e0d65"/><file name="Invoice.php" hash="ecfd2883a9f2dc24a6e43f04b6f098e8"/><file name="Standard.php" hash="e79bc4044be332dba6b1bcb28ffd6654"/></dir><dir name="Mysql4"><file name="Setup.php" hash="3075fa047af3d56d6eac609004e6e1cc"/></dir><dir name="Order"><dir name="Creditmemo"><dir name="Total"><file name="Invoice.php" hash="0073a5e3617542107713e4155faa07fe"/></dir></dir><dir name="Invoice"><dir name="Total"><file name="Invoice.php" hash="2a2bb0752543535b27c29668113b67e0"/></dir></dir></dir><dir name="Quote"><dir name="Address"><dir name="Total"><file name="Invoice.php" hash="d85f0abf040163920659d18e16d84a9e"/></dir></dir></dir><file name="Standard.php" hash="2e7fa64c2e561d2fbbd3735935edad43"/><dir name="System"><dir name="Config"><dir name="Source"><file name="Paysondirectmethod.php" hash="23549b49797c4ef2ee312fc4fc5f5000"/></dir></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><dir name="Sales"><dir name="Order"><file name="ShipmentController.php" hash="18d1c17c341f97c233b8ad63f8c321cb"/></dir></dir></dir><file name="CheckoutController.php" hash="1db99c07df583828380c48b34e78b167"/><file name="IpnController.php" hash="e7b092cdd0011a3a1359a084bbaf14ad"/></dir><dir name="etc"><file name="config.xml" hash="e17c4e77f254abcb8518014abc974ac6"/><file name="system.xml" hash="2d95d66bdf13e8b056425a002279fb3b"/></dir><dir name="sql"><dir name="payson_setup"><file name="mysql4-install-0.1.0.php" hash="21cd9fd3436ba1eb2fc20eaaadb42106"/><file name="mysql4-upgrade-0.1.0-0.1.2.php" hash="5bbcb930748e3a87a220c0e9f8448a15"/></dir></dir></dir></dir></dir></dir><dir name="design"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="Payson"><dir name="Payson"><file name="total.phtml" hash="e35a3824cd0f3127e8cf7d03a229fb1a"/></dir></dir><dir name="layout"><file name="Payson.xml" hash=""/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="Payson"><dir name="Payson"><file name="invoice_form.phtml" hash="e492d82844ce8b9dc289ae676e391ca7"/><file name="standard_form.phtml" hash="781286055d322d532496af6c5e320034"/></dir></dir></dir><dir name="layout"><file name="Payson.xml" hash=""/></dir></dir></dir></dir></dir><dir name="etc"><dir name="modules"><file name="Payson_Payson.xml" hash=""/></dir></dir><dir name="locale"><dir name="sv_SE"><file name="Payson_Payson.csv" hash=""/></dir></dir></dir><dir name="skin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="Payson"><dir name="Payson"><file name="payson.gif" hash="638d0055cbc1a4bdc32e9fa1156b722a"/><file name="payson.png" hash="308916345711a4520313c94218c5bda7"/><file name="payson_faktura.png" hash="fa218c9949c05c6f3452d9f4c541da2c"/></dir></dir></dir></dir></dir></dir></target></contents>
20
  <compatible/>
21
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
22
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Payson</name>
4
+ <version>1.2.2</version>
5
  <stability>stable</stability>
6
  <license>BSD</license>
7
  <channel>community</channel>
12
  <description>Make it easy to charge your customers. Chose Payson.&#xD;
13
  &#xD;
14
  This module integrates with Payson and allows you to charge your customers via Invoice, Card and direct bank transfers.</description>
15
+ <notes>Added a check to make sure that a product options array existed before trying to read from it</notes>
16
  <authors><author><name>Daniel Hansen</name><user>PaysonAB</user><email>integration@payson.se</email></author></authors>
17
+ <date>2013-11-04</date>
18
+ <time>06:58:37</time>
19
+ <contents><target name="mage"><dir name="app"><dir name="code"><dir name="community"><dir name="Payson"><dir name="Payson"><dir name="Block"><file name="Form.php" hash="74a8967879fbb6af999f0e513bc91323"/><dir name="Invoice"><file name="Form.php" hash="0d16d91e26b31691267c0a7bdc2a516d"/></dir><dir name="Order"><dir name="Totals"><file name="Fee.php" hash="3e8566e634d68d8df9bb70f597916980"/></dir></dir><dir name="Standard"><file name="Form.php" hash="c715cbec95494a9a26d261992429dff0"/></dir></dir><dir name="Helper"><dir name="Api"><dir name="Response"><file name="Interface.php" hash="51d0ffe7eefaa12eb9b4f2551e9f4259"/><dir name="Standard"><file name="Parameters.php" hash="6965b8259867c23a5e1e682e14491eb2"/></dir><file name="Standard.php" hash="cef827896629364fee49671af879adc3"/><file name="Validate.php" hash="34fb6626af3a6ac06e987c9e10a95796"/></dir></dir><file name="Api.php" hash="88eb7f2beadbfd9dc7e4f27105e7e8a6"/><file name="Data.php" hash="83ff59b1588c0b0ff8d2f7341589ea59"/></dir><dir name="Model"><file name="Config.php" hash="2886124eac6b444fce7944e06ebf9faf"/><dir name="Method"><file name="Abstract.php" hash="6ea3385160ce437933da158b5d3e0d65"/><file name="Invoice.php" hash="ecfd2883a9f2dc24a6e43f04b6f098e8"/><file name="Standard.php" hash="e79bc4044be332dba6b1bcb28ffd6654"/></dir><dir name="Mysql4"><file name="Setup.php" hash="3075fa047af3d56d6eac609004e6e1cc"/></dir><dir name="Order"><dir name="Creditmemo"><dir name="Total"><file name="Invoice.php" hash="0073a5e3617542107713e4155faa07fe"/></dir></dir><dir name="Invoice"><dir name="Total"><file name="Invoice.php" hash="2a2bb0752543535b27c29668113b67e0"/></dir></dir></dir><dir name="Quote"><dir name="Address"><dir name="Total"><file name="Invoice.php" hash="d85f0abf040163920659d18e16d84a9e"/></dir></dir></dir><file name="Standard.php" hash="2e7fa64c2e561d2fbbd3735935edad43"/><dir name="System"><dir name="Config"><dir name="Source"><file name="Paysondirectmethod.php" hash="23549b49797c4ef2ee312fc4fc5f5000"/></dir></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><dir name="Sales"><dir name="Order"><file name="ShipmentController.php" hash="18d1c17c341f97c233b8ad63f8c321cb"/></dir></dir></dir><file name="CheckoutController.php" hash="1db99c07df583828380c48b34e78b167"/><file name="IpnController.php" hash="e7b092cdd0011a3a1359a084bbaf14ad"/></dir><dir name="etc"><file name="config.xml" hash="6eb00bd85327753783bab794f955ae7d"/><file name="system.xml" hash="2d95d66bdf13e8b056425a002279fb3b"/></dir><dir name="sql"><dir name="payson_setup"><file name="mysql4-install-0.1.0.php" hash="21cd9fd3436ba1eb2fc20eaaadb42106"/><file name="mysql4-upgrade-0.1.0-0.1.2.php" hash="5bbcb930748e3a87a220c0e9f8448a15"/></dir></dir></dir></dir></dir></dir><dir name="design"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="Payson"><dir name="Payson"><file name="total.phtml" hash="e35a3824cd0f3127e8cf7d03a229fb1a"/></dir></dir><dir name="layout"><file name="Payson.xml" hash=""/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="Payson"><dir name="Payson"><file name="invoice_form.phtml" hash="e492d82844ce8b9dc289ae676e391ca7"/><file name="standard_form.phtml" hash="781286055d322d532496af6c5e320034"/></dir></dir></dir><dir name="layout"><file name="Payson.xml" hash=""/></dir></dir></dir></dir></dir><dir name="etc"><dir name="modules"><file name="Payson_Payson.xml" hash=""/></dir></dir><dir name="locale"><dir name="sv_SE"><file name="Payson_Payson.csv" hash=""/></dir></dir></dir><dir name="skin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="Payson"><dir name="Payson"><file name="payson.gif" hash="638d0055cbc1a4bdc32e9fa1156b722a"/><file name="payson.png" hash="308916345711a4520313c94218c5bda7"/><file name="payson_faktura.png" hash="fa218c9949c05c6f3452d9f4c541da2c"/></dir></dir></dir></dir></dir></dir></target></contents>
20
  <compatible/>
21
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
22
  </package>