Skip to content
Snippets Groups Projects
Commit 94f34414 authored by Florian Bieringer's avatar Florian Bieringer
Browse files

Show latest plugins in overview

parent 28735ad6
No related branches found
No related tags found
1 merge request!53Show latest plugins in overview #51
......@@ -89,6 +89,8 @@ class PresentingController extends MarketController
}
$this->plugins = MarketPlugin::findBySQL("publiclyvisible = 1 AND approved = 1 ORDER BY RAND() LIMIT 3");
$this->latest_plugins = MarketPlugin::findBySQL("publiclyvisible = 1 AND approved = 1 ORDER BY mkdate DESC LIMIT 5");
$this->best_plugins = MarketPlugin::findBySQL("publiclyvisible = 1 AND approved = 1 ORDER BY rating DESC LIMIT 6");
......
<? if ($show_all) : ?>
<h2><?=count($plugins)?>&nbsp;<?= _('Plugins') ?></h2>
<h2><?= count($plugins) ?>&nbsp;<?= _('Plugins') ?></h2>
<div class="plugins_shortview">
<? foreach ($plugins as $marketplugin) : ?>
<?= $this->render_partial("presenting/_plugin_short.php", compact("marketplugin", "plugin")) ?>
......@@ -15,6 +15,13 @@
</div>
<? endif ?>
<h2><?= _("Neueste Plugins") ?></h2>
<div class="plugins_shortview">
<? foreach ($latest_plugins as $marketplugin) : ?>
<?= $this->render_partial("presenting/_plugin_short.php", compact("marketplugin", "plugin")) ?>
<? endforeach ?>
</div>
<h2><?= _("Zufllige Plugins") ?></h2>
<div class="plugins_shortview">
<? foreach ($plugins as $marketplugin) : ?>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment