ParcelPro_Carrier - Version 1.0.6

Version Notes

Version 1.0.6
Fixed free shipping option

Version 1.0.5
API format changes

Version 1.0.4
FIX: Logs prematurely truncated.

Version 1.0.3
Logging bugfix

Version 1.0.2
Improved logging

Version 1.0.1
Actually use default location for ShipFrom
Some error logging added

Version 1.0.0
New release.

Download this release

Release Info

Developer Parcel Pro, Inc. Joey Chan, Project Lead Jasper Lynn, Project Manager
Extension ParcelPro_Carrier
Version 1.0.6
Comparing to
See all releases


Code changes from version 1.0.5 to 1.0.6

app/code/community/ParcelPro/Carrier/Model/Carrier.php CHANGED
@@ -59,7 +59,7 @@ class ParcelPro_Carrier_Model_Carrier extends Mage_Shipping_Model_Carrier_Abstra
59
  //Mage::log(json_encode($_rawRequest));
60
  $estimatorData = $this->_sendRequest($this->_estimator_path, $_rawRequest, true);
61
 
62
- $rateList = $this->_parseShippingRates($estimatorData);
63
 
64
  if($rateList){
65
  foreach ($rateList as $rate){
@@ -977,7 +977,7 @@ class ParcelPro_Carrier_Model_Carrier extends Mage_Shipping_Model_Carrier_Abstra
977
  }
978
 
979
  }
