Scroll down when the plugin is activated

This commit is contained in:
Diego Najar 2018-03-09 12:26:32 +01:00
parent 321225c6b7
commit be5ad4aee1
6 changed files with 32 additions and 10 deletions

View File

@ -26,4 +26,4 @@ if ($Login->role()!=='admin') {
// ============================================================================
$pluginClassName = $layout['parameters'];
activatePlugin($pluginClassName);
Redirect::page('plugins');
Redirect::page('plugins#'.$pluginClassName);

View File

@ -17,26 +17,22 @@ echo '
<tbody>
';
foreach($plugins['all'] as $Plugin)
{
echo '<tr '.($Plugin->installed()?'class="plugin-installed"':'class="plugin-notInstalled"').'>
foreach ($plugins['all'] as $Plugin) {
echo '<tr id="'.$Plugin->className().'" '.($Plugin->installed()?'class="plugin-installed"':'class="plugin-notInstalled"').'>
<td>
<div class="plugin-name">'.$Plugin->name().'</div>
<div class="plugin-links">';
if($Plugin->installed()) {
if(method_exists($Plugin, 'form')) {
if ($Plugin->installed()) {
if (method_exists($Plugin, 'form')) {
echo '<a class="configure" href="'.HTML_PATH_ADMIN_ROOT.'configure-plugin/'.$Plugin->className().'">'.$L->g('Settings').'</a>';
echo '<span class="separator"> | </span>';
}
echo '<a class="uninstall" href="'.HTML_PATH_ADMIN_ROOT.'uninstall-plugin/'.$Plugin->className().'">'.$L->g('Deactivate').'</a>';
}
else {
} else {
echo '<a class="install" href="'.HTML_PATH_ADMIN_ROOT.'install-plugin/'.$Plugin->className().'">'.$L->g('Activate').'</a>';
}
echo '</div>';
echo '</td>';

View File

@ -0,0 +1,8 @@
{
"plugin-data": {
"name": "Static Pages",
"description": "Menü der statischen Seiten."
},
"home-link": "Hauptseite",
"show-the-home-link-on-the-sidebar": "Hauptseite im Menü zeigen."
}

View File

@ -0,0 +1,8 @@
{
"plugin-data": {
"name": "Static Pages",
"description": "Menü der statischen Seiten."
},
"home-link": "Hauptseite",
"show-the-home-link-on-the-sidebar": "Hauptseite im Menü zeigen."
}

View File

@ -0,0 +1,9 @@
{
"plugin-data":
{
"name": "Páginas Estáticas",
"description": "Cree su propio menú de navegación con páginas estáticas."
},
"home-link": "Inicio enlace",
"show-the-home-link-on-the-sidebar": "Mostrar el enlace de inicio en la barra lateral."
}

View File

@ -27,6 +27,7 @@ class pluginStaticPages extends Plugin {
$html .= '<select name="homeLink">';
$html .= '<option value="true" '.($this->getValue('homeLink')===true?'selected':'').'>'.$Language->get('Enabled').'</option>';
$html .= '<option value="false" '.($this->getValue('homeLink')===false?'selected':'').'>'.$Language->get('Disabled').'</option>';
$html .= '<span class="tip">'.$Language->get('show-the-home-link-on-the-sidebar').'</span>';
$html .= '</select>';
$html .= '</div>';