Mage_Codi - Version 4.2.8

Version Notes

Please contact our support desk if you have any problems.

Download this release

Release Info

Developer Magento Core Team
Extension Mage_Codi
Version 4.2.8
Comparing to
See all releases


Code changes from version 4.2.7 to 4.2.8

app/code/community/Mage/CodiScript/Model/Files.php CHANGED
@@ -1,5 +1,5 @@
1
  <?php
2
- // 2015-05-11
3
  class ConfiguredProductLine{
4
  public $optionIds = array();
5
  public $line = NULL;
@@ -254,8 +254,9 @@ thumbnail: ".$product->getThumbnail()."
254
  $firstImageFile = trim( $product->getImage() );
255
  if( $firstImageFile == "no_selection" )
256
  $firstImageFile = FALSE;
257
- if( $firstImageFile )
258
- $prodImages[] = "MagentoBase#=#".$this->prodmediaurl.$firstImageFile;
 
259
  $prodImageArray = $product->getMediaGallery( 'images' );
260
  if( is_array( $prodImageArray ) ){
261
  foreach( $prodImageArray as $image ){
@@ -266,7 +267,7 @@ thumbnail: ".$product->getThumbnail()."
266
  continue;
267
  if( $this->ignoreexcludedimages && $image['disabled'] )
268
  continue;
269
- $prodImages[] = "Print#=#".$this->prodmediaurl.$imageFile;
270
  }
271
  }
272
  $prodImages = implode( "#|#", $prodImages );
@@ -371,7 +372,7 @@ thumbnail: ".$product->getThumbnail()."
371
  if( $firstImageFile == "no_selection" )
372
  $firstImageFile = FALSE;
373
  if( $firstImageFile )
374
- $itemImages[] = "MagentoBase#=#".$this->prodmediaurl.$firstImageFile;
375
  $itemImageArray = $UsedProduct->getMediaGallery('images');
376
  if( is_array($itemImageArray) ){
377
  foreach( $itemImageArray as $image ){
@@ -382,7 +383,7 @@ thumbnail: ".$product->getThumbnail()."
382
  continue;
383
  if( $this->ignoreexcludedimages && $image['disabled'] )
384
  continue;
385
- $itemImages[] = "Print#=#".$this->prodmediaurl.$imageFile;
386
  }
387
  }
388
  $itemImages = implode( "#|#", $itemImages );
@@ -572,7 +573,7 @@ thumbnail: ".$product->getThumbnail()."
572
  if( $firstImageFile == "no_selection" )
573
  $firstImageFile = FALSE;
574
  if( $firstImageFile )
575
- $prodImages[] = "MagentoBase#=#".$this->prodmediaurl.$firstImageFile;
576
  $prodImageArray = $product->getMediaGallery('images');
577
  if( is_array($prodImageArray) ){
578
  foreach( $prodImageArray as $image ){
@@ -583,7 +584,7 @@ thumbnail: ".$product->getThumbnail()."
583
  continue;
584
  if( $this->ignoreexcludedimages && $image['disabled'] )
585
  continue;
586
- $prodImages[] = "Print#=#".$this->prodmediaurl.$imageFile;
587
  }
588
  }
589
  $prodImages = implode( "#|#", $prodImages );
@@ -878,7 +879,7 @@ thumbnail: ".$UsedProduct->getThumbnail()."
878
  if( $firstImageFile == "no_selection" )
879
  $firstImageFile = FALSE;
880
  if( $firstImageFile )
881
- $itemImages[] = "MagentoBase#=#".$this->prodmediaurl.$firstImageFile;
882
  $itemImageArray = $UsedProduct->getMediaGallery('images');
883
  if( is_array($itemImageArray) ){
884
  foreach( $itemImageArray as $image ){
@@ -889,7 +890,7 @@ thumbnail: ".$UsedProduct->getThumbnail()."
889
  continue;
890
  if( $this->ignoreexcludedimages && $image['disabled'] )
891
  continue;
892
- $itemImages[] = "Print#=#".$this->prodmediaurl.$imageFile;
893
  }
894
  }
895
  $itemImages = implode( "#|#", $itemImages );
@@ -1023,7 +1024,7 @@ thumbnail: ".$product->getThumbnail()."
1023
  if( $firstImageFile == "no_selection" )
1024
  $firstImageFile = FALSE;
1025
  if( $firstImageFile )
1026
- $prodImages[] = "MagentoBase#=#".$this->prodmediaurl.$firstImageFile;
1027
  $prodImageArray = $product->getMediaGallery('images');
1028
  if( is_array( $prodImageArray ) ){
1029
  foreach( $prodImageArray as $image ){
@@ -1034,7 +1035,7 @@ thumbnail: ".$product->getThumbnail()."
1034
  continue;
1035
  if( $this->ignoreexcludedimages && $image['disabled'] )
1036
  continue;
1037
- $prodImages[] = "Print#=#".$this->prodmediaurl.$imageFile;
1038
  }
1039
  }
1040
  $prodImages = implode( "#|#", $prodImages );
@@ -1765,6 +1766,12 @@ ProdRPrice=".$ProdRPrice." ProdSPrice=".$ProdSPrice."
1765
  return $qty;
1766
  }
