Print_Science_Designer_Web_to_Print - Version 1.0.14

Version Notes

Print_Science_Designer_Web_to_Print

Download this release

Release Info

Developer John Weissberg
Extension Print_Science_Designer_Web_to_Print
Version 1.0.14
Comparing to
See all releases


Code changes from version 1.0.13 to 1.0.14

app/code/local/PrintScience/Personalization/Helper/Output.php CHANGED
@@ -1,34 +1,72 @@
1
  <?php
 
2
  /**
 
3
  * Print Science personalization quote helper
 
4
  *
 
5
  */
 
6
  class PrintScience_Personalization_Helper_Output extends Mage_Core_Helper_Abstract
 
7
  {
 
8
  /**
 
9
  * Check if personalization is enabled for this product
 
10
  *
 
11
  * @param Mage_Catalog_Model_Product $product
 
12
  * @return boolean
 
13
  */
 
14
  public function isPersonalizationEnabled($product)
 
15
  {
 
 
 
 
 
16
  $productTypeId = $product->getTypeId();
 
17
  if ($productTypeId == Mage_Catalog_Model_Product_Type::TYPE_SIMPLE) {
 
18
  return $product->getPersonalizationEnabled();
 
19
  } elseif ($productTypeId == Mage_Catalog_Model_Product_Type::TYPE_CONFIGURABLE) {
 
20
  $subproducts = $product->getTypeInstance()->getUsedProducts();
 
21
  foreach ($subproducts as $product) {
 
22
  if (!$product->getPersonalizationEnabled()) {
 
23
  return false;
 
24
  }
 
25
  }
 
26
  return true;
 
27
  }
 
28
  }
 
29
 
 
30
  public function getFrontendParams() {
 
31
  $addedtoCart = (int) $_REQUEST['added'];
 
32
  return $addedtoCart;
 
33
  }
 
34
  }
 
1
  <?php
2
+
3
  /**
4
+
5
  * Print Science personalization quote helper
6
+
7
  *
8
+
9
  */
10
+
11
  class PrintScience_Personalization_Helper_Output extends Mage_Core_Helper_Abstract
12
+
13
  {
14
+
15
  /**
16
+
17
  * Check if personalization is enabled for this product
18
+
19
  *
20
+
21
  * @param Mage_Catalog_Model_Product $product
22
+
23
  * @return boolean
24
+
25
  */
26
+
27
  public function isPersonalizationEnabled($product)
28
+
29
  {
30
+ $pId = $product->getId();
31
+
32
+ $product = Mage::getModel('catalog/product');
33
+ $product->load($pId);
34
+
35
  $productTypeId = $product->getTypeId();
36
+
37
  if ($productTypeId == Mage_Catalog_Model_Product_Type::TYPE_SIMPLE) {
38
+
39
  return $product->getPersonalizationEnabled();
40
+
41
  } elseif ($productTypeId == Mage_Catalog_Model_Product_Type::TYPE_CONFIGURABLE) {
42
+
43
  $subproducts = $product->getTypeInstance()->getUsedProducts();
44
+
45
  foreach ($subproducts as $product) {
46
+
47
  if (!$product->getPersonalizationEnabled()) {
48
+
49
  return false;
50
+
51
  }
52
+
53
  }
54
+
55
  return true;
56
+
57
  }
58
+
59
  }
60
+
61
 
62
+
63
  public function getFrontendParams() {
64
+
65
  $addedtoCart = (int) $_REQUEST['added'];
66
+
67
  return $addedtoCart;
68
+
69
  }
70
+
71
  }
72
+
app/code/local/PrintScience/Personalization/etc/config.xml CHANGED
@@ -2,7 +2,7 @@
2
  <config>
3
  <modules>
4
  <PrintScience_Personalization>
5
- <version>1.0.13</version>
6
  </PrintScience_Personalization>
7
  </modules>
8
  <frontend>
2
  <config>
3
  <modules>
4
  <PrintScience_Personalization>
5
+ <version>1.0.14</version>
6
  </PrintScience_Personalization>
7
  </modules>
8
  <frontend>
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Print_Science_Designer_Web_to_Print</name>
4
- <version>1.0.13</version>
5
  <stability>stable</stability>
6
  <license>OSL v3.0</license>
7
  <channel>community</channel>
@@ -10,9 +10,9 @@
10
  <description>Print_Science_Designer_Web_to_Print</description>