980
- private function _parseShippingRates($estimatorData){
981
  if(!isset( $estimatorData->Estimator)){
982
  return null;
983
  }
@@ -1005,7 +1005,13 @@ class ParcelPro_Carrier_Model_Carrier extends Mage_Shipping_Model_Carrier_Abstra
1005
  $rate->setMethod($estimator->ServiceCode);
1006
  $rate->setMethodTitle($estimator->ServiceCodeDescription);
1007
 
1008
- $rate->setPrice($estimator->TotalCharges);
 
 
 
 
 
 
1009
  $rate->setCost($estimator->AccessorialsCost);
1010
 
1011
  $rateList[] = $rate;
59
  //Mage::log(json_encode($_rawRequest));
60
  $estimatorData = $this->_sendRequest($this->_estimator_path, $_rawRequest, true);
61
 
62
+ $rateList = $this->_parseShippingRates($estimatorData,$request);
63
 
64
  if($rateList){
65
  foreach ($rateList as $rate){
977
  }
978
 
979
  }
980
+ private function _parseShippingRates($estimatorData,$request){
981
  if(!isset( $estimatorData->Estimator)){
982
  return null;
983
  }
1005
  $rate->setMethod($estimator->ServiceCode);
1006
  $rate->setMethodTitle($estimator->ServiceCodeDescription);
1007
 
1008
+ //$rate->setPrice($estimator->TotalCharges);
1009
+
1010
+ $rate->setPrice($estimator->ServiceCode == $this->getConfigData($this->_freeMethod)
1011
+ && $this->getConfigFlag('free_shipping_enable')
1012
+ && $this->getConfigData('free_shipping_subtotal') <= $request->getBaseSubtotalInclTax()
1013
+ ? '0.00': $estimator->TotalCharges);
1014
+
1015
  $rate->setCost($estimator->AccessorialsCost);
1016
 
1017
  $rateList[] = $rate;
package.xml CHANGED
@@ -1,14 +1,17 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>ParcelPro_Carrier</name>
4
- <version>1.0.5</version>
5
  <stability>stable</stability>
6
  <license uri="https://www.mozilla.org/MPL/2.0/">MPL 2.0</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>Parcel Pro for Magento is a web-based Insured Shipping solution that integrates with your Magento online store, adding Parcel Pro as one of your shipping options. It allows you to set the price of shipping and insurance coverage quickly and easily.</summary>
10
  <description>Parcel Pro for Magento is a web-based Insured Shipping solution that integrates with your Magento online store. It adds Parcel Pro as one of your shipping options, allowing you to set the price of shipping and insurance coverage easily. You must have a Magento store. By having Parcel Pro for Magento installed into your Magento store, you&#x2019;ll have a powerful new option for your customers to choose from when selecting Insured Shipping. With solid integration with your favorite carriers, Parcel Pro for Magento lets your customers check out in a breeze, with the costs of shipping and insurance embedded into your price.</description>
11
- <notes>Version 1.0.5&#xD;
 
 
 
12
  API format changes&#xD;
13
  &#xD;
14
  Version 1.0.4&#xD;
@@ -27,9 +30,9 @@ Some error logging added&#xD;
27
  Version 1.0.0&#xD;
28
  New release.</notes>
29
  <authors><author><name>Parcel Pro, Inc.</name><user>ParcelProInc</user><email>techsupport@parcelpro.com</email></author></authors>
30
- <date>2014-09-26</date>
31
- <time>22:07:48</time>
32
- <contents><target name="magecommunity"><dir name="ParcelPro"><dir name="Carrier"><dir name="Block"><dir name="Adminhtml"><dir name="Button"><dir name="Refresh"><file name="Cms.php" hash="4e17c2e2488321dec06785af3b3c3706"/></dir></dir></dir></dir><dir name="Helper"><file name="Parcelpro.php" hash="473cd2f7f29d2406dbf21930b76a6f99"/></dir><dir name="Model"><file name="Carrier.php" hash="edb06e85da805e8cf8271ac6b289ff96"/><file name="Config.php" hash="1a524a99e831bcbad22ffd50316aec44"/><dir name="Mysql4"><dir name="Config"><file name="Collection.php" hash="60720e05a974b362891d4dba01694132"/></dir><file name="Config.php" hash="ac407fcd7973e28342bc99a24fad7b4a"/></dir><dir name="Resource"><dir name="Mysql4"><file name="Setup.php" hash="4c6b2c661d616ccce831185d30cc340e"/></dir></dir><dir name="Source"><file name="Carriers.php" hash="fbae840c7a2bb07d36f61aab7cf4d960"/><file name="Dropoff.php" hash="ab1c1c54e22ed3f1c628cd2f34b50ea8"/><file name="Fedexmethod.php" hash="1966f6b0e4cb1f5a8cbb8be5a2b38981"/><file name="Freemethod.php" hash="2f590b14abae6718abdd8ab1ebbca2b8"/><file name="Packaging.php" hash="85e5e9416c4ba68bedd12558edafe384"/><file name="Unitofmeasure.php" hash="4048107787504d7aef1b662de777e93d"/><file name="Upsmethod.php" hash="4eed70c1e0f051622251377dd2ffe050"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="RefreshController.php" hash="01dc45dd06e8af8968cce7fbaa554cb9"/></dir><file name="IndexController.php" hash="dd116c50612320505894e151b43a8fcc"/></dir><dir name="etc"><file name="config.xml" hash="2e9655e356b5609e5b50f90c94bb79df"/><file name="system.xml" hash="25e4b2b1e7c61b4bf55d5015d5cab0df"/></dir><dir name="sql"><dir name="carrier_setup"><file name="mysql4-install-1.0.0.php" hash="42faff48ed0752ba42739316ac02e890"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="ParcelPro_Carrier.xml" hash=""/></dir></target></contents>
33
  <compatible/>
34
  <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
35
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>ParcelPro_Carrier</name>
4
+ <version>1.0.6</version>
5
  <stability>stable</stability>
6
  <license uri="https://www.mozilla.org/MPL/2.0/">MPL 2.0</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>Parcel Pro for Magento is a web-based Insured Shipping solution that integrates with your Magento online store, adding Parcel Pro as one of your shipping options. It allows you to set the price of shipping and insurance coverage quickly and easily.</summary>
10
  <description>Parcel Pro for Magento is a web-based Insured Shipping solution that integrates with your Magento online store. It adds Parcel Pro as one of your shipping options, allowing you to set the price of shipping and insurance coverage easily. You must have a Magento store. By having Parcel Pro for Magento installed into your Magento store, you&#x2019;ll have a powerful new option for your customers to choose from when selecting Insured Shipping. With solid integration with your favorite carriers, Parcel Pro for Magento lets your customers check out in a breeze, with the costs of shipping and insurance embedded into your price.</description>
11
+ <notes>Version 1.0.6&#xD;
12
+ Fixed free shipping option&#xD;
13
+ &#xD;
14
+ Version 1.0.5&#xD;
15
  API format changes&#xD;
16
  &#xD;
17
  Version 1.0.4&#xD;
30
  Version 1.0.0&#xD;
31
  New release.</notes>
32
  <authors><author><name>Parcel Pro, Inc.</name><user>ParcelProInc</user><email>techsupport@parcelpro.com</email></author></authors>
33
+ <date>2014-10-14</date>
34
+ <time>18:06:07</time>
35
+ <contents><target name="magecommunity"><dir name="ParcelPro"><dir name="Carrier"><dir name="Block"><dir name="Adminhtml"><dir name="Button"><dir name="Refresh"><file name="Cms.php" hash="4e17c2e2488321dec06785af3b3c3706"/></dir></dir></dir></dir><dir name="Helper"><file name="Parcelpro.php" hash="473cd2f7f29d2406dbf21930b76a6f99"/></dir><dir name="Model"><file name="Carrier.php" hash="4c4c0c06bdad4728cad48817212aa727"/><file name="Config.php" hash="1a524a99e831bcbad22ffd50316aec44"/><dir name="Mysql4"><dir name="Config"><file name="Collection.php" hash="60720e05a974b362891d4dba01694132"/></dir><file name="Config.php" hash="ac407fcd7973e28342bc99a24fad7b4a"/></dir><dir name="Resource"><dir name="Mysql4"><file name="Setup.php" hash="4c6b2c661d616ccce831185d30cc340e"/></dir></dir><dir name="Source"><file name="Carriers.php" hash="fbae840c7a2bb07d36f61aab7cf4d960"/><file name="Dropoff.php" hash="ab1c1c54e22ed3f1c628cd2f34b50ea8"/><file name="Fedexmethod.php" hash="1966f6b0e4cb1f5a8cbb8be5a2b38981"/><file name="Freemethod.php" hash="2f590b14abae6718abdd8ab1ebbca2b8"/><file name="Packaging.php" hash="85e5e9416c4ba68bedd12558edafe384"/><file name="Unitofmeasure.php" hash="4048107787504d7aef1b662de777e93d"/><file name="Upsmethod.php" hash="4eed70c1e0f051622251377dd2ffe050"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="RefreshController.php" hash="01dc45dd06e8af8968cce7fbaa554cb9"/></dir><file name="IndexController.php" hash="dd116c50612320505894e151b43a8fcc"/></dir><dir name="etc"><file name="config.xml" hash="2e9655e356b5609e5b50f90c94bb79df"/><file name="system.xml" hash="25e4b2b1e7c61b4bf55d5015d5cab0df"/></dir><dir name="sql"><dir name="carrier_setup"><file name="mysql4-install-1.0.0.php" hash="42faff48ed0752ba42739316ac02e890"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="ParcelPro_Carrier.xml" hash=""/></dir></target></contents>
36
  <compatible/>
37
  <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
38
  </package>