Version Notes
Download this release
Release Info
Developer | Codisto |
Extension | codistoconnect |
Version | 1.90.3 |
Comparing to | |
See all releases |
Code changes from version 1.90.2 to 1.90.3
- app/code/community/Codisto/Sync/Model/Observer.php +2 -2
- app/code/community/Codisto/Sync/Model/Sync.php +29 -6
- app/code/community/Codisto/Sync/controllers/IndexController.php +2 -2
- app/code/community/Codisto/Sync/controllers/SyncController.php +1 -1
- app/code/community/Codisto/Sync/data/codisto_setup/{data-install-1.90.2.php → data-install-1.90.3.php} +0 -0
- app/code/community/Codisto/Sync/etc/config.xml +1 -1
- app/code/community/Codisto/Sync/sql/codisto_setup/{mysql4-install-1.90.2.php → mysql4-install-1.90.3.php} +0 -0
- package.xml +1 -1
app/code/community/Codisto/Sync/Model/Observer.php
CHANGED
@@ -456,7 +456,7 @@ class Codisto_Sync_Model_Observer
|
|
456 |
|
457 |
public function salesOrderShipmentTrackSaveAfter(Varien_Event_Observer $observer)
|
458 |
{
|
459 |
-
$track = $
|
460 |
$shipment = $track->getShipment();
|
461 |
$order = $shipment->getOrder();
|
462 |
$orderid = $order->getCodistoOrderid();
|
@@ -790,6 +790,6 @@ class Codisto_Sync_Model_Observer
|
|
790 |
|
791 |
public function cancelOrderItem($observer)
|
792 |
{
|
793 |
-
|
794 |
}
|
795 |
}
|
456 |
|
457 |
public function salesOrderShipmentTrackSaveAfter(Varien_Event_Observer $observer)
|
458 |
{
|
459 |
+
$track = $observer->getEvent()->getTrack();
|
460 |
$shipment = $track->getShipment();
|
461 |
$order = $shipment->getOrder();
|
462 |
$orderid = $order->getCodistoOrderid();
|
790 |
|
791 |
public function cancelOrderItem($observer)
|
792 |
{
|
793 |
+
|
794 |
}
|
795 |
}
|
app/code/community/Codisto/Sync/Model/Sync.php
CHANGED
@@ -36,6 +36,8 @@ class Codisto_Sync_Model_Sync
|
|
36 |
private $optionCache;
|
37 |
private $optionTextCache;
|
38 |
|
|
|
|
|
39 |
public function __construct()
|
40 |
{
|
41 |
if(method_exists('Mage', 'getEdition'))
|
@@ -72,6 +74,27 @@ class Codisto_Sync_Model_Sync
|
|
72 |
$this->ebayGroupId = $ebayGroup->getId();
|
73 |
if(!$this->ebayGroupId)
|
74 |
$this->ebayGroupId = Mage_Customer_Model_Group::NOT_LOGGED_IN_ID;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
75 |
}
|
76 |
|
77 |
private function FilesInDir($dir, $prefix = '')
|
@@ -283,7 +306,7 @@ class Codisto_Sync_Model_Sync
|
|
283 |
|
284 |
// Configurable products
|
285 |
$configurableProducts = $this->getProductCollection()
|
286 |
-
->addAttributeToSelect(
|
287 |
->addAttributeToFilter('type_id', array('eq' => 'configurable'));
|
288 |
|
289 |
$sqlCheckModified = '(`e`.entity_id IN ('.implode(',', $ids).') OR `e`.entity_id IN (SELECT parent_id FROM `'.$superLinkName.'` WHERE product_id IN ('.implode(',', $ids).')))';
|
@@ -294,7 +317,7 @@ class Codisto_Sync_Model_Sync
|
|
294 |
|
295 |
// Simple Products not participating as configurable skus
|
296 |
$simpleProducts = $this->getProductCollection()
|
297 |
-
->addAttributeToSelect(
|
298 |
->addAttributeToFilter('type_id', array('eq' => 'simple'))
|
299 |
->addAttributeToFilter('entity_id', array('in' => $ids));
|
300 |
|
@@ -1405,8 +1428,8 @@ class Codisto_Sync_Model_Sync
|
|
1405 |
if($state == 'simple')
|
1406 |
{
|
1407 |
// Simple Products not participating as configurable skus
|
1408 |
-
|
1409 |
-
|
1410 |
->addAttributeToFilter('type_id', array('eq' => 'simple'))
|
1411 |
->addAttributeToFilter('entity_id', array('gt' => (int)$this->currentEntityId));
|
1412 |
|
@@ -1450,7 +1473,7 @@ class Codisto_Sync_Model_Sync
|
|
1450 |
{
|
1451 |
// Configurable products
|
1452 |
$configurableProducts = $this->getProductCollection()
|
1453 |
-
->addAttributeToSelect(
|
1454 |
->addAttributeToFilter('type_id', array('eq' => 'configurable'))
|
1455 |
->addAttributeToFilter('entity_id', array('gt' => (int)$this->currentEntityId));
|
1456 |
|
@@ -1498,7 +1521,7 @@ class Codisto_Sync_Model_Sync
|
|
1498 |
{
|
1499 |
// Grouped products
|
1500 |
$groupedProducts = $this->getProductCollection()
|
1501 |
-
->addAttributeToSelect(
|
1502 |
->addAttributeToFilter('type_id', array('eq' => 'grouped'))
|
1503 |
->addAttributeToFilter('entity_id', array('gt' => (int)$this->currentEntityId));
|
1504 |
|
36 |
private $optionCache;
|
37 |
private $optionTextCache;
|
38 |
|
39 |
+
private $availableProductFields;
|
40 |
+
|
41 |
public function __construct()
|
42 |
{
|
43 |
if(method_exists('Mage', 'getEdition'))
|
74 |
$this->ebayGroupId = $ebayGroup->getId();
|
75 |
if(!$this->ebayGroupId)
|
76 |
$this->ebayGroupId = Mage_Customer_Model_Group::NOT_LOGGED_IN_ID;
|
77 |
+
|
78 |
+
$productSelectArray = array('entity_id', 'sku', 'name', 'image', 'description', 'short_description', 'price', 'special_price', 'special_from_date', 'special_to_date', 'status', 'tax_class_id', 'weight');
|
79 |
+
$this->availableProductFields = $this->AvailableProductFields($productSelectArray);
|
80 |
+
|
81 |
+
}
|
82 |
+
|
83 |
+
private function AvailableProductFields($selectArr) {
|
84 |
+
|
85 |
+
$attributes = array();
|
86 |
+
$productAttrs = Mage::getResourceModel('catalog/product_attribute_collection');
|
87 |
+
foreach ($productAttrs as $productAttr) {
|
88 |
+
$attributes[] = $productAttr->getAttributeCode();
|
89 |
+
}
|
90 |
+
$selectAvailable = array();
|
91 |
+
foreach($attributes as $attr){
|
92 |
+
if (in_array($attr, $selectArr)) {
|
93 |
+
$selectAvailable[] = $attr;
|
94 |
+
}
|
95 |
+
}
|
96 |
+
return $selectAvailable;
|
97 |
+
|
98 |
}
|
99 |
|
100 |
private function FilesInDir($dir, $prefix = '')
|
306 |
|
307 |
// Configurable products
|
308 |
$configurableProducts = $this->getProductCollection()
|
309 |
+
->addAttributeToSelect($this->availableProductFields, 'left')
|
310 |
->addAttributeToFilter('type_id', array('eq' => 'configurable'));
|
311 |
|
312 |
$sqlCheckModified = '(`e`.entity_id IN ('.implode(',', $ids).') OR `e`.entity_id IN (SELECT parent_id FROM `'.$superLinkName.'` WHERE product_id IN ('.implode(',', $ids).')))';
|
317 |
|
318 |
// Simple Products not participating as configurable skus
|
319 |
$simpleProducts = $this->getProductCollection()
|
320 |
+
->addAttributeToSelect($this->availableProductFields, 'left')
|
321 |
->addAttributeToFilter('type_id', array('eq' => 'simple'))
|
322 |
->addAttributeToFilter('entity_id', array('in' => $ids));
|
323 |
|
1428 |
if($state == 'simple')
|
1429 |
{
|
1430 |
// Simple Products not participating as configurable skus
|
1431 |
+
|
1432 |
+
$simpleProducts = $this->getProductCollection()->addAttributeToSelect($this->availableProductFields, 'left')
|
1433 |
->addAttributeToFilter('type_id', array('eq' => 'simple'))
|
1434 |
->addAttributeToFilter('entity_id', array('gt' => (int)$this->currentEntityId));
|
1435 |
|
1473 |
{
|
1474 |
// Configurable products
|
1475 |
$configurableProducts = $this->getProductCollection()
|
1476 |
+
->addAttributeToSelect($this->availableProductFields, 'left')
|
1477 |
->addAttributeToFilter('type_id', array('eq' => 'configurable'))
|
1478 |
->addAttributeToFilter('entity_id', array('gt' => (int)$this->currentEntityId));
|
1479 |
|
1521 |
{
|
1522 |
// Grouped products
|
1523 |
$groupedProducts = $this->getProductCollection()
|
1524 |
+
->addAttributeToSelect($this->availableProductFields, 'left')
|
1525 |
->addAttributeToFilter('type_id', array('eq' => 'grouped'))
|
1526 |
->addAttributeToFilter('entity_id', array('gt' => (int)$this->currentEntityId));
|
1527 |
|
app/code/community/Codisto/Sync/controllers/IndexController.php
CHANGED
@@ -197,9 +197,9 @@ class Codisto_Sync_IndexController extends Mage_Core_Controller_Front_Action
|
|
197 |
$item->setBaseRowTotalInclTax($productpriceincltax * $productqty);
|
198 |
$item->setWeeeTaxApplied(serialize(array()));
|
199 |
|
200 |
-
$total += $productpriceincltax;
|
201 |
$itemqty += $productqty;
|
202 |
-
$totalweight += $product->getWeight();
|
203 |
|
204 |
$quote->getItemsCollection()->addItem($item);
|
205 |
}
|
197 |
$item->setBaseRowTotalInclTax($productpriceincltax * $productqty);
|
198 |
$item->setWeeeTaxApplied(serialize(array()));
|
199 |
|
200 |
+
$total += $productpriceincltax * $productqty;
|
201 |
$itemqty += $productqty;
|
202 |
+
$totalweight += $product->getWeight() * $productqty;
|
203 |
|
204 |
$quote->getItemsCollection()->addItem($item);
|
205 |
}
|
app/code/community/Codisto/Sync/controllers/SyncController.php
CHANGED
@@ -633,7 +633,7 @@ class Codisto_Sync_SyncController extends Mage_Core_Controller_Front_Action
|
|
633 |
|
634 |
}
|
635 |
|
636 |
-
$this->sendPlainResponse($response, 200, 'OK',
|
637 |
$response->sendResponse();
|
638 |
}
|
639 |
else
|
633 |
|
634 |
}
|
635 |
|
636 |
+
$this->sendPlainResponse($response, 200, 'OK', 'complete');
|
637 |
$response->sendResponse();
|
638 |
}
|
639 |
else
|
app/code/community/Codisto/Sync/data/codisto_setup/{data-install-1.90.2.php → data-install-1.90.3.php}
RENAMED
File without changes
|
app/code/community/Codisto/Sync/etc/config.xml
CHANGED
@@ -23,7 +23,7 @@
|
|
23 |
<config>
|
24 |
<modules>
|
25 |
<Codisto_Sync>
|
26 |
-
<version>1.90.
|
27 |
<depends>
|
28 |
<Mage_Payment/>
|
29 |
</depends>
|
23 |
<config>
|
24 |
<modules>
|
25 |
<Codisto_Sync>
|
26 |
+
<version>1.90.3</version>
|
27 |
<depends>
|
28 |
<Mage_Payment/>
|
29 |
</depends>
|
app/code/community/Codisto/Sync/sql/codisto_setup/{mysql4-install-1.90.2.php → mysql4-install-1.90.3.php}
RENAMED
File without changes
|
package.xml
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
-
<package><name>codistoconnect</name><version>1.90.
|
1 |
<?xml version="1.0"?>
|
2 |
+
<package><name>codistoconnect</name><version>1.90.3</version><stability>stable</stability><license>OSL-3.0</license><channel>community</channel><extends></extends><summary>Fastest, Easiest eBay listing</summary><description>CodistoConnect enables you to list on eBay in the simplest way possible with maximum performance</description><notes></notes><authors><author><name>Codisto</name><user>Codisto</user><email>hello@codisto.com</email></author></authors><date>2016-06-15</date><time>18:26:18</time><compatible></compatible><dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies><contents><target name="mage"><dir name="app"><dir name="design"><dir name="ebay"><file name="README" hash="8a3f3351f68ccde9f161cdbe3960392f"/></dir></dir><dir name="code"><dir name="community"><dir name="Codisto"><dir name="Sync"><dir name="Helper"><file name="CmsContent.php" hash="f00b4523d681c60c660089d0de0f2e03"/><file name="Data.php" hash="331f0298b2c5701e2e7ef4d52b11c5e6"/><file name="Signal.php" hash="b624f962056ceffae9c3160ed3e5655e"/></dir><dir name="controllers"><file name="CodistoController.php" hash="4992c5f9d6d2f7422f409f0321b0e455"/><file name="IndexController.php" hash="3519c07183177e17e75cb84e7a30a934"/><file name="SyncController.php" hash="dffd761724da815f9e29620b475e2c08"/></dir><dir name="Controller"><file name="Router.php" hash="0ae958be465fbbe216afe18d4a715c5d"/></dir><dir name="Test"><file name="README" hash="8299e52f9198536ff5fd3fb42f4a29d8"/><dir name="Config"><file name="AdminHtml.php" hash="6ee6404e52ed6376ad41b7556f265c32"/><file name="Config.php" hash="2e9023fcbab484d03936394934f44f13"/><dir name="Config"><dir name="expectations"><file name="testCodistoCoreConfig.yaml" hash="4a4e07f62981139ff6eb8a63420cbf0d"/></dir></dir></dir><dir name="Controllers"><file name="CodistoController.php" hash="a2be4faeac73ff1847c0d7dc4fbdc0e0"/><file name="IndexController.php" hash="f7252fae8d2f7b67397ae56524db49d1"/><file name="SyncController.php" hash="33436e4935631488073765d723a82ff7"/></dir><dir name="Controller"><file name="Router.php" hash="8afc0dca269dd0977ff6b3ac6802d0ee"/></dir><dir name="Model"><file name="Paymentmethod.php" hash="862365909073ffbba057f6f152933826"/><file name="Sync.php" hash="10a38bbb62260208a8b1529e762b7b75"/></dir></dir><dir name="sql"><dir name="codisto_setup"><file name="mysql4-install-1.90.3.php" hash="6d07d4e22ae5d907df1f4389c3a829d4"/></dir></dir><dir name="data"><dir name="codisto_setup"><file name="data-install-1.90.3.php" hash="a42cf5f15b68ac92d4c207bed8472c7d"/></dir></dir><dir name="Block"><file name="PaymentInfo.php" hash="7aa15fed37766d20d9d5a7d707aff80d"/></dir><dir name="Ebaypayment"><dir name="Model"><file name="Paymentmethod.php" hash="480787461a5b952a739f20a752bffb5d"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="4ef592c4047f610b6943758fa4fd43a6"/><file name="config.xml" hash="2387f3f61abd1272c313a8ecfba55cef"/></dir><dir name="Model"><file name="Observer.php" hash="b0b1e5c7ac62875fd77a74c49c48d5e9"/><file name="Sync.php" hash="1dd1ae1ef128a7ea51625ac2238e83ba"/><dir name="Indexer"><file name="Ebay.php" hash="556b1aabc7c3202f31a2e6c250e7d590"/></dir><dir name="Resource"><dir name="Mysql4"><file name="Setup.php" hash="6a6664ea18d93bcdd0f45530caa56244"/></dir></dir></dir></dir></dir></dir></dir><dir name="etc"><dir name="modules"><file name="Codisto_Sync.xml" hash="a791bc2a9302d085eb29edf77421f525"/></dir></dir></dir></target></contents></package>
|