11
  <notes>Print_Science_Designer_Web_to_Print</notes>
12
  <authors><author><name>John Weissberg</name><user>johnwwweissberg</user><email>jw@print-science.com</email></author></authors>
13
- <date>2013-09-25</date>
14
- <time>10:15:24</time>
15
- <contents><target name="magelocal"><dir name="PrintScience"><dir name="Personalization"><dir name="Block"><dir name="Adminhtml"><dir name="Sales"><dir name="Order"><dir name="View"><dir name="Items"><file name="Renderer.php" hash="e9a0dcb549311ea6f4e3992bbc9a4b5c"/></dir></dir></dir></dir></dir><dir name="Checkout"><dir name="Cart"><dir name="Item"><file name="Renderer.php" hash="ed6e20240327913534ae3d93debe5101"/></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="cd3c2c919469c3ad244bb412892a7462"/><file name="Order.php" hash="ba50cbfb5f647cbca2deae91153db9b7"/><file name="Output.php" hash="cc6f4eccaff419490bc8cccbf45b6b45"/><file name="Quote.php" hash="d14fbe62e2a96e4aede13082c16dda30"/><file name="Session.php" hash="0236f26208780df75ca780d40edbe351"/></dir><dir name="Model"><dir name="ApiGateway"><dir name="Response"><file name="Abstract.php" hash="66667fce4c92782faf1d1a92f4c3e339"/><file name="Begin.php" hash="451d64c86ef6aa542ae7cf5949b1b627"/><file name="GetPreview.php" hash="5801403f4c511aa0a97b8273a712e407"/></dir></dir><file name="ApiGateway.php" hash="1893c8252ac1eb4f877da99d5aa81d65"/><file name="Observer.php" hash="8aff4eadf568df85125ec2340599e720"/><dir name="Override"><dir name="Checkout"><file name="Cart.php" hash="ccece0a4e9fffd6d4b7f1b1a8a97dbd3"/></dir><dir name="Sales"><file name="Quote.php" hash="58083e79ec32db5ea22e0fa61f3a4bd7"/></dir></dir><dir name="Resource"><dir name="Eav"><dir name="Mysql4"><file name="Setup.php" hash="0b1f152cf26c58a92efe4165dc9b3803"/></dir></dir></dir><dir name="System"><dir name="Config"><dir name="Backend"><file name="ApiUrl.php" hash="34eb488ef178104966397f425625534d"/></dir><dir name="Source"><file name="ApiVersion.php" hash="e0248a29ebc88171b7fb51bdbabaca8b"/><file name="WindowType.php" hash="1af16df72f4fcfe959f6f091cd2f6821"/></dir></dir></dir></dir><dir name="controllers"><file name="IndexController.php" hash="c266982327554278526fc2bc02fa2820"/></dir><dir name="etc"><file name="config.xml" hash="49c97896edfb98f4eed0a5a919da66aa"/><file name="system.xml" hash="ea5d1935373ddfef8935d5cd26c53066"/></dir><dir name="sql"><dir name="printscience_personalization_setup"><file name="mysql4-install-1.0.3.php" hash="7895f0369177cb6dab9911d7820647b4"/><file name="mysql4-upgrade-1.0.3-1.0.4.php" hash="d952675034fdd05650ef978dccbc05fd"/><file name="mysql4-upgrade-1.0.8-1.0.9.php" hash="2e7cd11df78d3742d95f5264a2f34f07"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="printscience_personalization"><dir name="catalog"><dir name="product"><file name="list.phtml" hash="df34148e4bf01000bb445a02e887b8a6"/><dir name="view"><file name="addtocart.phtml" hash="ee0af223cca8c873492e2e9624953879"/><file name="media.phtml" hash="c1350af91c896b3a621a4ddc9bb9e219"/></dir><file name="view.phtml" hash="bc39bfa989142e868f2283476c767c2a"/></dir></dir><dir name="checkout"><dir name="cart"><dir name="item"><file name="default.phtml" hash="f36d9b822f54a543fcbcc7af06326379"/></dir></dir><file name="cart.phtml" hash="e89ff28600d85d6ecaa4ef2254c6852b"/></dir></dir></dir><dir name="layout"><file name="printscience_personalization.xml" hash="762502407374156d41802de045d780e0"/></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="template"><dir name="printscience_personalization"><dir name="sales"><dir name="order"><dir name="view"><dir name="items"><dir name="renderer"><file name="default.phtml" hash="5b6bcdd9bd94afda867429707dd786d3"/></dir></dir></dir></dir></dir></dir></dir><dir name="layout"><file name="printscience_personalization.xml" hash="d0934cc5cfaca9e2d6c687f2fb866943"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="PrintScience_Personalization.xml" hash="5f5c39c5b01e828137125d057d04a655"/></dir></target><target name="magelocale"><dir name="en_US"><file name="PrintScience_Personalization.csv" hash="fc8365124f21bddca4dfac3d3dbf5b7f"/></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="printscience_personalization"><file name="jquery-1.7.2.min.js" hash="acc0adc6c188845a409bf158d2de4451"/><file name="modalPopLite.css" hash="32dc2c9142fff0c6221c62e3f95b8275"/><file name="modalPopLite.min.js" hash="255d501be44d6c7ac54aa4226d1ce314"/></dir></dir></dir></dir></target><target name="magelib"><dir name="xmlrpc"><file name="xmlrpc.inc" hash="55ecb2a9f7fc20d53a7b4da9d885e26b"/></dir></target><target name="mage"><dir name="js"><dir name="printscience_personalization"><file name="gallery.css" hash="eccacd49a35d68ef25bc1bf8e292fe98"/><file name="gallery.js" hash="d1ce93b3cf8ef950fef1097636f3205e"/><dir name="jquery"><dir name="fancybox"><file name="blank.gif" hash="325472601571f31e1bf00674c368d335"/><file name="fancy_close.png" hash="6e2879a324a76e9972ebc98201aae1d8"/><file name="fancy_loading.png" hash="b1d54c240cf06e7f41e372d56919b738"/><file name="fancy_nav_left.png" hash="3f3e406102152cd8236383568a40ba35"/><file name="fancy_nav_right.png" hash="216e4bde5bddeeaa60dc3d692890a68e"/><file name="fancy_shadow_e.png" hash="fd4f491080d29fade5080877f1ba4c8b"/><file name="fancy_shadow_n.png" hash="18cde16379b2ceadef714d9b346d09ec"/><file name="fancy_shadow_ne.png" hash="63adf788acf193d4e4f3642d7d793125"/><file name="fancy_shadow_nw.png" hash="c820c878aedb7a7f9ebd7135a58e7c65"/><file name="fancy_shadow_s.png" hash="9b9e5c888028aaef40fe5b6a363f1e29"/><file name="fancy_shadow_se.png" hash="a8afd5a008884380ee712d177105268f"/><file name="fancy_shadow_sw.png" hash="f81cc0fee5581d76ad3cebe47e7e791b"/><file name="fancy_shadow_w.png" hash="59b0e63eb059e58d932cfd53da4d87e6"/><file name="fancy_title_left.png" hash="1582ac2d3bef6a6445bf02ceca2741cd"/><file name="fancy_title_main.png" hash="38dad6c1ed4bdc81c0bec721b2deb8c2"/><file name="fancy_title_over.png" hash="b886fd165d4b7ac77d41fb52d87ffc60"/><file name="fancy_title_right.png" hash="6cbe0c935511e7f9a2555ccb6a7324c4"/><file name="fancybox-x.png" hash="168696d8a694214090ef90e029cdf393"/><file name="fancybox-y.png" hash="36a58859beb9a6b19322a37466b9f78e"/><file name="fancybox.png" hash="11e57e492ee0311540967cc7a1e6e3e2"/><file name="jquery.easing-1.3.pack.js" hash="def257dbb0ab805c4996fd8abb1a6b49"/><file name="jquery.fancybox-1.3.4.css" hash="4638ce99ef00cf62bfb22d230f9924b8"/><file name="jquery.fancybox-1.3.4.pack.js" hash="8bc36a08c46719377528d962966ce37c"/><file name="jquery.mousewheel-3.0.4.pack.js" hash="3b0a821567b463e70bcc1e90ed2bc9b6"/></dir><file name="jquery-1.4.2.min.js" hash="b80a2154ce061c8242031d9a4892c5a6"/><dir name="jquery.cycle"><file name="jquery.cycle.lite.min.js" hash="0c4a7571c05a6ada90b93e826e7f9f6e"/></dir></dir></dir></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Print_Science_Designer_Web_to_Print</name>
4
+ <version>1.0.14</version>
5
  <stability>stable</stability>
6
  <license>OSL v3.0</license>
7
  <channel>community</channel>
10
  <description>Print_Science_Designer_Web_to_Print</description>
11
  <notes>Print_Science_Designer_Web_to_Print</notes>
12
  <authors><author><name>John Weissberg</name><user>johnwwweissberg</user><email>jw@print-science.com</email></author></authors>
13
+ <date>2013-10-01</date>
14
+ <time>09:53:01</time>
15
+ <contents><target name="magelocal"><dir><dir name="PrintScience"><dir name="Personalization"><dir name="Block"><dir name="Adminhtml"><dir name="Sales"><dir name="Order"><dir name="View"><dir name="Items"><file name="Renderer.php" hash="e9a0dcb549311ea6f4e3992bbc9a4b5c"/></dir></dir></dir></dir></dir><dir name="Checkout"><dir name="Cart"><dir name="Item"><file name="Renderer.php" hash="ed6e20240327913534ae3d93debe5101"/></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="cd3c2c919469c3ad244bb412892a7462"/><file name="Order.php" hash="ba50cbfb5f647cbca2deae91153db9b7"/><file name="Output.php" hash="3f173352807815abaf443da359de935e"/><file name="Quote.php" hash="d14fbe62e2a96e4aede13082c16dda30"/><file name="Session.php" hash="0236f26208780df75ca780d40edbe351"/></dir><dir name="Model"><dir name="ApiGateway"><dir name="Response"><file name="Abstract.php" hash="66667fce4c92782faf1d1a92f4c3e339"/><file name="Begin.php" hash="451d64c86ef6aa542ae7cf5949b1b627"/><file name="GetPreview.php" hash="5801403f4c511aa0a97b8273a712e407"/></dir></dir><file name="ApiGateway.php" hash="1893c8252ac1eb4f877da99d5aa81d65"/><file name="Observer.php" hash="8aff4eadf568df85125ec2340599e720"/><dir name="Override"><dir name="Checkout"><file name="Cart.php" hash="ccece0a4e9fffd6d4b7f1b1a8a97dbd3"/></dir><dir name="Sales"><file name="Quote.php" hash="58083e79ec32db5ea22e0fa61f3a4bd7"/></dir></dir><dir name="Resource"><dir name="Eav"><dir name="Mysql4"><file name="Setup.php" hash="0b1f152cf26c58a92efe4165dc9b3803"/></dir></dir></dir><dir name="System"><dir name="Config"><dir name="Backend"><file name="ApiUrl.php" hash="34eb488ef178104966397f425625534d"/></dir><dir name="Source"><file name="ApiVersion.php" hash="e0248a29ebc88171b7fb51bdbabaca8b"/><file name="WindowType.php" hash="1af16df72f4fcfe959f6f091cd2f6821"/></dir></dir></dir></dir><dir name="controllers"><file name="IndexController.php" hash="c266982327554278526fc2bc02fa2820"/></dir><dir name="etc"><file name="config.xml" hash="25e2f94590baeddd2aaad258b2cedbc7"/><file name="system.xml" hash="ea5d1935373ddfef8935d5cd26c53066"/></dir><dir name="sql"><dir name="printscience_personalization_setup"><file name="mysql4-install-1.0.3.php" hash="7895f0369177cb6dab9911d7820647b4"/><file name="mysql4-upgrade-1.0.3-1.0.4.php" hash="d952675034fdd05650ef978dccbc05fd"/><file name="mysql4-upgrade-1.0.8-1.0.9.php" hash="2e7cd11df78d3742d95f5264a2f34f07"/></dir></dir></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="printscience_personalization"><dir name="catalog"><dir name="product"><file name="list.phtml" hash="df34148e4bf01000bb445a02e887b8a6"/><dir name="view"><file name="addtocart.phtml" hash="ee0af223cca8c873492e2e9624953879"/><file name="media.phtml" hash="c1350af91c896b3a621a4ddc9bb9e219"/></dir><file name="view.phtml" hash="bc39bfa989142e868f2283476c767c2a"/></dir></dir><dir name="checkout"><dir name="cart"><dir name="item"><file name="default.phtml" hash="f36d9b822f54a543fcbcc7af06326379"/></dir></dir><file name="cart.phtml" hash="e89ff28600d85d6ecaa4ef2254c6852b"/></dir></dir></dir><dir name="layout"><file name="printscience_personalization.xml" hash="762502407374156d41802de045d780e0"/></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="template"><dir name="printscience_personalization"><dir name="sales"><dir name="order"><dir name="view"><dir name="items"><dir name="renderer"><file name="default.phtml" hash="5b6bcdd9bd94afda867429707dd786d3"/></dir></dir></dir></dir></dir></dir></dir><dir name="layout"><file name="printscience_personalization.xml" hash="d0934cc5cfaca9e2d6c687f2fb866943"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="PrintScience_Personalization.xml" hash="5f5c39c5b01e828137125d057d04a655"/></dir></target><target name="magelocale"><dir name="en_US"><file name="PrintScience_Personalization.csv" hash="fc8365124f21bddca4dfac3d3dbf5b7f"/></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="printscience_personalization"><file name="jquery-1.7.2.min.js" hash="acc0adc6c188845a409bf158d2de4451"/><file name="modalPopLite.css" hash="32dc2c9142fff0c6221c62e3f95b8275"/><file name="modalPopLite.min.js" hash="255d501be44d6c7ac54aa4226d1ce314"/></dir></dir></dir></dir></target><target name="magelib"><dir name="xmlrpc"><file name="xmlrpc.inc" hash="55ecb2a9f7fc20d53a7b4da9d885e26b"/></dir></target><target name="mage"><dir name="js"><dir name="printscience_personalization"><file name="gallery.css" hash="eccacd49a35d68ef25bc1bf8e292fe98"/><file name="gallery.js" hash="d1ce93b3cf8ef950fef1097636f3205e"/><dir name="jquery"><dir name="fancybox"><file name="blank.gif" hash="325472601571f31e1bf00674c368d335"/><file name="fancy_close.png" hash="6e2879a324a76e9972ebc98201aae1d8"/><file name="fancy_loading.png" hash="b1d54c240cf06e7f41e372d56919b738"/><file name="fancy_nav_left.png" hash="3f3e406102152cd8236383568a40ba35"/><file name="fancy_nav_right.png" hash="216e4bde5bddeeaa60dc3d692890a68e"/><file name="fancy_shadow_e.png" hash="fd4f491080d29fade5080877f1ba4c8b"/><file name="fancy_shadow_n.png" hash="18cde16379b2ceadef714d9b346d09ec"/><file name="fancy_shadow_ne.png" hash="63adf788acf193d4e4f3642d7d793125"/><file name="fancy_shadow_nw.png" hash="c820c878aedb7a7f9ebd7135a58e7c65"/><file name="fancy_shadow_s.png" hash="9b9e5c888028aaef40fe5b6a363f1e29"/><file name="fancy_shadow_se.png" hash="a8afd5a008884380ee712d177105268f"/><file name="fancy_shadow_sw.png" hash="f81cc0fee5581d76ad3cebe47e7e791b"/><file name="fancy_shadow_w.png" hash="59b0e63eb059e58d932cfd53da4d87e6"/><file name="fancy_title_left.png" hash="1582ac2d3bef6a6445bf02ceca2741cd"/><file name="fancy_title_main.png" hash="38dad6c1ed4bdc81c0bec721b2deb8c2"/><file name="fancy_title_over.png" hash="b886fd165d4b7ac77d41fb52d87ffc60"/><file name="fancy_title_right.png" hash="6cbe0c935511e7f9a2555ccb6a7324c4"/><file name="fancybox-x.png" hash="168696d8a694214090ef90e029cdf393"/><file name="fancybox-y.png" hash="36a58859beb9a6b19322a37466b9f78e"/><file name="fancybox.png" hash="11e57e492ee0311540967cc7a1e6e3e2"/><file name="jquery.easing-1.3.pack.js" hash="def257dbb0ab805c4996fd8abb1a6b49"/><file name="jquery.fancybox-1.3.4.css" hash="4638ce99ef00cf62bfb22d230f9924b8"/><file name="jquery.fancybox-1.3.4.pack.js" hash="8bc36a08c46719377528d962966ce37c"/><file name="jquery.mousewheel-3.0.4.pack.js" hash="3b0a821567b463e70bcc1e90ed2bc9b6"/></dir><file name="jquery-1.4.2.min.js" hash="b80a2154ce061c8242031d9a4892c5a6"/><dir name="jquery.cycle"><file name="jquery.cycle.lite.min.js" hash="0c4a7571c05a6ada90b93e826e7f9f6e"/></dir></dir></dir></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>