diff --git a/app/code/community/Retailcrm/Retailcrm/Block/Adminhtml/System/Config/Form/Fieldset/Base.php b/app/code/community/Retailcrm/Retailcrm/Block/Adminhtml/System/Config/Form/Fieldset/Base.php
index 0cc46f5..8ef4e1e 100644
--- a/app/code/community/Retailcrm/Retailcrm/Block/Adminhtml/System/Config/Form/Fieldset/Base.php
+++ b/app/code/community/Retailcrm/Retailcrm/Block/Adminhtml/System/Config/Form/Fieldset/Base.php
@@ -31,23 +31,6 @@ class Retailcrm_Retailcrm_Block_Adminhtml_System_Config_Form_Fieldset_Base exten
if ($response->isSuccessful()) {
$this->_isCredentialCorrect = true;
}
-
- $lastRun = Mage::getStoreConfig('retailcrm/general/history');
-
- if (!empty($lastRun)) {
- $lastRun = new DateTime(
- date(
- 'Y-m-d H:i:s',
- strtotime('-1 days', strtotime(date('Y-m-d H:i:s')))
- )
- );
- } else {
- $lastRun = new DateTime($lastRun);
- }
-
- $history = $client->ordersHistory($lastRun);
- var_dump($history);
- Mage::getModel('core/config')->saveConfig('retailcrm/general/history', $history->getGeneratedAt());
}
}
}
diff --git a/app/code/community/Retailcrm/Retailcrm/Model/Exchange.php b/app/code/community/Retailcrm/Retailcrm/Model/Exchange.php
index 3d1d7af..038d667 100644
--- a/app/code/community/Retailcrm/Retailcrm/Model/Exchange.php
+++ b/app/code/community/Retailcrm/Retailcrm/Model/Exchange.php
@@ -147,6 +147,7 @@ class Retailcrm_Retailcrm_Model_Exchange
$history = $client->ordersHistory($lastRun);
Mage::getModel('core/config')->saveConfig('retailcrm/general/history', $timeMark);
+ Mage::log($timeMark, null, 'history.log');
}
/**
diff --git a/app/code/community/Retailcrm/Retailcrm/etc/config.xml b/app/code/community/Retailcrm/Retailcrm/etc/config.xml
index ca0af8b..0f2da6e 100644
--- a/app/code/community/Retailcrm/Retailcrm/etc/config.xml
+++ b/app/code/community/Retailcrm/Retailcrm/etc/config.xml
@@ -63,7 +63,7 @@ SOFTWARE.
retailcrm/observer::exportCatalog
- */5 * * * *
+ */15 * * * *
retailcrm/observer::importHistory
diff --git a/app/code/community/Retailcrm/Retailcrm/etc/system.xml b/app/code/community/Retailcrm/Retailcrm/etc/system.xml
index f61c24c..9e89574 100644
--- a/app/code/community/Retailcrm/Retailcrm/etc/system.xml
+++ b/app/code/community/Retailcrm/Retailcrm/etc/system.xml
@@ -43,7 +43,6 @@ SOFTWARE.
1
- General settings that are required to connect RetailCRM and Magento.
text
10
1
@@ -72,8 +71,7 @@ SOFTWARE.
0
-
- Comparison of shipping methods
+
text
11
1
@@ -83,8 +81,7 @@ SOFTWARE.
0
-
- Comparison of payment methods
+
text
12
1
@@ -94,8 +91,7 @@ SOFTWARE.
0
-
- Comparison of payment statuses
+
text
13
1
@@ -105,8 +101,7 @@ SOFTWARE.
0
-
- Comparison of order statuses
+
text
14
1