Version Notes
Official commit
Download this release
Release Info
Developer | Magento Core Team |
Extension | Fianet_Sceau |
Version | 1.1.1 |
Comparing to | |
See all releases |
Code changes from version 1.1.0 to 1.1.1
app/code/community/Fianet/Sceau/Helper/Data.php
CHANGED
@@ -1,21 +1,19 @@
|
|
1 |
<?php
|
2 |
|
3 |
class Fianet_Sceau_Helper_Data extends Mage_Core_Helper_Abstract {
|
4 |
-
protected $_resource = null;
|
5 |
-
protected $
|
6 |
-
protected $
|
7 |
-
protected $_tables = array();
|
8 |
const ORDER_ATTR_SCEAU_SENT_PROD = 'fianet_sceau_order_sent_prod';
|
9 |
const ORDER_ATTR_SCEAU_SENT_PPROD = 'fianet_sceau_order_sent_preprod';
|
10 |
|
11 |
static public function processResponse(Mage_Sales_Model_Order $order, $result) {
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
$
|
16 |
-
$orderGrid = $_resource->getTableName('sales/order_grid');
|
17 |
if ($orderGrid)
|
18 |
-
|
19 |
|
20 |
if ($result) {
|
21 |
$attribut_sceau = self::ORDER_ATTR_SCEAU_SENT_PPROD;
|
@@ -25,11 +23,16 @@ class Fianet_Sceau_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
25 |
}
|
26 |
|
27 |
// Mise à jour par SQL pour éviter incompatibilité avec Certissim
|
28 |
-
foreach (
|
29 |
-
|
30 |
-
|
31 |
-
$
|
32 |
-
$
|
|
|
|
|
|
|
|
|
|
|
33 |
}
|
34 |
}
|
35 |
}
|
@@ -126,16 +129,6 @@ class Fianet_Sceau_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
126 |
return false;
|
127 |
}
|
128 |
|
129 |
-
public static function getMagentoVersion() {
|
130 |
-
$version = Mage::getVersion();
|
131 |
-
$version = substr($version, 0, 5);
|
132 |
-
$version = str_replace('.', '', $version);
|
133 |
-
while (strlen($version) < 3) {
|
134 |
-
$version .= "0";
|
135 |
-
}
|
136 |
-
return (int) $version;
|
137 |
-
}
|
138 |
-
|
139 |
public static function isModuleActive($order) {
|
140 |
if (Mage::getStoreConfig('sceau/sceauconfg/active', $order->getStoreId()) == '1') {
|
141 |
return true;
|
1 |
<?php
|
2 |
|
3 |
class Fianet_Sceau_Helper_Data extends Mage_Core_Helper_Abstract {
|
4 |
+
protected static $_resource = null;
|
5 |
+
protected static $_writeConnection = null;
|
6 |
+
protected static $_tables = array();
|
|
|
7 |
const ORDER_ATTR_SCEAU_SENT_PROD = 'fianet_sceau_order_sent_prod';
|
8 |
const ORDER_ATTR_SCEAU_SENT_PPROD = 'fianet_sceau_order_sent_preprod';
|
9 |
|
10 |
static public function processResponse(Mage_Sales_Model_Order $order, $result) {
|
11 |
+
self::$_resource = Mage::getSingleton('core/resource');
|
12 |
+
self::$_writeConnection = self::$_resource->getConnection('core_write');
|
13 |
+
self::$_tables = array(self::$_resource->getTableName('sales/order'));
|
14 |
+
$orderGrid = self::$_resource->getTableName('sales/order_grid');
|
|
|
15 |
if ($orderGrid)
|
16 |
+
self::$_tables[] = $orderGrid;
|
17 |
|
18 |
if ($result) {
|
19 |
$attribut_sceau = self::ORDER_ATTR_SCEAU_SENT_PPROD;
|
23 |
}
|
24 |
|
25 |
// Mise à jour par SQL pour éviter incompatibilité avec Certissim
|
26 |
+
foreach (self::$_tables as $table) {
|
27 |
+
self::$_writeConnection->beginTransaction();
|
28 |
+
|
29 |
+
$__fields = array();
|
30 |
+
$__fields[$attribut_sceau] = '1';
|
31 |
+
$__where = self::$_writeConnection->quoteInto('entity_id =?',$order->getEntityId());
|
32 |
+
|
33 |
+
self::$_writeConnection->update($table, $__fields, $__where);
|
34 |
+
|
35 |
+
self::$_writeConnection->commit();
|
36 |
}
|
37 |
}
|
38 |
}
|
129 |
return false;
|
130 |
}
|
131 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
132 |
public static function isModuleActive($order) {
|
133 |
if (Mage::getStoreConfig('sceau/sceauconfg/active', $order->getStoreId()) == '1') {
|
134 |
return true;
|
app/code/community/Fianet/Sceau/etc/config.xml
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Fianet_Sceau>
|
5 |
-
<version>1.1.
|
6 |
</Fianet_Sceau>
|
7 |
</modules>
|
8 |
<global>
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Fianet_Sceau>
|
5 |
+
<version>1.1.1</version>
|
6 |
</Fianet_Sceau>
|
7 |
</modules>
|
8 |
<global>
|
app/code/community/Fianet/Sceau/sql/fianet_sceau_setup/mysql4-install-1.0.0.php
CHANGED
@@ -6,7 +6,7 @@ $installer->addAttribute('order', 'fianet_sceau_order_sent_prod', array('type' =
|
|
6 |
$installer->addAttribute('order', 'fianet_sceau_order_sent_preprod', array('type' => 'int', 'visible' => false, 'required' => true, 'default_value' => 0));
|
7 |
$installer->addAttribute('order', 'fianet_sceau_order_sent_error', array('type' => 'int', 'visible' => false, 'required' => true, 'default_value' => 0));
|
8 |
|
9 |
-
if (
|
10 |
$installer->getConnection()->addColumn($installer->getTable('sales_flat_order_grid'), 'fianet_sceau_order_sent_prod', 'varchar(255) default 0');
|
11 |
$installer->getConnection()->addColumn($installer->getTable('sales_flat_order_grid'), 'fianet_sceau_order_sent_preprod', 'varchar(255) default 0');
|
12 |
$installer->getConnection()->addColumn($installer->getTable('sales_flat_order_grid'), 'fianet_sceau_order_sent_error', 'varchar(255) default 0');
|
6 |
$installer->addAttribute('order', 'fianet_sceau_order_sent_preprod', array('type' => 'int', 'visible' => false, 'required' => true, 'default_value' => 0));
|
7 |
$installer->addAttribute('order', 'fianet_sceau_order_sent_error', array('type' => 'int', 'visible' => false, 'required' => true, 'default_value' => 0));
|
8 |
|
9 |
+
if ((Mage::getEdition() == "Community" && version_compare(Mage::getVersion(), "1.4.0.1", '>')) || (Mage::getEdition() == "Enterprise" && version_compare(Mage::getVersion(), "1.8.0.0", '>'))) {
|
10 |
$installer->getConnection()->addColumn($installer->getTable('sales_flat_order_grid'), 'fianet_sceau_order_sent_prod', 'varchar(255) default 0');
|
11 |
$installer->getConnection()->addColumn($installer->getTable('sales_flat_order_grid'), 'fianet_sceau_order_sent_preprod', 'varchar(255) default 0');
|
12 |
$installer->getConnection()->addColumn($installer->getTable('sales_flat_order_grid'), 'fianet_sceau_order_sent_error', 'varchar(255) default 0');
|
app/etc/modules/zFianet_Sceau.xml
CHANGED
@@ -5,7 +5,7 @@
|
|
5 |
<active>true</active>
|
6 |
<codePool>community</codePool>
|
7 |
<!-- declare module's version information for database updates -->
|
8 |
-
<version>1.1.
|
9 |
</Fianet_Sceau>
|
10 |
</modules>
|
11 |
</config>
|
5 |
<active>true</active>
|
6 |
<codePool>community</codePool>
|
7 |
<!-- declare module's version information for database updates -->
|
8 |
+
<version>1.1.1</version>
|
9 |
</Fianet_Sceau>
|
10 |
</modules>
|
11 |
</config>
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Fianet_Sceau</name>
|
4 |
-
<version>1.1.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/OSL-3.0">Open Software License (OSL 3.0)</license>
|
7 |
<channel>community</channel>
|
@@ -10,9 +10,9 @@
|
|
10 |
<description>Seal of trust FIA-NET</description>
|
11 |
<notes>Official commit</notes>
|
12 |
<authors><author><name>FIA-NET</name><user>auto-converted</user><email>support-boutique@fia-net.com</email></author></authors>
|
13 |
-
<date>2014-
|
14 |
-
<time>
|
15 |
-
<contents><target name="magecommunity"><dir name="Fianet"><dir name="Sceau"><dir name="Block"><dir name="Catalog"><file name="ProductsReviews.php" hash="25cc10f954860a30154f33cc1f40e3c8"/></dir><dir name="Logo"><file name="Abstract.php" hash="c3b9d566fb937f5093e5d49b021e82df"/><file name="Footer.php" hash="af103617947cbbd5d5a32468757b691b"/><file name="Left.php" hash="87fb4aab3af002792282eaea5f806cf4"/><file name="Right.php" hash="692839ed3361af84561468245c15e4e3"/></dir><dir name="Sales"><dir name="Order"><file name="Grid.php" hash="1728f5da74fa5ab799f603dfd338a1e1"/></dir><file name="Order.php" hash="8caae3cbc5d66a55505664027138d866"/></dir><dir name="Widget"><dir name="Grid"><dir name="Column"><dir name="Filter"><file name="Fianet.php" hash="97b2dadc4011ce836781cc7d7d6a244b"/></dir><dir name="Renderer"><file name="Fianet.php" hash="77abadb34fdfa0dbccaca57328dfd648"/></dir></dir></dir><file name="Abstract.php" hash="34081f22dc73992f7b4fc6575ca7fd01"/><file name="Footer.php" hash="46b8ff738bebeb17b4c80bab3f8414a2"/><file name="Left.php" hash="9a81ebcfd5dbd11a6f0a4a23158157ed"/><file name="Right.php" hash="807cf3507a6d4177f3bbdc8be3f14f11"/></dir></dir><dir name="Helper"><file name="Data.php" hash="
|
16 |
<compatible/>
|
17 |
<dependencies><required><package><name>Fianet_Core</name><channel>community</channel><min>1.0.6</min><max></max></package></required></dependencies>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Fianet_Sceau</name>
|
4 |
+
<version>1.1.1</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/OSL-3.0">Open Software License (OSL 3.0)</license>
|
7 |
<channel>community</channel>
|
10 |
<description>Seal of trust FIA-NET</description>
|
11 |
<notes>Official commit</notes>
|
12 |
<authors><author><name>FIA-NET</name><user>auto-converted</user><email>support-boutique@fia-net.com</email></author></authors>
|
13 |
+
<date>2014-11-18</date>
|
14 |
+
<time>14:19:16</time>
|
15 |
+
<contents><target name="magecommunity"><dir name="Fianet"><dir name="Sceau"><dir name="Block"><dir name="Catalog"><file name="ProductsReviews.php" hash="25cc10f954860a30154f33cc1f40e3c8"/></dir><dir name="Logo"><file name="Abstract.php" hash="c3b9d566fb937f5093e5d49b021e82df"/><file name="Footer.php" hash="af103617947cbbd5d5a32468757b691b"/><file name="Left.php" hash="87fb4aab3af002792282eaea5f806cf4"/><file name="Right.php" hash="692839ed3361af84561468245c15e4e3"/></dir><dir name="Sales"><dir name="Order"><file name="Grid.php" hash="1728f5da74fa5ab799f603dfd338a1e1"/></dir><file name="Order.php" hash="8caae3cbc5d66a55505664027138d866"/></dir><dir name="Widget"><dir name="Grid"><dir name="Column"><dir name="Filter"><file name="Fianet.php" hash="97b2dadc4011ce836781cc7d7d6a244b"/></dir><dir name="Renderer"><file name="Fianet.php" hash="77abadb34fdfa0dbccaca57328dfd648"/></dir></dir></dir><file name="Abstract.php" hash="34081f22dc73992f7b4fc6575ca7fd01"/><file name="Footer.php" hash="46b8ff738bebeb17b4c80bab3f8414a2"/><file name="Left.php" hash="9a81ebcfd5dbd11a6f0a4a23158157ed"/><file name="Right.php" hash="807cf3507a6d4177f3bbdc8be3f14f11"/></dir></dir><dir name="Helper"><file name="Data.php" hash="698a9d882d0a8922e26ef7ccf4cfc8ab"/></dir><dir name="Model"><dir name="Avisproduits"><file name="Commentaires.php" hash="fbe323d5e61f854cb22756bdac31994b"/></dir><dir name="Categories"><file name="Association.php" hash="05d7c01cfc0eaa4b11677d0a5e9601ef"/></dir><dir name="Fianet"><dir name="Order"><file name="Sceau.php" hash="e4daee79f550c54f3cc31a1e42a6c3a1"/></dir><file name="Productsreviews.php" hash="7d0e7e63e9fc2fd80eda947f69a9549e"/></dir><dir name="Mysql4"><dir name="Avisproduits"><dir name="Commentaires"><file name="Collection.php" hash="9ec0204994a36e0e25873ee680ae0c67"/></dir><file name="Collection.php" hash="605825d9be4ef7aac76fe2057e35541c"/><file name="Commentaires.php" hash="4b49645a47ca958c46e6bd9c8062708f"/></dir><dir name="Categories"><dir name="Association"><file name="Collection.php" hash="f97eec5090921ca8e226167b7e0e152a"/></dir><file name="Association.php" hash="c159bea78e252c961e7cbaf6a29d2738"/></dir><dir name="Shipping"><dir name="Association"><file name="Collection.php" hash="bc99928aa71622baac8bea35d095f9ef"/></dir><file name="Association.php" hash="dfec437432bbb15aa2343e9135a69181"/></dir><file name="Avisproduits.php" hash="39c0b6435566c3a7139264d578c879fb"/></dir><dir name="Shipping"><file name="Association.php" hash="8bc91127879515d4328db0ab46325384"/></dir><dir name="Source"><file name="Language.php" hash="81c2c491ebbb550cc6460a51b6afe712"/><file name="Mode.php" hash="6ad379b3514bcd1335e10ef6116ae949"/><file name="Pagination.php" hash="15b255094a1e39c4bfede1855245a294"/><file name="ProductType.php" hash="35bdafbf86f7bde6901eff2b11c3c297"/><file name="ShippingType.php" hash="75e2ea777d3d4562b394cfb3141aa685"/><file name="Status.php" hash="64f0a26fe72c496ecc8538313d614099"/></dir><file name="Avisproduits.php" hash="62ebc2a39c1422cb60da1733ea3aa07a"/><file name="Observer.php" hash="ead2dbc51a612678a3d04f1b7fcc0a8c"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="CategoriesController.php" hash="3b140e5ffa63d87c6ffb634c270d0ce1"/><file name="CategoriesController.php.old" hash="fae5ee21d97f3549630b3c9e241115af"/><file name="ProductsController.php" hash="f5baa69400887184c962994c3407d610"/><file name="ShippingController.php" hash="81c4526f195327074bd41d507f11e520"/></dir><file name="IndexController.php" hash="0fbe00540d6c04b48706f5b632bc97a1"/><file name="ProductsreviewsController.php" hash="36e9335a54015f159969d53a255c2085"/></dir><dir name="etc"><file name="adminhtml.xml" hash="04e137ec740c3a060b2f26f82404a17c"/><file name="config.xml" hash="d8d6373020314abc20a5b47fc9888d1f"/><file name="system.xml" hash="9ff86abb50017e857b8104cb1ddba2b4"/></dir><dir name="sql"><dir name="fianet_sceau_setup"><file name="mysql4-install-1.0.0.php" hash="69497726d587f94d48c9101952a74e69"/><file name="mysql4-upgrade-1.0.3-1.0.4.php" hash="f5e70abde67d076c1730788ec4718939"/><file name="mysql4-upgrade-1.0.4-1.1.0.php" hash="8e2c05d166208268ce9070a13d2e727c"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="fianet_sceau.xml" hash="0358febbff6aae3401eb9c0176f246d6"/></dir><dir name="template"><dir name="fianet_sceau"><dir name="page"><dir name="html"><file name="logo.phtml" hash="8a80aad93f07e6e60386363f93ac6943"/><file name="productsReviews.phtml" hash="371fd6394eb7ef75a26ebb57d31d4953"/><file name="sceau.phtml" hash="d4edc0a31d564e5d6d35f189727544dc"/></dir></dir></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="fianet_sceau.xml" hash="3e56c10677bc0d2204f6395595547000"/></dir><dir name="template"><dir name="fianet_sceau"><file name="categories.phtml" hash="f3f63d3b3353a467fb84a3faf23a5704"/><file name="products.phtml" hash="cff7f9e88518e7198aa26fa49ba01931"/><file name="shipping.phtml" hash="701fdfbf67a49501c030cb8215cfbdc9"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="zFianet_Sceau.xml" hash="d9fca8359808c9e3b7568eee54a3733d"/></dir></target><target name="magelocale"><dir name="fr_FR"><file name="Fianet_Sceau.csv" hash="7e7f8e6486206fa8ad498a26587d8354"/></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="images"><dir name="sceau"><file name="10star.png" hash="89e9087e3566c203211b1949fb5e259d"/><file name="15star.png" hash="adfde5f3de162aa8c5cc7bafdb3b27b6"/><file name="20star.png" hash="1bedf78544acac179d1ddfe1d40039af"/><file name="25star.png" hash="3818be1921faa9af18ed9d71da5b0675"/><file name="30star.png" hash="1bc3331503bd6244c42e87b2db95b57c"/><file name="35star.png" hash="5c2f52d3500a2da9a86245ee9a1e1bb4"/><file name="40star.png" hash="7d40077e4454c297a5866569f4fda731"/><file name="45star.png" hash="d7e8acbeab91a3a665defabef9b4901d"/><file name="50star.png" hash="3198000c157efffee17fffda4beb630c"/><file name="5star.png" hash="2fc56de1808c1de615d59530660d83d2"/><file name="fond_comment.png" hash="87b33e2b603f4b472612b38951e5b625"/><file name="logo-fianet-transparent.png" hash="a5cdf5002c36a2cf4d5f944617cd2dcb"/><file name="logo_fianet_sceau.png" hash="befd6502a28deb2384674f696b9e1aa3"/><file name="ncstar.png" hash="c2a72391af53b06fd8cf17c69dd48613"/></dir></dir></dir></dir><dir name="default"><dir name="default"><dir name="fianet"><file name="sceau.js" hash="eb76770affa84faa301e55c67b630da1"/><file name="sceau.css" hash="f342ab1385775a649d4c83ef43eddf5c"/></dir></dir></dir><dir name="rwd"><dir name="default"><dir name="fianet"><file name="sceau.js" hash="eb76770affa84faa301e55c67b630da1"/><file name="sceau.css" hash="e9a3118b9a8db890cc1f6ddfb1a63245"/></dir></dir></dir></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><package><name>Fianet_Core</name><channel>community</channel><min>1.0.6</min><max></max></package></required></dependencies>
|
18 |
</package>
|