1767
 
 
 
 
 
 
 
1768
  private function _getTierPrices( &$product ){
1769
  $res="";
1770
  $prices = $product->getFormatedTierPrice();
@@ -2194,4 +2201,4 @@ Products: ".count( $prodIds )."
2194
  unset( $UsedProductIds );
2195
  return $ProducttoString;
2196
  }
2197
- } // Mage_CodiScript_Model_Files
1
  <?php
2
+ // 2015-07-09
3
  class ConfiguredProductLine{
4
  public $optionIds = array();
5
  public $line = NULL;
254
  $firstImageFile = trim( $product->getImage() );
255
  if( $firstImageFile == "no_selection" )
256
  $firstImageFile = FALSE;
257
+ if( $firstImageFile ){
258
+ $prodImages[] = "MagentoBase#=#".$this->prodmediaurl.$this->_formatImageURL( $firstImageFile );
259
+ }
260
  $prodImageArray = $product->getMediaGallery( 'images' );
261
  if( is_array( $prodImageArray ) ){
262
  foreach( $prodImageArray as $image ){
267
  continue;
268
  if( $this->ignoreexcludedimages && $image['disabled'] )
269
  continue;
270
+ $prodImages[] = "Print#=#".$this->prodmediaurl.$this->_formatImageURL( $imageFile );
271
  }
272
  }
273
  $prodImages = implode( "#|#", $prodImages );
372
  if( $firstImageFile == "no_selection" )
373
  $firstImageFile = FALSE;
374
  if( $firstImageFile )
375
+ $itemImages[] = "MagentoBase#=#".$this->prodmediaurl.$this->_formatImageURL( $firstImageFile );
376
  $itemImageArray = $UsedProduct->getMediaGallery('images');
377
  if( is_array($itemImageArray) ){
378
  foreach( $itemImageArray as $image ){
383
  continue;
384
  if( $this->ignoreexcludedimages && $image['disabled'] )
385
  continue;
386
+ $itemImages[] = "Print#=#".$this->prodmediaurl.$this->_formatImageURL( $imageFile );
387
  }
388
  }
389
  $itemImages = implode( "#|#", $itemImages );
573
  if( $firstImageFile == "no_selection" )
574
  $firstImageFile = FALSE;
575
  if( $firstImageFile )
576
+ $prodImages[] = "MagentoBase#=#".$this->prodmediaurl.$this->_formatImageURL( $firstImageFile );
577
  $prodImageArray = $product->getMediaGallery('images');
578
  if( is_array($prodImageArray) ){
579
  foreach( $prodImageArray as $image ){
584
  continue;
585
  if( $this->ignoreexcludedimages && $image['disabled'] )
586
  continue;
587
+ $prodImages[] = "Print#=#".$this->prodmediaurl.$this->_formatImageURL( $imageFile );
588
  }
589
  }
590
  $prodImages = implode( "#|#", $prodImages );
879
  if( $firstImageFile == "no_selection" )
880
  $firstImageFile = FALSE;
881
  if( $firstImageFile )
882
+ $itemImages[] = "MagentoBase#=#".$this->prodmediaurl.$this->_formatImageURL( $firstImageFile );
883
  $itemImageArray = $UsedProduct->getMediaGallery('images');
884
  if( is_array($itemImageArray) ){
885
  foreach( $itemImageArray as $image ){
890
  continue;
891
  if( $this->ignoreexcludedimages && $image['disabled'] )
892
  continue;
893
+ $itemImages[] = "Print#=#".$this->prodmediaurl.$this->_formatImageURL( $imageFile );
894
  }
895
  }
896
  $itemImages = implode( "#|#", $itemImages );
1024
  if( $firstImageFile == "no_selection" )
1025
  $firstImageFile = FALSE;
1026
  if( $firstImageFile )
1027
+ $prodImages[] = "MagentoBase#=#".$this->prodmediaurl.$this->_formatImageURL( $firstImageFile );
1028
  $prodImageArray = $product->getMediaGallery('images');
1029
  if( is_array( $prodImageArray ) ){
1030
  foreach( $prodImageArray as $image ){
1035
  continue;
1036
  if( $this->ignoreexcludedimages && $image['disabled'] )
1037
  continue;
1038
+ $prodImages[] = "Print#=#".$this->prodmediaurl.$this->_formatImageURL( $imageFile );
1039
  }
1040
  }
1041
  $prodImages = implode( "#|#", $prodImages );
1766
  return $qty;
1767
  }
1768
 
1769
+ private function _formatImageURL( $str ){
1770
+ if( $str[0] != '/' )
1771
+ $str = "/".$str;
1772
+ return $str;
1773
+ }
1774
+
1775
  private function _getTierPrices( &$product ){
1776
  $res="";
1777
  $prices = $product->getFormatedTierPrice();
2201
  unset( $UsedProductIds );
2202
  return $ProducttoString;
2203
  }
