Mage_Codi - Version 4.0.4

Version Notes

Supports suppression of associated product images.

Please contact our support desk if you have any problems.

Download this release

Release Info

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


Code changes from version 4.0.3 to 4.0.4

app/code/community/Mage/CodiScript/Model/Files.php CHANGED
@@ -1,5 +1,5 @@
1
  <?php
2
- // 2013-02-04
3
  class Mage_CodiScript_Model_Files extends Mage_Core_Model_Abstract {
4
  public $version = VERSION;
5
  public $Store;
@@ -15,6 +15,7 @@ class Mage_CodiScript_Model_Files extends Mage_Core_Model_Abstract {
15
  public $publishtieredpricing = FALSE;
16
  public $includetaxes = FALSE;
17
  public $ignoreexcludedimages = FALSE;
 
18
  public $address = FALSE;
19
  public $quantitylabel;
20
  public $pricelabel;
@@ -175,18 +176,21 @@ product thumbnail : ".$product->getThumbnail()."
175
  item small image: ".$UsedProduct->getSmallImage()."
176
  item thumbnail : ".$UsedProduct->getThumbnail()."
177
  ";
178
- $itemImages = array();
179
- $itemImageArray = $UsedProduct->getMediaGallery('images');
180
- if( is_array($itemImageArray) ){
181
- foreach( $itemImageArray as $image ){
182
- if($this->_DEBUG) echo "gallery image ".$image['file']." disabled=".$image['disabled']."
 
 
183
  ";
184
- if( $this->ignoreexcludedimages && $image['disabled'] )
185
- continue;
186
- $itemImages[] = "Print#=#".$this->prodmediaurl.$image['file'];
 
187
  }
 
188
  }
189
- $itemImages = implode( "#|#", $itemImages );
190
  $attributes = $UsedProduct->getAttributes();
191
  $ItemAttributes = "";
192
  foreach ($attributes as $attribute) {
1
  <?php
2
+ // 2013-05-31
3
  class Mage_CodiScript_Model_Files extends Mage_Core_Model_Abstract {
4
  public $version = VERSION;
5
  public $Store;
15
  public $publishtieredpricing = FALSE;
16
  public $includetaxes = FALSE;
17
  public $ignoreexcludedimages = FALSE;
18
+ public $ignoreassprodimages = FALSE;
19
  public $address = FALSE;
20
  public $quantitylabel;
21
  public $pricelabel;
176
  item small image: ".$UsedProduct->getSmallImage()."
177
  item thumbnail : ".$UsedProduct->getThumbnail()."
178
  ";
179
+ if($this->ignoreassprodimages) $itemImages = "";
180
+ else{
181
+ $itemImages = array();
182
+ $itemImageArray = $UsedProduct->getMediaGallery('images');
183
+ if( is_array($itemImageArray) ){
184
+ foreach( $itemImageArray as $image ){
185
+ if($this->_DEBUG) echo "gallery image ".$image['file']." disabled=".$image['disabled']."
186
  ";
187
+ if( $this->ignoreexcludedimages && $image['disabled'] )
188
+ continue;
189
+ $itemImages[] = "Print#=#".$this->prodmediaurl.$image['file'];
190
+ }
191
  }
192
+ $itemImages = implode( "#|#", $itemImages );
193
  }
 
194
  $attributes = $UsedProduct->getAttributes();
195
  $ItemAttributes = "";
196
  foreach ($attributes as $attribute) {
app/code/community/Mage/CodiScript/controllers/IndexController.php CHANGED
@@ -1,5 +1,5 @@
1
  <?php
2
- define("VERSION","2013-02-04");
3
 
4
  class Mage_CodiScript_IndexController extends Mage_Core_Controller_Front_Action{
5
  public function indexAction(){
@@ -59,6 +59,7 @@ if( $Class=="DataFile" ){
59
  $savingslabel = isset($_REQUEST["savingslabel"]) ? $_REQUEST["savingslabel"] : "Savings";
60
  $includetaxes = ( isset($_REQUEST["includetaxes"]) && $_REQUEST["includetaxes"] == "1" );
61
  $ignoreexcludedimages = ( isset($_REQUEST["ignoreexcludedimages"]) && $_REQUEST["ignoreexcludedimages"] == "1" );
 
62
  if($_DEBUG) echo "enablereviews=".$enablereviews."
63
  ignoretopcategory=".$ignoretopcategory."
64
  includeshortdescription=".$includeshortdescription."
@@ -70,6 +71,7 @@ pricelabel=".$pricelabel."
70
  savingslabel=".$savingslabel."
71
  includetaxes=".$includetaxes."
72
  ignoreexcludedimages=".$ignoreexcludedimages."
 
73
  ";
74
  }else if( $Class=="CatalogSection" ){
75
  $ignoretopcategory = ( isset($_REQUEST["ignoretopcategory"]) && $_REQUEST["ignoretopcategory"] == "1" );
@@ -139,6 +141,7 @@ if($Class=="DataFile"){
139
  $cfModel->savingslabel = $savingslabel;
140
  $cfModel->includetaxes = $includetaxes;
141
  $cfModel->ignoreexcludedimages = $ignoreexcludedimages;
 
142
  if($cfModel->includetaxes)
143
  $cfModel->taxhelper=Mage::helper('tax');
144
  }else if( $Class=="CatalogSection" ){
@@ -179,6 +182,9 @@ executed in ".( time() - $started_time )." sec.
179
  ";
180
  die();
181
  /* RELEASE NOTES
 
 
 
182
  * 2013-02-04
183
  * 1. Added includelongdescription request parameter / processing
184
  *
1
  <?php
2
+ define("VERSION","2013-05-31");
3
 
4
  class Mage_CodiScript_IndexController extends Mage_Core_Controller_Front_Action{
5
  public function indexAction(){
59
  $savingslabel = isset($_REQUEST["savingslabel"]) ? $_REQUEST["savingslabel"] : "Savings";
60
  $includetaxes = ( isset($_REQUEST["includetaxes"]) && $_REQUEST["includetaxes"] == "1" );
61
  $ignoreexcludedimages = ( isset($_REQUEST["ignoreexcludedimages"]) && $_REQUEST["ignoreexcludedimages"] == "1" );
62
+ $ignoreassprodimages = ( isset($_REQUEST["ignoreassprodimages"]) && $_REQUEST["ignoreassprodimages"] == "1" );
63
  if($_DEBUG) echo "enablereviews=".$enablereviews."
64
  ignoretopcategory=".$ignoretopcategory."
65
  includeshortdescription=".$includeshortdescription."
71
  savingslabel=".$savingslabel."
72
  includetaxes=".$includetaxes."
73
  ignoreexcludedimages=".$ignoreexcludedimages."
74
+ ignoreassprodimages=".$ignoreassprodimages."
75
  ";
76
  }else if( $Class=="CatalogSection" ){
77
  $ignoretopcategory = ( isset($_REQUEST["ignoretopcategory"]) && $_REQUEST["ignoretopcategory"] == "1" );
141
  $cfModel->savingslabel = $savingslabel;
142
  $cfModel->includetaxes = $includetaxes;
143
  $cfModel->ignoreexcludedimages = $ignoreexcludedimages;
144
+ $cfModel->ignoreassprodimages = $ignoreassprodimages;
145
  if($cfModel->includetaxes)
146
  $cfModel->taxhelper=Mage::helper('tax');
147
  }else if( $Class=="CatalogSection" ){
182
  ";
183
  die();
184
  /* RELEASE NOTES
185
+ * 2013-05-31
186
+ * 1. Added "Ignore associated product images" feature
187
+ *
188
  * 2013-02-04
189
  * 1. Added includelongdescription request parameter / processing
190
  *
package.xml CHANGED
@@ -1,18 +1,20 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Mage_Codi</name>
4
- <version>4.0.3</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>
8
  <extends/>
9
  <summary>Catalog-on-Demand</summary>
10
  <description>Extension to connect to the Catalog-on-Demand service for making print catalogs, brochures, and flyers.</description>
11
- <notes>Adds ability to optionally include long description. 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>2013-02-06</date>
14
- <time>16:16:09</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="b86e5a99c9dccea3f71a9573e4232d60"/></dir><dir name="controllers"><file name="IndexController.php" hash="0bf70eab71d1f1ed3452c5ac1bbbb969"/></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.0.4</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>
8
  <extends/>
9
  <summary>Catalog-on-Demand</summary>
10
  <description>Extension to connect to the Catalog-on-Demand service for making print catalogs, brochures, and flyers.</description>
11
+ <notes>Supports suppression of associated product images.&#xD;
12
+ &#xD;
13
+ Please contact our support desk if you have any problems.</notes>
14
  <authors><author><name>catalogondemand</name><user>auto-converted</user><email>timh@catalog-on-demand.com</email></author></authors>
15
+ <date>2013-05-31</date>
16
+ <time>18:23:10</time>
17
+ <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="b8ec7a091c9bda7f87d13587304e74c1"/></dir><dir name="controllers"><file name="IndexController.php" hash="5592e9a19e8e8c321f332f19f31c6988"/></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>
18
  <compatible/>
19
  <dependencies/>
20
  </package>