bludit/admin/views/plugins.php

52 lines
1.3 KiB
PHP
Raw Permalink Normal View History

2015-06-11 04:27:04 +02:00
<?php
2015-10-19 00:45:58 +02:00
HTML::title(array('title'=>$L->g('Plugins'), 'icon'=>'puzzle-piece'));
echo '
<table class="uk-table uk-table-striped">
<thead>
<tr>
<th class="uk-width-1-5">'.$L->g('Name').'</th>
<th class="uk-width-3-5">'.$L->g('Description').'</th>
<th class="uk-text-center">'.$L->g('Version').'</th>
<th class="uk-text-center">'.$L->g('Author').'</th>
</tr>
</thead>
<tbody>
';
2015-06-11 04:27:04 +02:00
foreach($plugins['all'] as $Plugin)
{
2015-10-19 00:45:58 +02:00
echo '
<tr>
<td>
<div class="plugin-name">'.$Plugin->name().'</div>
<div class="plugin-links">
';
2015-06-12 06:00:04 +02:00
if($Plugin->installed()) {
2015-08-07 23:33:43 +02:00
if(method_exists($Plugin, 'form')) {
2015-10-19 00:45:58 +02:00
echo '<a class="configure" href="'.HTML_PATH_ADMIN_ROOT.'configure-plugin/'.$Plugin->className().'">'.$L->g('Configure').'</a>';
echo '<span class="separator"> | </span>';
2015-08-01 18:28:47 +02:00
}
2015-10-19 00:45:58 +02:00
echo '<a class="uninstall" href="'.HTML_PATH_ADMIN_ROOT.'uninstall-plugin/'.$Plugin->className().'">'.$L->g('Uninstall').'</a>';
2015-06-12 06:00:04 +02:00
}
else {
2015-10-19 00:45:58 +02:00
echo '<a class="install" href="'.HTML_PATH_ADMIN_ROOT.'install-plugin/'.$Plugin->className().'">'.$L->g('Install').'</a>';
2015-06-12 06:00:04 +02:00
}
2015-10-19 00:45:58 +02:00
echo '
</div>
</td>
<td>'.$Plugin->description().'</td>
<td class="uk-text-center">'.$Plugin->version().'</td>
<td class="uk-text-center"><a targe="_blank" href="'.$Plugin->website().'">'.$Plugin->author().'</a></td>
';
echo '</tr>';
2015-06-11 04:27:04 +02:00
}
2015-10-19 00:45:58 +02:00
echo '
</tbody>
</table>
';