Fooman_Common - Version 1.2.8

Version Notes

1.1.15 release

Download this release

Release Info

Developer Magento Core Team
Extension Fooman_Common
Version 1.2.8
Comparing to
See all releases


Code changes from version 1.2.5 to 1.2.8

app/code/community/Fooman/Common/Model/Selftester.php CHANGED
@@ -169,17 +169,22 @@ class Fooman_Common_Model_Selftester extends Fooman_Common_Model_Selftester_Abst
169
  return $dbCheckModel->dbCheck($this);
170
  }
171
 
 
 
 
 
 
172
  public function cronCheck()
173
  {
174
 
175
  if ($this->_needsCron()) {
176
  $schedulesPending = Mage::getModel('cron/schedule')->getCollection()
177
  ->addFieldToFilter('status', Mage_Cron_Model_Schedule::STATUS_PENDING)
178
- ->addFieldToFilter('created_at', array('from' => strtotime('-1 day', time())))
179
  ->load();
180
  $schedulesComplete = Mage::getModel('cron/schedule')->getCollection()
181
  ->addFieldToFilter('status', Mage_Cron_Model_Schedule::STATUS_SUCCESS)
182
- ->addFieldToFilter('created_at', array('from' => strtotime('-1 day', time())))
183
  ->load();
184
 
185
  if (sizeof($schedulesPending) == 0
169
  return $dbCheckModel->dbCheck($this);
170
  }
171
 
172
+ /**
173
+ * check cron schedule table to verify cron tasks have run and are scheduled
174
+ *
175
+ * @return bool
176
+ */
177
  public function cronCheck()
178
  {
179
 
180
  if ($this->_needsCron()) {
181
  $schedulesPending = Mage::getModel('cron/schedule')->getCollection()
182
  ->addFieldToFilter('status', Mage_Cron_Model_Schedule::STATUS_PENDING)
183
+ ->addFieldToFilter('created_at', array('from' => strtotime('-1 day', time()),'datetime' => true))
184
  ->load();
185
  $schedulesComplete = Mage::getModel('cron/schedule')->getCollection()
186
  ->addFieldToFilter('status', Mage_Cron_Model_Schedule::STATUS_SUCCESS)
187
+ ->addFieldToFilter('created_at', array('from' => strtotime('-1 day', time()),'datetime' => true))
188
  ->load();
189
 
190
  if (sizeof($schedulesPending) == 0
app/code/community/Fooman/Common/Model/Selftester/Db.php CHANGED
@@ -212,11 +212,18 @@ class Fooman_Common_Model_Selftester_Db extends Mage_Core_Model_Abstract
212
  *
213
  * @return bool
214
  */
215
- protected function _dbCheckForeignKeyConstraint(Fooman_Common_Model_Selftester $selftester, $fields, $installer, $localError)
216
- {
 
217
  try {
218
  $constraints = $installer->getConnection()->getForeignKeys($installer->getTable($fields[2]));
219
- if (!(isset($constraints[$installer->getTable($fields[1])]))) {
 
 
 
 
 
 
220
  throw new Exception(
221
  sprintf('Did not find constraint %s', $installer->getTable($fields[1]))
222
  );
212
  *
213
  * @return bool
214
  */
215
+ protected function _dbCheckForeignKeyConstraint(
216
+ Fooman_Common_Model_Selftester $selftester, $fields, $installer, $localError
217
+ ) {
218
  try {
219
  $constraints = $installer->getConnection()->getForeignKeys($installer->getTable($fields[2]));
220
+ if (empty($constraints)
221
+ || (
222
+ !(isset($constraints[$installer->getTable($fields[1])]))
223
+ && (!isset($constraints['PRIMARY'])
224
+ || (isset($constraints['PRIMARY']) && !in_array($fields[3], $constraints['PRIMARY'])))
225
+ )
226
+ ) {
227
  throw new Exception(
228
  sprintf('Did not find constraint %s', $installer->getTable($fields[1]))
229
  );
app/code/community/Fooman/Common/etc/adminhtml.xml CHANGED
@@ -1,36 +1,27 @@
1
  <?xml version="1.0"?>
2
  <config>
3
- <adminhtml>
4
- <layout>
5
- <updates>
6
- <foomancommon>
7
- <file>fooman_common.xml</file>
8
- </foomancommon>
9
- </updates>
10
- </layout>
11
- <acl>
12
- <resources>
13
- <admin>
14
- <children>
15
- <foomancommon translate="title" module="foomancommon">
16
- <title>Fooman Selftests</title>
17
- <sort_order>-100</sort_order>
18
- </foomancommon>
19
- <system>
20
- <children>
21
- <config>
22
- <children>
23
- <foomancommon translate="title" module="foomancommon">
24
- <title>Fooman</title>
25
- <sort_order>50</sort_order>
26
- </foomancommon>
27
- </children>
28
- </config>
29
- </children>
30
- </system>
31
- </children>
32
- </admin>
33
- </resources>
34
- </acl>
35
- </adminhtml>
36
  </config>
1
  <?xml version="1.0"?>
2
  <config>
3
+ <acl>
4
+ <resources>
5
+ <admin>
6
+ <children>
7
+ <foomancommon translate="title" module="foomancommon">
8
+ <title>Fooman Selftests</title>
9
+ <sort_order>-100</sort_order>
10
+ </foomancommon>
11
+ <system>
12
+ <children>
13
+ <config>
14
+ <children>
15
+ <foomancommon translate="title" module="foomancommon">
16
+ <title>Fooman</title>
17
+ <sort_order>50</sort_order>
18
+ </foomancommon>
19
+ </children>
20
+ </config>
21
+ </children>
22
+ </system>
23
+ </children>
24
+ </admin>
25
+ </resources>
26
+ </acl>
 
 
 
 
 
 
 
 
 
27
  </config>
app/code/community/Fooman/Common/etc/config.xml CHANGED
@@ -9,7 +9,7 @@
9
  <config>
10
  <modules>
11
  <Fooman_Common>
12
- <version>1.2.4</version>
13
  </Fooman_Common>
14
  </modules>
15
  <global>
@@ -40,6 +40,15 @@
40
  </adminhtml>
41
  </routers>
42
  </admin>
 
 
 
 
 
 
 
 
 
43
  <phpunit>
44
  <suite>
45
  <modules>
9
  <config>
10
  <modules>
11
  <Fooman_Common>
12
+ <version>1.2.8</version>
13
  </Fooman_Common>
14
  </modules>
15
  <global>
40
  </adminhtml>
41
  </routers>
42
  </admin>
43
+ <adminhtml>
44
+ <layout>
45
+ <updates>
46
+ <foomancommon>
47
+ <file>fooman_common.xml</file>
48
+ </foomancommon>
49
+ </updates>
50
+ </layout>
51
+ </adminhtml>
52
  <phpunit>
53
  <suite>
54
  <modules>
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Fooman_Common</name>
4
- <version>1.2.5</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>
@@ -10,9 +10,9 @@
10
  <description>add Fooman section to back-end, provide base selftest</description>
11
  <notes>1.1.15 release</notes>
12
  <authors><author><name>Kristof Ringleff</name><user>auto-converted</user><email>kristof@fooman.co.nz</email></author><author><name>Kristof Ringleff</name><user>auto-converted</user><email>kristof@fooman.co.nz</email></author></authors>
13
- <date>2014-11-05</date>
14
- <time>06:48:56</time>
15
- <contents><target name="magecommunity"><dir name="Fooman"><dir name="Common"><dir name="Block"><dir name="Adminhtml"><file name="Extensioninfo.php" hash="48a6de0af77c57b5c1a4f62a7b8c717c"/></dir></dir><dir name="Helper"><file name="Data.php" hash="e6d3700e8926d50abdc0d590b66d3aea"/></dir><dir name="Model"><dir name="Selftester"><file name="Abstract.php" hash="9c733a5af8f6f7068761beb5ae4a2955"/><file name="Db.php" hash="f28cc3d28bb98cd0b982ae79eb5263d2"/></dir><file name="Selftester.php" hash="f716efea116bb949895f3f783f023c65"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="SelftesterController.php" hash="10ab323884db2d9215eae703c3d1ca50"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="f8d8e76a8e8f9a20be6e8d8dae8043f1"/><file name="config.xml" hash="ae40b1ff299f7188f7c07b261fbfb252"/><file name="system.xml" hash="062afadb28b77803a0cf5fbdb472f23b"/></dir><file name="LICENSE.txt" hash="34410d4f566fdc33f094525a2d9865fa"/><file name="modman" hash="d0df72f800327ae8436bbb6bf76bde5a"/></dir></dir></target><target name="mage"><dir name="app"><dir name="etc"><dir name="modules"><file name="Fooman_Common.xml" hash="2555b2dd668865790df287b5cca61e35"/></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="fooman_common.xml" hash="a7e4ac18fcfcac0080b1aef960fe9c94"/></dir><dir name="template"><dir name="fooman"><dir name="common"><file name="selftester.phtml" hash="12c4225cfb71490f2b297f50650d1185"/></dir></dir></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="Fooman_Common.csv" hash="d15584a4da95d0a802e048a99a844723"/></dir></target></contents>
16
  <compatible/>
17
  <dependencies/>
18
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Fooman_Common</name>
4
+ <version>1.2.8</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>
10
  <description>add Fooman section to back-end, provide base selftest</description>
11
  <notes>1.1.15 release</notes>
12
  <authors><author><name>Kristof Ringleff</name><user>auto-converted</user><email>kristof@fooman.co.nz</email></author><author><name>Kristof Ringleff</name><user>auto-converted</user><email>kristof@fooman.co.nz</email></author></authors>
13
+ <date>2015-04-07</date>
14
+ <time>11:28:08</time>
15
+ <contents><target name="magecommunity"><dir name="Fooman"><dir name="Common"><dir name="Block"><dir name="Adminhtml"><file name="Extensioninfo.php" hash="48a6de0af77c57b5c1a4f62a7b8c717c"/></dir></dir><dir name="Helper"><file name="Data.php" hash="e6d3700e8926d50abdc0d590b66d3aea"/></dir><dir name="Model"><dir name="Selftester"><file name="Abstract.php" hash="9c733a5af8f6f7068761beb5ae4a2955"/><file name="Db.php" hash="65802bce3904b8f67f8ba0f1b44ed606"/></dir><file name="Selftester.php" hash="ea4aa6c4edc9a416e930498e59b28c5d"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="SelftesterController.php" hash="10ab323884db2d9215eae703c3d1ca50"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="e7da2572f0441d4f830fa3469fd3a067"/><file name="config.xml" hash="8c3fa3081815cd780b585064b49f31c2"/><file name="system.xml" hash="062afadb28b77803a0cf5fbdb472f23b"/></dir><file name="LICENSE.txt" hash="34410d4f566fdc33f094525a2d9865fa"/><file name="modman" hash="d0df72f800327ae8436bbb6bf76bde5a"/></dir></dir></target><target name="mage"><dir name="app"><dir name="etc"><dir name="modules"><file name="Fooman_Common.xml" hash="2555b2dd668865790df287b5cca61e35"/></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="fooman_common.xml" hash="a7e4ac18fcfcac0080b1aef960fe9c94"/></dir><dir name="template"><dir name="fooman"><dir name="common"><file name="selftester.phtml" hash="12c4225cfb71490f2b297f50650d1185"/></dir></dir></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="Fooman_Common.csv" hash="d15584a4da95d0a802e048a99a844723"/></dir></target></contents>
16
  <compatible/>
17
  <dependencies/>
18
  </package>