/** * Timer for year or ordered months * @return string */ protected function getTimerForOrderingInQuery() { if ($this->showsAllYears()) { // Ensure month-wise data return 'MONTH(FROM_UNIXTIME(`time`))'; } return parent::getTimerForOrderingInQuery(); }
/** * Timer for year or ordered months * @param bool $addTableName must be used if query contains joins * @return string */ protected function getTimerForOrderingInQuery($addTableName = false) { $time = $addTableName ? '`' . PREFIX . 'training`.`time`' : '`time`'; if ($this->showsAllYears()) { // Ensure month-wise data return 'MONTH(FROM_UNIXTIME(' . $time . '))'; } return parent::getTimerForOrderingInQuery($addTableName); }
?> </div> </div> <div id="statistics" class="panel"> <ul id="statistics-nav"> <?php $Factory = new PluginFactory(); $Stats = $Factory->activePlugins(PluginType::STAT); foreach ($Stats as $i => $key) { $Plugin = $Factory->newInstance($key); if ($Plugin !== false) { echo '<li' . ($i == 0 ? ' class="active"' : '') . '>' . $Plugin->getLink() . '</li>'; } } if (PluginStat::hasVariousStats()) { echo '<li class="with-submenu">'; echo '<a href="#">' . __('Miscellaneous') . '</a>'; echo '<ul class="submenu">'; $VariousStats = $Factory->variousPlugins(); foreach ($VariousStats as $key) { $Plugin = $Factory->newInstance($key); if ($Plugin !== false) { echo '<li>' . $Plugin->getLink() . '</li>'; } } echo '</ul>'; echo '</li>'; } ?> </ul>