2204
+ } // Mage_CodiScript_Model_Files
app/code/community/Mage/CodiScript/controllers/IndexController.php CHANGED
@@ -1,5 +1,5 @@
1
  <?php
2
- define("__VERSION__","2015-05-11");
3
  define("__SCRIPTNAME__",basename(__FILE__));
4
 
5
  class Mage_CodiScript_IndexController extends Mage_Core_Controller_Front_Action{
@@ -241,6 +241,9 @@ executed in ".( time() - $started_time )." sec.
241
  ";
242
  die();
243
  /* RELEASE NOTES
 
 
 
244
  * 2015-05-11
245
  * Improved rendering of prices with store-dependent taxes
246
  *
1
  <?php
2
+ define("__VERSION__","2015-07-09");
3
  define("__SCRIPTNAME__",basename(__FILE__));
4
 
5
  class Mage_CodiScript_IndexController extends Mage_Core_Controller_Front_Action{
241
  ";
242
  die();
243
  /* RELEASE NOTES
244
+ * 2015-07-09
245
+ * Improved rendering of image URLs
246
+ *
247
  * 2015-05-11
248
  * Improved rendering of prices with store-dependent taxes
249
  *
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Mage_Codi</name>
4
- <version>4.2.7</version>
5
  <stability>stable</stability>
6
  <license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
  <channel>community</channel>
@@ -10,9 +10,9 @@
10
  <description>Extension to connect to the Catalog-on-Demand service for making print catalogs, brochures, and flyers.</description>
11
  <notes>Please contact our support desk if you have any problems.</notes>
12
  <authors><author><name>catalogondemand</name><user>auto-converted</user><email>timh@catalog-on-demand.com</email></author></authors>
13
- <date>2015-05-12</date>
14
- <time>16:52:20</time>
15
- <contents><target name="magecommunity"><dir name="Mage"><dir name="CodiScript"><dir name="Helper"><file name="Data.php" hash="3f99660cb06a9dc09f024b9993d43a3f"/></dir><dir name="Model"><file name="Files.php" hash="7c362bdc29aceb997dec9833a58a7642"/></dir><dir name="controllers"><file name="IndexController.php" hash="9d059f9970fb22d36f4c1964fc699c45"/></dir><dir name="etc"><file name="adminhtml.xml" hash="40ab0bd86928c5ba175988926a9f6aee"/><file name="config.xml" hash="b960e9bd106f0c94559baa2bc5761e18"/><file name="system.xml" hash="1b5e5b18bfdce6b85e304fb4ef877274"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Mage_CodiScript.xml" hash="f0502cac7918fc798b3b02d3d4b7e7fd"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="codiscript.xml" hash="066f99333a6054e11943a75413f65ff0"/></dir></dir></dir></dir></target><target name="mageweb"><dir name="js"><dir name="codi"><file name="password_validation.js" hash="7223aeed118bb5774c73f951460ae0b0"/></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="Mage_CodiScript.csv" hash="183fc591065ced83f878a4c3e23f854c"/></dir></target></contents>
16
  <compatible/>
17
  <dependencies/>
18
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Mage_Codi</name>
4
+ <version>4.2.8</version>
5
  <stability>stable</stability>
6
  <license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
  <channel>community</channel>
10
  <description>Extension to connect to the Catalog-on-Demand service for making print catalogs, brochures, and flyers.</description>
11
  <notes>Please contact our support desk if you have any problems.</notes>
12
  <authors><author><name>catalogondemand</name><user>auto-converted</user><email>timh@catalog-on-demand.com</email></author></authors>
13
+ <date>2015-07-10</date>
14
+ <time>01:06:16</time>
15
+ <contents><target name="magecommunity"><dir name="Mage"><dir name="CodiScript"><dir name="Helper"><file name="Data.php" hash="3f99660cb06a9dc09f024b9993d43a3f"/></dir><dir name="Model"><file name="Files.php" hash="72f0abaefcac569121e8c973cc9fb8ef"/></dir><dir name="controllers"><file name="IndexController.php" hash="5528c3ca039e3d4b1fd43f660f3d9cc6"/></dir><dir name="etc"><file name="adminhtml.xml" hash="40ab0bd86928c5ba175988926a9f6aee"/><file name="config.xml" hash="b960e9bd106f0c94559baa2bc5761e18"/><file name="system.xml" hash="1b5e5b18bfdce6b85e304fb4ef877274"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Mage_CodiScript.xml" hash="f0502cac7918fc798b3b02d3d4b7e7fd"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="codiscript.xml" hash="066f99333a6054e11943a75413f65ff0"/></dir></dir></dir></dir></target><target name="mageweb"><dir name="js"><dir name="codi"><file name="password_validation.js" hash="7223aeed118bb5774c73f951460ae0b0"/></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="Mage_CodiScript.csv" hash="183fc591065ced83f878a4c3e23f854c"/></dir></target></contents>
16
  <compatible/>
17
  <dependencies/>
18
  </package>